This commit is contained in:
zadam
2023-11-03 12:23:14 +01:00
parent a45b801a84
commit 6dd466ddaf
9 changed files with 124 additions and 141 deletions

View File

@@ -119,7 +119,7 @@ class BNote extends AbstractBeccaEntity {
this.utcDateCreated = utcDateCreated || dateUtils.utcNowDateTime();
/** @type {string} */
this.utcDateModified = utcDateModified;
/**
/**
* set during the deletion operation, before it is completed (removed from becca completely)
* @type {boolean}
*/
@@ -784,7 +784,7 @@ class BNote extends AbstractBeccaEntity {
} else if (a.parentNote?.isHiddenCompletely()) {
return 1;
} else {
return -1;
return 0;
}
});
@@ -804,7 +804,7 @@ class BNote extends AbstractBeccaEntity {
const aBranch = becca.getBranchFromChildAndParent(a.noteId, this.noteId);
const bBranch = becca.getBranchFromChildAndParent(b.noteId, this.noteId);
return aBranch?.notePosition < bBranch?.notePosition ? -1 : 1;
return (aBranch?.notePosition - bBranch?.notePosition) || 0;
});
}