widgets can now listen to sync data changes

This commit is contained in:
zadam
2019-08-06 22:39:27 +02:00
parent fcd87b3e2d
commit bfbc124e78
8 changed files with 60 additions and 9 deletions

View File

@@ -244,7 +244,10 @@ class TabContext {
treeService.setNoteTitle(this.note.noteId, this.note.title);
await server.put('notes/' + this.note.noteId, this.note.dto);
const resp = await server.put('notes/' + this.note.noteId, this.note.dto);
this.note.dateModified = resp.dateModified;
this.note.utcDateModified = resp.utcDateModified;
if (this.note.isProtected) {
protectedSessionHolder.touchProtectedSession();
@@ -352,6 +355,12 @@ class TabContext {
this.$tabContent.find('.aa-input').autocomplete('close');
}
}
syncDataReceived(syncData) {
if (this.sidebar) {
this.sidebar.syncDataReceived(syncData);
}
}
}
export default TabContext;