page

package
v1.53.4 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2017 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Meta

type Meta struct {
	ID             uint64    `json:"id"`
	Created        time.Time `json:"created"`
	Revised        time.Time `json:"revised"`
	OrgID          string    `json:"orgId"`
	UserID         string    `json:"userId"`
	DocumentID     string    `json:"documentId"`
	PageID         string    `json:"pageId"`
	RawBody        string    `json:"rawBody"`        // a blob of data
	Config         string    `json:"config"`         // JSON based custom config for this type
	ExternalSource bool      `json:"externalSource"` // true indicates data sourced externally
}

Meta holds raw page data that is used to render the actual page data.

func (*Meta) SetDefaults

func (p *Meta) SetDefaults()

SetDefaults ensures no blank values.

type NewPage

type NewPage struct {
	Page Page `json:"page"`
	Meta Meta `json:"meta"`
}

NewPage contains the page and associated meta.

type Page

type Page struct {
	model.BaseEntity
	OrgID       string  `json:"orgId"`
	DocumentID  string  `json:"documentId"`
	UserID      string  `json:"userId"`
	ContentType string  `json:"contentType"`
	PageType    string  `json:"pageType"`
	BlockID     string  `json:"blockId"`
	Level       uint64  `json:"level"`
	Sequence    float64 `json:"sequence"`
	Title       string  `json:"title"`
	Body        string  `json:"body"`
	Revisions   uint64  `json:"revisions"`
}

Page represents a section within a document.

func (*Page) IsSectionType

func (p *Page) IsSectionType() bool

IsSectionType tells us that page is "words"

func (*Page) IsTabType

func (p *Page) IsTabType() bool

IsTabType tells us that page is "SaaS data embed"

func (*Page) SetDefaults

func (p *Page) SetDefaults()

SetDefaults ensures no blank values.

type PageLevelRequest

type PageLevelRequest struct {
	PageID string `json:"pageId"`
	Level  int    `json:"level"`
}

PageLevelRequest details a page ID and level.

type PageSequenceRequest

type PageSequenceRequest struct {
	PageID   string  `json:"pageId"`
	Sequence float64 `json:"sequence"`
}

PageSequenceRequest details a page ID and its sequence within the document.

type Revision

type Revision struct {
	model.BaseEntity
	OrgID       string `json:"orgId"`
	DocumentID  string `json:"documentId"`
	PageID      string `json:"pageId"`
	OwnerID     string `json:"ownerId"`
	UserID      string `json:"userId"`
	ContentType string `json:"contentType"`
	PageType    string `json:"pageType"`
	Title       string `json:"title"`
	Body        string `json:"body"`
	RawBody     string `json:"rawBody"`
	Config      string `json:"config"`
	Email       string `json:"email"`
	Firstname   string `json:"firstname"`
	Lastname    string `json:"lastname"`
	Initials    string `json:"initials"`
	Revisions   int    `json:"revisions"`
}

Revision holds the previous version of a Page.

Jump to

Keyboard shortcuts

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