controllers

package
v0.0.0-...-66fd069 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 10, 2014 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseController

type BaseController struct{}

func (*BaseController) FormGroup

func (ctrl *BaseController) FormGroup(name string, errs map[string]string, label string) template.HTML

func (*BaseController) FormGroupClose

func (ctrl *BaseController) FormGroupClose(name string, errs map[string]string) template.HTML
func (ctrl *BaseController) MenuLink(url, title, current_url string) template.HTML

type ContentController

type ContentController struct {
	BaseController
}

This controller is poorly named, but it manages both content and pages Content are the versioned entities Pages hold the current view and metadata

func (*ContentController) Create

func (ctrl *ContentController) Create(c context.Context) error

func (*ContentController) New

func (ctrl *ContentController) New(c context.Context) error

Show the markdown editor form

func (*ContentController) Preview

func (ctrl *ContentController) Preview(c context.Context) error

func (*ContentController) Publish

func (ctrl *ContentController) Publish(c context.Context) error

1. Save to datastore 2. Save rendered template to cloud storage 3. Redirect user to new URL

func (*ContentController) Read

func (ctrl *ContentController) Read(key string, c context.Context) error

func (*ContentController) ReadMany

func (ctrl *ContentController) ReadMany(c context.Context) error

type FilesController

type FilesController struct {
	BaseController
}

func (*FilesController) Create

func (ctrl *FilesController) Create(c context.Context) error

func (*FilesController) ReadMany

func (ctrl *FilesController) ReadMany(c context.Context) error

type SitesController

type SitesController struct {
	BaseController
}

func (*SitesController) Create

func (ctrl *SitesController) Create(c context.Context) error

func (*SitesController) Delete

func (ctrl *SitesController) Delete(key string, c context.Context) error

func (*SitesController) Read

func (ctrl *SitesController) Read(key string, c context.Context) error

This actually does a ReadMany action combined with Edit

func (*SitesController) ReadMany

func (ctrl *SitesController) ReadMany(c context.Context) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL