mirror of
https://github.com/wekan/wekan.git
synced 2026-02-08 09:24:20 +01:00
- Fix card copy & move between boards with customFields
- Fix card copy & move between boards with labels with same name - Fix activities for labels when copying and moving card - Fix activities for customFields when copying and moving card
This commit is contained in:
parent
4cd0d1c397
commit
d01fccd949
9 changed files with 179 additions and 34 deletions
|
|
@ -116,15 +116,22 @@ const CreateCustomFieldPopup = BlazeComponent.extendComponent({
|
|||
data.boardIds = [Session.get('currentBoard')];
|
||||
CustomFields.insert(data);
|
||||
} else {
|
||||
data.boardIds = {$in: [Session.get('currentBoard')]};
|
||||
CustomFields.update(this.data()._id, {$set: data});
|
||||
}
|
||||
|
||||
Popup.back();
|
||||
},
|
||||
'click .js-delete-custom-field': Popup.afterConfirm('deleteCustomField', function() {
|
||||
const customFieldId = this._id;
|
||||
CustomFields.remove(customFieldId);
|
||||
const customField = CustomFields.findOne(this._id);
|
||||
if (customField.boardIds.length > 1) {
|
||||
CustomFields.update(customField._id, {
|
||||
$pull: {
|
||||
boardIds: Session.get('currentBoard')
|
||||
}
|
||||
});
|
||||
} else {
|
||||
CustomFields.remove(customField._id);
|
||||
}
|
||||
Popup.close();
|
||||
}),
|
||||
}];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue