github.com/kyleu/dbaudit@v0.0.2-0.20240321155047-ff2f2c940496/views/vpage/Load.html.go (about)

     1  // Code generated by qtc from "Load.html". DO NOT EDIT.
     2  // See https://github.com/valyala/quicktemplate for details.
     3  
     4  // <!-- Content managed by Project Forge, see [projectforge.md] for details. -->
     5  
     6  //line views/vpage/Load.html:2
     7  package vpage
     8  
     9  //line views/vpage/Load.html:2
    10  import (
    11  	"github.com/kyleu/dbaudit/app"
    12  	"github.com/kyleu/dbaudit/app/controller/cutil"
    13  	"github.com/kyleu/dbaudit/views/layout"
    14  )
    15  
    16  //line views/vpage/Load.html:8
    17  import (
    18  	qtio422016 "io"
    19  
    20  	qt422016 "github.com/valyala/quicktemplate"
    21  )
    22  
    23  //line views/vpage/Load.html:8
    24  var (
    25  	_ = qtio422016.Copy
    26  	_ = qt422016.AcquireByteBuffer
    27  )
    28  
    29  //line views/vpage/Load.html:8
    30  type Load struct {
    31  	layout.Basic
    32  	URL              string
    33  	Title            string
    34  	Message          string
    35  	HideInstructions bool
    36  }
    37  
    38  //line views/vpage/Load.html:16
    39  func (p *Load) StreamBody(qw422016 *qt422016.Writer, as *app.State, ps *cutil.PageState) {
    40  //line views/vpage/Load.html:16
    41  	qw422016.N().S(`
    42  `)
    43  //line views/vpage/Load.html:18
    44  	if p.Message == "" {
    45  		p.Message = "Please wait as your request is processed..."
    46  	}
    47  
    48  //line views/vpage/Load.html:21
    49  	qw422016.N().S(`  <div class="card">
    50      <h3>`)
    51  //line views/vpage/Load.html:23
    52  	qw422016.E().S(p.Title)
    53  //line views/vpage/Load.html:23
    54  	qw422016.N().S(`</h3>
    55      <p>`)
    56  //line views/vpage/Load.html:24
    57  	qw422016.E().S(p.Message)
    58  //line views/vpage/Load.html:24
    59  	qw422016.N().S(`</p>
    60  `)
    61  //line views/vpage/Load.html:25
    62  	if !p.HideInstructions {
    63  //line views/vpage/Load.html:25
    64  		qw422016.N().S(`    <div class="mt"><em>Please avoid refreshing the browser or navigating away, your page is loading</em></div>
    65  `)
    66  //line views/vpage/Load.html:27
    67  	}
    68  //line views/vpage/Load.html:27
    69  	qw422016.N().S(`  </div>
    70    <meta http-equiv="refresh" content="0; url=`)
    71  //line views/vpage/Load.html:29
    72  	qw422016.E().S(p.URL)
    73  //line views/vpage/Load.html:29
    74  	qw422016.N().S(`">
    75  `)
    76  //line views/vpage/Load.html:30
    77  }
    78  
    79  //line views/vpage/Load.html:30
    80  func (p *Load) WriteBody(qq422016 qtio422016.Writer, as *app.State, ps *cutil.PageState) {
    81  //line views/vpage/Load.html:30
    82  	qw422016 := qt422016.AcquireWriter(qq422016)
    83  //line views/vpage/Load.html:30
    84  	p.StreamBody(qw422016, as, ps)
    85  //line views/vpage/Load.html:30
    86  	qt422016.ReleaseWriter(qw422016)
    87  //line views/vpage/Load.html:30
    88  }
    89  
    90  //line views/vpage/Load.html:30
    91  func (p *Load) Body(as *app.State, ps *cutil.PageState) string {
    92  //line views/vpage/Load.html:30
    93  	qb422016 := qt422016.AcquireByteBuffer()
    94  //line views/vpage/Load.html:30
    95  	p.WriteBody(qb422016, as, ps)
    96  //line views/vpage/Load.html:30
    97  	qs422016 := string(qb422016.B)
    98  //line views/vpage/Load.html:30
    99  	qt422016.ReleaseByteBuffer(qb422016)
   100  //line views/vpage/Load.html:30
   101  	return qs422016
   102  //line views/vpage/Load.html:30
   103  }