// Code generated by summer make. DO NOT EDIT. package controllers import ( "git.golem15.com/golem15/summercms/docs/examples/blog/models" "git.golem15.com/golem15/summercms/modules/pact" ) var ( _ pact.AdminController = postsAdmin{} _ pact.AdminRecordSource = postsAdmin{} _ pact.AdminPermissioned = postsAdmin{} ) // postsAdmin is the Go form of the Posts backend controller with the List // and Form behaviours. type postsAdmin struct{} func (postsAdmin) ID() string { return "acme.blog.posts" } func (postsAdmin) ModelName() string { return "Post" } func (postsAdmin) ConfigDir() string { return "controllers/posts" } // NewRecord returns the model the generic admin handlers query and fill. func (postsAdmin) NewRecord() any { return &models.Post{} } // RequiredPermissions replaces $requiredPermissions: an administrator needs // this permission before any schema or record is served. func (postsAdmin) RequiredPermissions() []string { return []string{"acme.blog.access_posts"} } // PostsController returns the acme.blog.posts admin controller. func PostsController() pact.AdminController { return postsAdmin{} }