Exemple #1
0
func newFragments() web.Controller {
	_ = n.Log
	var rtn = &fragments{
		service: services.New.Fragments(),
		decoder: schema.NewDecoder(),
		urls:    urls.New.UrlHelper(),
	}
	return rtn
}
Exemple #2
0
// Create an instance
func newContext(w http.ResponseWriter, r *http.Request, vars map[string]string) *Context {
	var rtn = &Context{
		Writer:  w,
		Request: r,
		vars:    vars,
		decoder: schema.NewDecoder(),
	}
	rtn.Url = &url{rtn}
	rtn.Form = &form{rtn}
	rtn.Utils = &utils{rtn}
	return rtn
}