mirror of
https://github.com/zadam/trilium.git
synced 2025-11-06 05:15:59 +01:00
using whole note box to drag the box instead of special handle
This commit is contained in:
@@ -134,20 +134,12 @@ async function deleteRelation(req) {
|
||||
|
||||
let attribute = await repository.getEntity(`SELECT * FROM attributes WHERE isDeleted = 0 AND noteId = ? AND type = 'relation' AND name = ? AND value = ?`, [sourceNoteId, name, targetNoteId]);
|
||||
|
||||
if (!attribute) {
|
||||
attribute = new Attribute();
|
||||
attribute.noteId = sourceNoteId;
|
||||
attribute.name = name;
|
||||
attribute.type = 'relation';
|
||||
attribute.value = targetNoteId;
|
||||
|
||||
if (attribute) {
|
||||
attribute.isDeleted = true;
|
||||
await attribute.save();
|
||||
}
|
||||
|
||||
return attribute;
|
||||
}
|
||||
|
||||
|
||||
module.exports = {
|
||||
updateNoteAttributes,
|
||||
updateNoteAttribute,
|
||||
|
||||
Reference in New Issue
Block a user