mirror of
https://github.com/wekan/wekan.git
synced 2026-02-14 12:14:21 +01:00
Use Utils#getCurrentCard() everywhere in the code
This commit is contained in:
parent
7a6cfcb498
commit
fdf40f4584
10 changed files with 21 additions and 21 deletions
|
|
@ -15,7 +15,7 @@ BlazeComponent.extendComponent({
|
|||
const capitalizedMode = Utils.capitalize(mode);
|
||||
let thisId, searchId;
|
||||
if (mode === 'linkedcard' || mode === 'linkedboard') {
|
||||
thisId = Session.get('currentCard');
|
||||
thisId = Utils.getCurrentCardId();
|
||||
searchId = Cards.findOne({ _id: thisId }).linkedId;
|
||||
mode = mode.replace('linked', '');
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ function resetCommentInput(input) {
|
|||
// Tracker.autorun to register the component dependencies, and re-run when these
|
||||
// dependencies are invalidated. A better component API would remove this hack.
|
||||
Tracker.autorun(() => {
|
||||
Session.get('currentCard');
|
||||
Utils.getCurrentCardId();
|
||||
Tracker.afterFlush(() => {
|
||||
autosize.update($('.js-new-comment-input'));
|
||||
});
|
||||
|
|
@ -75,7 +75,7 @@ EscapeActions.register(
|
|||
() => {
|
||||
const draftKey = {
|
||||
fieldName: 'cardComment',
|
||||
docId: Session.get('currentCard'),
|
||||
docId: Utils.getCurrentCardId(),
|
||||
};
|
||||
const commentInput = $('.js-new-comment-input');
|
||||
const draft = commentInput.val().trim();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue