start cookie session
This commit is contained in:
parent
017ef4c066
commit
1b6f3e6103
6 changed files with 299 additions and 55 deletions
27
controllers/sample.go
Normal file
27
controllers/sample.go
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
// Copyright (c) 2024 Zeni Kim <zenik@smarteching.com>
|
||||
// Use of this source code is governed by MIT-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package controllers
|
||||
|
||||
import (
|
||||
"git.smarteching.com/goffee/core"
|
||||
"git.smarteching.com/goffee/core/template/components"
|
||||
)
|
||||
|
||||
// Show basic template
|
||||
func Sample(c *core.Context) *core.Response {
|
||||
|
||||
type templateData struct {
|
||||
TheTitle components.Title
|
||||
}
|
||||
|
||||
tmplData := templateData{
|
||||
TheTitle: components.Title{
|
||||
Label: "Lorem ipsum inside",
|
||||
},
|
||||
}
|
||||
|
||||
return c.Response.Template("basic.html", tmplData)
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue