admin

package
v0.0.0-...-99ae320 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2015 License: GPL-3.0 Imports: 15 Imported by: 0

Documentation

Overview

TODO: This editor needs to be rewritten with new model ffor contentypes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddChild

func AddChild(w *wrapper.Wrapper)

Controller for adding children to wrapper element or path.

func AddExistingChild

func AddExistingChild(w *wrapper.Wrapper)

Controller for adding existing element to wrapper element or path.

func AddExistingChildForm

func AddExistingChildForm(w *wrapper.Wrapper)

Controller for adding existing element form.

func AddExistingPathSubmit

func AddExistingPathSubmit(w *wrapper.Wrapper)

Controller for adding existing element to path form submission.

func AddExistingWrapperSubmit

func AddExistingWrapperSubmit(w *wrapper.Wrapper)

Controller for adding existing element to wrapper element form submission.

func AddPathChild

func AddPathChild(w *wrapper.Wrapper)

Controller for adding children to path.

func AddSlugChild

func AddSlugChild(w *wrapper.Wrapper)

func AddWrapperChild

func AddWrapperChild(w *wrapper.Wrapper)

Controller for adding children to wrapper element.

func AdminPaths

func AdminPaths(w *wrapper.Wrapper)

Controller to list all paths

func AllElements

func AllElements(w *wrapper.Wrapper)

Controller to list all elements

func ContentEditor

func ContentEditor(w *wrapper.Wrapper)

Controller to edit content in element.

func ContentEditorForm

func ContentEditorForm(w *wrapper.Wrapper)

Controller for content editing form.

func ContentEditorSubmit

func ContentEditorSubmit(w *wrapper.Wrapper)

Controller to handle content editor submission.

func ContentTypeEditor

func ContentTypeEditor(w *wrapper.Wrapper)

Controller to change content type for content type element.

func ContentTypeEditorForm

func ContentTypeEditorForm(w *wrapper.Wrapper)

Controller to ddisplay form to change content type for conteent element

func ContentTypeEditorSubmit

func ContentTypeEditorSubmit(w *wrapper.Wrapper)

Controller to handle submission for content type change form.

func Delete

func Delete(w *wrapper.Wrapper)

This controller deletes paths and elements

func DeleteElement

func DeleteElement(w *wrapper.Wrapper)

Controller to delete an element and all references to the element

func DeletePath

func DeletePath(w *wrapper.Wrapper)

Controller to delete a path

func EditContentType

func EditContentType(w *wrapper.Wrapper)

func EditContentTypeForm

func EditContentTypeForm(w *wrapper.Wrapper)

func EditContentTypeSubmit

func EditContentTypeSubmit(w *wrapper.Wrapper)

func Element

func Element(w *wrapper.Wrapper)

Controller to render an element in content editor

func ElementEditor

func ElementEditor(w *wrapper.Wrapper)

Controller to edit an elements properties TODO: break this into smaller functions to make it easier to maintain

func FieldFormGroup

func FieldFormGroup() []*form.Field

func GetAllContentTypes

func GetAllContentTypes(w *wrapper.Wrapper)

func GetContentType

func GetContentType(w *wrapper.Wrapper)

func GetControllerMap

func GetControllerMap(cm controller.ControllerMap)

Package function to return controller map

func MenuEditor(w *wrapper.Wrapper)

Controller to edit a menu element TODO: break this into smaller functions

func NewAdmin

func NewAdmin() (*AdminMap, *AdminMenu)

Build a new admin instance and return AdminMap and menu to be altered

func OrphanElements

func OrphanElements(w *wrapper.Wrapper)

Controller to retrive a list of all orphaned elements.

func PathEditor

func PathEditor(w *wrapper.Wrapper)

Controller for editing paths

func PathEditorForm

func PathEditorForm(w *wrapper.Wrapper)

Controller to present path editor form

func PathEditorSubmit

func PathEditorSubmit(w *wrapper.Wrapper)

Controller to handle path editor form submissions.

func PathElements

func PathElements(w *wrapper.Wrapper)

Retrieve a list of elements in a path for content editor.

func SlugUrlEditor

func SlugUrlEditor(w *wrapper.Wrapper)

func SlugUrlEditorForm

func SlugUrlEditorForm(w *wrapper.Wrapper)

func SlugUrlEditorSubmit

func SlugUrlEditorSubmit(w *wrapper.Wrapper)

func Sort

func Sort(w *wrapper.Wrapper)

Sort controller to sort path and wrapper children

func SortPathForm

func SortPathForm(w *wrapper.Wrapper)

Controller for path sort form.

func SortPathSubmit

func SortPathSubmit(w *wrapper.Wrapper)

Controller for path sort submission.

func SortWrapperForm

func SortWrapperForm(w *wrapper.Wrapper)

Controller for wrapper element sort form.

func SortWrapperSubmit

func SortWrapperSubmit(w *wrapper.Wrapper)

Controller for wrapper sort submission.

Types

type AdminMap

type AdminMap controller.ControllerMap

Admin Map for controllers

func (AdminMap) Admin

func (a AdminMap) Admin(w *wrapper.Wrapper)

Main controller for all admin functions

type AdminMenu

type AdminMenu struct {
	MenuItems []map[string]string `json:"menu_items"`
}

A series of menu items to render on the admin page

func (*AdminMenu) AdminMenu

func (a *AdminMenu) AdminMenu(w *wrapper.Wrapper)

Structure of url links that appear on the admin page.

type ContentType

type ContentType struct {
	Form    []*form.Field `bson:"form,omitempty" json:"content_form"`
	Type    string        `bson:"type,omitempty" json:"type"`
	MongoId bson.ObjectId `bson:"_id" json:"id"`
}

Jump to

Keyboard shortcuts

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