mirror of
https://github.com/zadam/trilium.git
synced 2025-02-20 21:13:11 +08:00
force note sync now syncs also note revision contents and attributes
This commit is contained in:
parent
69b53fdfb3
commit
d93b9b8a23
1 changed files with 6 additions and 1 deletions
|
@ -77,12 +77,17 @@ async function forceNoteSync(req) {
|
|||
await syncTableService.addNoteSync(noteId);
|
||||
await syncTableService.addNoteContentSync(noteId);
|
||||
|
||||
for (const branchId of await sql.getColumn("SELECT branchId FROM branches WHERE isDeleted = 0 AND noteId = ?", [noteId])) {
|
||||
for (const branchId of await sql.getColumn("SELECT branchId FROM branches WHERE noteId = ?", [noteId])) {
|
||||
await syncTableService.addBranchSync(branchId);
|
||||
}
|
||||
|
||||
for (const attributeId of await sql.getColumn("SELECT attributeId FROM attributes WHERE noteId = ?", [noteId])) {
|
||||
await syncTableService.addAttributeSync(attributeId);
|
||||
}
|
||||
|
||||
for (const noteRevisionId of await sql.getColumn("SELECT noteRevisionId FROM note_revisions WHERE noteId = ?", [noteId])) {
|
||||
await syncTableService.addNoteRevisionSync(noteRevisionId);
|
||||
await syncTableService.addNoteRevisionContentSync(noteRevisionId);
|
||||
}
|
||||
|
||||
await syncTableService.addRecentNoteSync(noteId);
|
||||
|
|
Loading…
Reference in a new issue