mirror of
https://github.com/laurent22/joplin.git
synced 2025-03-26 21:12:59 +02:00
All: Fixed note update issue
This commit is contained in:
parent
4de1edda05
commit
7f1a14fa22
@ -10,5 +10,5 @@ git tag $VERSION
|
||||
git push && git push --tags
|
||||
|
||||
echo "Create a draft release at: https://github.com/laurent22/joplin/releases/tag/$VERSION"
|
||||
|
||||
node "$APP_DIR/update-readme-download.js" $VERSION
|
||||
echo ""
|
||||
echo "Then run $APP_DIR/update-readme-download.js"
|
@ -35,9 +35,14 @@ shared.saveNoteButton_press = async function(comp) {
|
||||
}
|
||||
|
||||
// Save only the properties that have changed
|
||||
const diff = BaseModel.diffObjects(comp.state.lastSavedNote, note);
|
||||
diff.type_ = note.type_;
|
||||
diff.id = note.id;
|
||||
let diff = null;
|
||||
if (!isNew) {
|
||||
diff = BaseModel.diffObjects(comp.state.lastSavedNote, note);
|
||||
diff.type_ = note.type_;
|
||||
diff.id = note.id;
|
||||
} else {
|
||||
diff = Object.assign({}, note);
|
||||
}
|
||||
|
||||
const savedNote = await Note.save(diff);
|
||||
|
||||
|
@ -289,7 +289,7 @@ const reducer = (state = defaultState, action) => {
|
||||
newState.notes = newNotes;
|
||||
|
||||
if (noteFolderHasChanged) {
|
||||
newState.selectedNoteIds = newNotes.length ? [newNotes[0].id] : null;
|
||||
newState.selectedNoteIds = newNotes.length ? [newNotes[0].id] : [];
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -310,7 +310,7 @@ async function initialize(dispatch, backButtonHandler) {
|
||||
if (Setting.value('env') == 'prod') {
|
||||
await db.open({ name: 'joplin.sqlite' })
|
||||
} else {
|
||||
await db.open({ name: 'joplin-66.sqlite' })
|
||||
await db.open({ name: 'joplin-67.sqlite' })
|
||||
//await db.open({ name: 'joplin-67.sqlite' })
|
||||
|
||||
// await db.exec('DELETE FROM notes');
|
||||
|
Loading…
x
Reference in New Issue
Block a user