package pages import ( "bytes" "html/template" "faculty_media_report/dbi" ) var dashboardTmpl = template.Must(template.New("dashboard").Parse(` Dashboard — Maurer School of Law
Skip to main content

Activity Report Dashboard

{{if .}}
{{range .}} {{end}}
Date Submitted Name Title Description Hyperlink Type
{{.Created}} {{.LastName}}, {{.FirstName}} {{.Title}} {{.Description}} {{if .Hyperlink}}Link{{end}} {{.ItemType}}
{{else}}

No reported items.

{{end}}
`)) func DashboardPage(items []dbi.DashboardItem) (string, error) { var buf bytes.Buffer if err := dashboardTmpl.Execute(&buf, items); err != nil { return "", err } return buf.String(), nil }