Documentation ¶
Index ¶
- Constants
- Variables
- func UploadImg(req *http.Request) io.UrlStatus
- type CateInfo
- type CateNode
- type CateTree
- type CmsCfg
- type CmsCtx
- func (c *CmsCtx) CateTree() (tree *CateTree, err error)
- func (c *CmsCtx) GetCate(id GUID) (m CmsInfo)
- func (c *CmsCtx) GetCateByUri(ns, mc string) (m CmsInfo)
- func (c *CmsCtx) GetCateInfo(id GUID, f *filter.PageFilter) (m CateInfo)
- func (c *CmsCtx) GetInfo(id GUID) (m CmsInfo)
- func (c *CmsCtx) GetTopCateInfoByUri(ns, mc string, n int) (m []CmsInfo)
- func (c *CmsCtx) Orm() *orm.Orm
- func (c *CmsCtx) SaveCate(m *CmsInfo) error
- func (c *CmsCtx) SaveInfo(m *CmsInfo) error
- func (c *CmsCtx) SetOrm(orm *orm.Orm)
- type CmsFj
- type CmsInfo
Constants ¶
View Source
const (
Cate_Cgid = GUID("7cae5572-02ef-11e7-902f-c07cd130ee8a")
)
Variables ¶
View Source
var (
Ctx = &CmsCtx{}
)
Functions ¶
Types ¶
type CateTree ¶
type CateTree struct { Nodes []*CateNode // contains filtered or unexported fields }
func NewCateTree ¶
func NewCateTree() *CateTree
type CmsCtx ¶
type CmsCtx struct {
// contains filtered or unexported fields
}
func (*CmsCtx) GetCateByUri ¶
func (*CmsCtx) GetCateInfo ¶
func (c *CmsCtx) GetCateInfo(id GUID, f *filter.PageFilter) (m CateInfo)
func (*CmsCtx) GetTopCateInfoByUri ¶
type CmsFj ¶
func UploadFile ¶
type CmsInfo ¶
type CmsInfo struct { Id GUID Uid GUID //发布者user.id Mc string //名称,主标题 Qz int //权重 IsCate bool //是否分类 Ns string //分类:树展示路径 Lx string //类型?//信息,分类,文件下载,链接,特殊模型(红头文件等) Ljdkfs bool //链接打开方式,Target :_blank Zt string //状态? Cjsj time.Time Gxsj time.Time Fbsj time.Time `json:",omitempty"` //发布时间 Nr string `json:",omitempty"` //内容 Mc2 string `json:",omitempty"` //副标题 Ztp string `json:",omitempty"` //主图片,一般用于展示 Fbdw string `json:",omitempty"` //发布单位(信息) Zy string `json:",omitempty"` //摘要 Fj []CmsFj `json:",omitempty"` //附件列表 Cates []GUID `json:",omitempty"` //分类列表(信息) Tags []string `json:",omitempty"` Bz string `json:",omitempty"` // 备注 Ext M `json:",omitempty"` Fav bool }
Click to show internal directories.
Click to hide internal directories.