Files
assets/model/entity/asset/private_category.go
2026-03-18 10:18:03 +08:00

26 lines
967 B
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package entity
import (
"assets/consts/public"
"gitea.com/red-future/common/beans"
)
// PrivateCategory 私域分类实体
type PrivateCategory struct {
beans.MongoBaseDO `bson:",inline"` // 嵌入基础字段Id, Creator, CreatedAt, Updater, UpdatedAt, TenantId, IsDeleted
Name string `bson:"name" json:"name"` // 分类名称
ParentID string `bson:"parentId" json:"parentId"` // 父分类ID为空表示根分类
Path string `bson:"path" json:"path"` // 分类路径,如:/root/parent
Level int `bson:"level" json:"level"` // 分类层级
IsLeafNode bool `bson:"isLeafNode" json:"isLeafNode"` // 是叶子节点
Sort int `bson:"sort" json:"sort"` // 排序
Image string `bson:"image" json:"image"` // 分类图片
}
// CollectionName 分类集合名称
func (PrivateCategory) CollectionName() string {
return public.PrivateCategoryCollection
}