From 3caeeaf29d90c900c36b74167ded803baee57b7c Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Mon, 4 Aug 2025 11:24:46 +0800 Subject: [PATCH] :art: Improve database field default filling https://github.com/siyuan-note/siyuan/issues/11966 --- kernel/model/attribute_view.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/kernel/model/attribute_view.go b/kernel/model/attribute_view.go index b4bc4aca5..f2ac3daad 100644 --- a/kernel/model/attribute_view.go +++ b/kernel/model/attribute_view.go @@ -3157,6 +3157,11 @@ func addAttributeViewBlock(now int64, avID, blockID, groupID, previousBlockID, a continue } + if av.KeyTypeRollup == newValue.Type { + // 汇总字段的值是渲染时计算的,不需要添加到数据存储中 + continue + } + if av.KeyTypeBlock == newValue.Type { // 如果是主键的话前面已经添加过了,这里仅修改内容 blockValue.Block.Content = newValue.Block.Content