mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 15:10:12 +01:00
🎨 反链面板支持文档排序 https://github.com/siyuan-note/insider/issues/1086
This commit is contained in:
parent
7388c0d2a7
commit
e34e7fe217
4 changed files with 64 additions and 3 deletions
|
|
@ -89,7 +89,17 @@ func getBacklink2(c *gin.Context) {
|
|||
id := arg["id"].(string)
|
||||
keyword := arg["k"].(string)
|
||||
mentionKeyword := arg["mk"].(string)
|
||||
boxID, backlinks, backmentions, linkRefsCount, mentionsCount := model.GetBacklink2(id, keyword, mentionKeyword)
|
||||
sortArg := arg["sort"]
|
||||
sort := util.SortModeUpdatedDESC
|
||||
if nil != sortArg {
|
||||
sort = int(sortArg.(float64))
|
||||
}
|
||||
mentionSortArg := arg["msort"]
|
||||
mentionSort := util.SortModeUpdatedDESC
|
||||
if nil != mentionSortArg {
|
||||
sort = int(mentionSortArg.(float64))
|
||||
}
|
||||
boxID, backlinks, backmentions, linkRefsCount, mentionsCount := model.GetBacklink2(id, keyword, mentionKeyword, sort, mentionSort)
|
||||
ret.Data = map[string]interface{}{
|
||||
"backlinks": backlinks,
|
||||
"linkRefsCount": linkRefsCount,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue