mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
✨ Database grouping by field https://github.com/siyuan-note/siyuan/issues/10964
This commit is contained in:
parent
b357047290
commit
17c59cb2ca
11 changed files with 64 additions and 69 deletions
|
|
@ -66,6 +66,8 @@ type BaseInstance struct {
|
|||
WrapField bool `json:"wrapField"` // 是否换行字段内容
|
||||
Folded bool `json:"folded,omitempty"` // 是否折叠
|
||||
Hidden bool `json:"hidden,omitempty"` // 是否隐藏
|
||||
|
||||
Groups []Viewable `json:"groups,omitempty"` // 分组实例列表
|
||||
}
|
||||
|
||||
func (baseInstance *BaseInstance) GetSorts() []*ViewSort {
|
||||
|
|
@ -76,6 +78,14 @@ func (baseInstance *BaseInstance) GetFilters() []*ViewFilter {
|
|||
return baseInstance.Filters
|
||||
}
|
||||
|
||||
func (baseInstance *BaseInstance) SetGroups(viewables []Viewable) {
|
||||
baseInstance.Groups = viewables
|
||||
}
|
||||
|
||||
func (baseInstance *BaseInstance) GetID() string {
|
||||
return baseInstance.ID
|
||||
}
|
||||
|
||||
// BaseInstanceField 描述了实例字段的基础结构。
|
||||
type BaseInstanceField struct {
|
||||
ID string `json:"id"` // ID
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue