support for note path

This commit is contained in:
azivner
2017-11-19 08:47:22 -05:00
parent cc3c9d6428
commit b22eb2db1e
7 changed files with 86 additions and 55 deletions

View File

@@ -8,7 +8,7 @@ const sync_table = require('./sync_table');
async function createNewNote(parentNoteId, note, browserId) {
const noteId = utils.newNoteId();
const noteTreeId = utils.newNoteId();
const noteTreeId = utils.newNoteTreeId();
let newNotePos = 0;
@@ -156,7 +156,7 @@ async function updateNote(noteId, newNote, ctx) {
await sql.doInTransaction(async () => {
if (!existingNoteHistoryId) {
const newNoteHistoryId = utils.randomString(16);
const newNoteHistoryId = utils.newNoteHistoryId();
await sql.execute("insert into notes_history (note_history_id, note_id, note_title, note_text, is_protected, date_modified_from, date_modified_to) " +
"values (?, ?, ?, ?, ?, ?, ?)", [