mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 00:20:47 +02:00
🎨 Improve open the user guide https://github.com/siyuan-note/siyuan/issues/15792
This commit is contained in:
parent
c326989391
commit
0ad7c4cf23
1 changed files with 7 additions and 0 deletions
|
@ -203,6 +203,12 @@ func Mount(boxID string) (alreadyMount bool, err error) {
|
|||
return
|
||||
}
|
||||
|
||||
boxes, _ := ListNotebooks()
|
||||
var sort int
|
||||
if len(boxes) > 0 {
|
||||
sort = boxes[0].Sort - 1
|
||||
}
|
||||
|
||||
p := filepath.Join(util.WorkingDir, "guide", boxID)
|
||||
if err = filelock.Copy(p, localPath); err != nil {
|
||||
return
|
||||
|
@ -218,6 +224,7 @@ func Mount(boxID string) (alreadyMount bool, err error) {
|
|||
if box := Conf.Box(boxID); nil != box {
|
||||
boxConf := box.GetConf()
|
||||
boxConf.Closed = true
|
||||
boxConf.Sort = sort
|
||||
box.SaveConf(boxConf)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue