Fix note being read-only after viewing note in trash
This commit is contained in:
parent
f7e9067660
commit
4aaec5f091
1 changed files with 3 additions and 2 deletions
|
@ -65,14 +65,15 @@
|
||||||
switch (val) {
|
switch (val) {
|
||||||
case 'view':
|
case 'view':
|
||||||
case 'merge':
|
case 'merge':
|
||||||
// If there's an existing editor, mark it as read-only. This allows for
|
|
||||||
// disabling an existing editable note (e.g., if there's a save error).
|
|
||||||
if (this.noteField) {
|
if (this.noteField) {
|
||||||
this.noteField.onInit(ed => ed.setMode('readonly'));
|
this.noteField.onInit(ed => ed.setMode('readonly'));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'edit':
|
case 'edit':
|
||||||
|
if (this.noteField) {
|
||||||
|
this.noteField.onInit(ed => ed.setMode('design'));
|
||||||
|
}
|
||||||
this.editable = true;
|
this.editable = true;
|
||||||
this.saveOnEdit = true;
|
this.saveOnEdit = true;
|
||||||
this.parentClickHandler = this.selectParent;
|
this.parentClickHandler = this.selectParent;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue