From 04800fdaf35fa0f4f4b075606702b370d2ff7222 Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Sat, 26 Nov 2022 10:41:44 +0800 Subject: [PATCH] =?UTF-8?q?:art:=20=E6=8A=98=E5=8F=A0=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E9=A1=B9=E8=BD=AC=E6=8D=A2=E4=B8=BA=E6=96=87=E6=A1=A3=E6=97=B6?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E5=B1=95=E5=BC=80=E5=AD=90=E5=9D=97=20Fix=20?= =?UTF-8?q?https://github.com/siyuan-note/siyuan/issues/6719?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kernel/model/listitem.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kernel/model/listitem.go b/kernel/model/listitem.go index 0407688ba..e89e12c38 100644 --- a/kernel/model/listitem.go +++ b/kernel/model/listitem.go @@ -87,6 +87,7 @@ func ListItem2Doc(srcListItemID, targetBoxID, targetPath string) (srcRootBlockID listItemNode.SetIALAttr("type", "doc") listItemNode.SetIALAttr("id", srcListItemID) listItemNode.SetIALAttr("title", listItemText) + listItemNode.RemoveIALAttr("fold") newTree.Root.KramdownIAL = listItemNode.KramdownIAL srcLiParent := listItemNode.Parent listItemNode.Unlink() @@ -103,6 +104,7 @@ func ListItem2Doc(srcListItemID, targetBoxID, targetPath string) (srcRootBlockID newTree.Box, newTree.Path = targetBoxID, newTargetPath newTree.Root.SetIALAttr("updated", util.CurrentTimeSecondsStr()) + newTree.Root.Spec = "1" if err = indexWriteJSONQueue(newTree); nil != err { return "", "", err }