mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 07:00:12 +01:00
🐛 After changing the History Retention Days, the file history cannot be displayed https://github.com/siyuan-note/siyuan/issues/11935
This commit is contained in:
parent
f566ef4abc
commit
e4541c9d5f
3 changed files with 6 additions and 6 deletions
|
|
@ -446,7 +446,7 @@ func buildSearchHistoryQueryFilter(query, op, box, table string, typ int) (stmt
|
|||
}
|
||||
|
||||
ago := time.Now().Add(-24 * time.Hour * time.Duration(Conf.Editor.HistoryRetentionDays))
|
||||
stmt += " AND created > '" + fmt.Sprintf("%d", ago.Unix()) + "'"
|
||||
stmt += " AND CAST(created AS INTEGER) > " + fmt.Sprintf("%d", ago.Unix()) + ""
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -619,7 +619,7 @@ func clearOutdatedHistoryDir(historyDir string) {
|
|||
}
|
||||
|
||||
// 清理历史库
|
||||
sql.DeleteOutdatedHistories(fmt.Sprintf("%d", ago))
|
||||
sql.DeleteOutdatedHistories(ago)
|
||||
}
|
||||
|
||||
var boxLatestHistoryTime = map[string]time.Time{}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue