summaryrefslogtreecommitdiff
path: root/management/editor/editor.go
diff options
context:
space:
mode:
Diffstat (limited to 'management/editor/editor.go')
-rw-r--r--management/editor/editor.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/management/editor/editor.go b/management/editor/editor.go
index 0acf03e..f49c4e3 100644
--- a/management/editor/editor.go
+++ b/management/editor/editor.go
@@ -6,8 +6,10 @@ import "bytes"
// Editable ensures data is editable
type Editable interface {
+ SetContentID(id int)
ContentID() int
ContentName() string
+ SetSlug(slug string)
Editor() *Editor
MarshalEditor() ([]byte, error)
}
@@ -23,9 +25,9 @@ type Field struct {
View []byte
}
-// New takes editable content and any number of Field funcs to describe the edit
+// Form takes editable content and any number of Field funcs to describe the edit
// page for any content struct added by a user
-func New(post Editable, fields ...Field) ([]byte, error) {
+func Form(post Editable, fields ...Field) ([]byte, error) {
editor := post.Editor()
editor.ViewBuf = &bytes.Buffer{}