mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 23:20:13 +01:00
🎨 The database rollup field supports using the template field https://github.com/siyuan-note/siyuan/issues/12384
This commit is contained in:
parent
bc16cd658f
commit
f2dda8b389
4 changed files with 22 additions and 10 deletions
|
|
@ -18,7 +18,7 @@ import (
|
|||
"github.com/siyuan-note/siyuan/kernel/util"
|
||||
)
|
||||
|
||||
func RenderAttributeViewGallery(attrView *av.AttributeView, view *av.View, query string) (ret *av.Gallery) {
|
||||
func RenderAttributeViewGallery(attrView *av.AttributeView, view *av.View, query string, depth *int) (ret *av.Gallery) {
|
||||
ret = &av.Gallery{
|
||||
BaseInstance: av.NewViewBaseInstance(view),
|
||||
CoverFrom: view.Gallery.CoverFrom,
|
||||
|
|
@ -114,7 +114,7 @@ func RenderAttributeViewGallery(attrView *av.AttributeView, view *av.View, query
|
|||
ials := BatchGetBlockAttrsWitTrees(ialIDs, boundTrees)
|
||||
|
||||
// 渲染自动生成的字段值,比如关联字段、汇总字段、创建时间字段和更新时间字段
|
||||
fillAttributeViewAutoGeneratedValues(attrView, ret, ials, cardsValues)
|
||||
fillAttributeViewAutoGeneratedValues(attrView, ret, ials, cardsValues, depth)
|
||||
|
||||
// 最后单独渲染模板字段,这样模板字段就可以使用汇总、关联、创建时间和更新时间字段的值了
|
||||
renderTemplateErr := fillAttributeViewTemplateValues(attrView, ret, ials, cardsValues)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue