Add initial report outline page.
This commit is contained in:
parent
ac736cced1
commit
f6acb6ab83
4 changed files with 284 additions and 0 deletions
8
html.go
8
html.go
|
|
@ -15,6 +15,7 @@ import (
|
|||
|
||||
var (
|
||||
dashboard = newBuiltTemplate("dashboard", "authenticated")
|
||||
report = newBuiltTemplate("report", "base")
|
||||
signin = newBuiltTemplate("signin", "base")
|
||||
signup = newBuiltTemplate("signup", "base")
|
||||
)
|
||||
|
|
@ -32,6 +33,8 @@ type Link struct {
|
|||
type ContentDashboard struct {
|
||||
User User
|
||||
}
|
||||
type ContentPlaceholder struct {
|
||||
}
|
||||
type ContentSignin struct {
|
||||
InvalidCredentials bool
|
||||
}
|
||||
|
|
@ -83,6 +86,11 @@ func htmlDashboard(w io.Writer, user *models.User) error {
|
|||
return dashboard.ExecuteTemplate(w, data)
|
||||
}
|
||||
|
||||
func htmlReport(w io.Writer) error {
|
||||
data := ContentPlaceholder{}
|
||||
return report.ExecuteTemplate(w, data)
|
||||
}
|
||||
|
||||
func htmlSignin(w io.Writer, errorCode string) error {
|
||||
data := ContentSignin{
|
||||
InvalidCredentials: errorCode == "invalid-credentials",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue