mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 23:40:13 +01:00
replace Session key popupCard with popupCardId (better meaning of what the variable contains)
This commit is contained in:
parent
4733afe4eb
commit
f4a3363f6f
6 changed files with 14 additions and 14 deletions
|
|
@ -546,7 +546,7 @@ Template.cardDetails.helpers({
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Template.cardDetailsPopup.onDestroyed(() => {
|
Template.cardDetailsPopup.onDestroyed(() => {
|
||||||
Session.delete('popupCard');
|
Session.delete('popupCardId');
|
||||||
Session.delete('popupCardBoardId');
|
Session.delete('popupCardBoardId');
|
||||||
});
|
});
|
||||||
Template.cardDetailsPopup.helpers({
|
Template.cardDetailsPopup.helpers({
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ BlazeComponent.extendComponent({
|
||||||
const boardId = this.currentData().boardId;
|
const boardId = this.currentData().boardId;
|
||||||
Meteor.subscribe('popupCardData', cardId, {
|
Meteor.subscribe('popupCardData', cardId, {
|
||||||
onReady() {
|
onReady() {
|
||||||
Session.set('popupCard', cardId);
|
Session.set('popupCardId', cardId);
|
||||||
Session.set('popupCardBoardId', boardId);
|
Session.set('popupCardBoardId', boardId);
|
||||||
this_.cardDetailsPopup(evt);
|
this_.cardDetailsPopup(evt);
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -150,7 +150,7 @@ BlazeComponent.extendComponent({
|
||||||
// overwriting the event in case the card is already selected.
|
// overwriting the event in case the card is already selected.
|
||||||
} else if (Utils.isMiniScreen()) {
|
} else if (Utils.isMiniScreen()) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
Session.set('popupCard', this.currentData()._id);
|
Session.set('popupCardId', this.currentData()._id);
|
||||||
this.cardDetailsPopup(evt);
|
this.cardDetailsPopup(evt);
|
||||||
} else if (Session.equals('currentCard', this.currentData()._id)) {
|
} else if (Session.equals('currentCard', this.currentData()._id)) {
|
||||||
evt.stopImmediatePropagation();
|
evt.stopImmediatePropagation();
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ BlazeComponent.extendComponent({
|
||||||
clickOnMiniCard(evt) {
|
clickOnMiniCard(evt) {
|
||||||
if (Utils.isMiniScreen()) {
|
if (Utils.isMiniScreen()) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
Session.set('popupCard', this.currentData()._id);
|
Session.set('popupCardId', this.currentData()._id);
|
||||||
this.cardDetailsPopup(evt);
|
this.cardDetailsPopup(evt);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@ Utils = {
|
||||||
return ret;
|
return ret;
|
||||||
},
|
},
|
||||||
getPopupCardId() {
|
getPopupCardId() {
|
||||||
const ret = Session.get('popupCard');
|
const ret = Session.get('popupCardId');
|
||||||
return ret;
|
return ret;
|
||||||
},
|
},
|
||||||
/** returns the current board
|
/** returns the current board
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ FlowRouter.route('/', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
@ -36,7 +36,7 @@ FlowRouter.route('/public', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
@ -60,7 +60,7 @@ FlowRouter.route('/b/:id/:slug', {
|
||||||
const previousBoard = Session.get('currentBoard');
|
const previousBoard = Session.get('currentBoard');
|
||||||
Session.set('currentBoard', currentBoard);
|
Session.set('currentBoard', currentBoard);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
// If we close a card, we'll execute again this route action but we don't
|
// If we close a card, we'll execute again this route action but we don't
|
||||||
|
|
@ -90,7 +90,7 @@ FlowRouter.route('/b/:boardId/:slug/:cardId', {
|
||||||
|
|
||||||
Session.set('currentBoard', params.boardId);
|
Session.set('currentBoard', params.boardId);
|
||||||
Session.set('currentCard', params.cardId);
|
Session.set('currentCard', params.cardId);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Utils.manageCustomUI();
|
Utils.manageCustomUI();
|
||||||
|
|
@ -220,7 +220,7 @@ FlowRouter.route('/import/:source', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
Session.set('importSource', params.source);
|
Session.set('importSource', params.source);
|
||||||
|
|
||||||
|
|
@ -242,7 +242,7 @@ FlowRouter.route('/setting', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
@ -267,7 +267,7 @@ FlowRouter.route('/information', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
@ -291,7 +291,7 @@ FlowRouter.route('/people', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
@ -315,7 +315,7 @@ FlowRouter.route('/admin-reports', {
|
||||||
Session.set('currentBoard', null);
|
Session.set('currentBoard', null);
|
||||||
Session.set('currentList', null);
|
Session.set('currentList', null);
|
||||||
Session.set('currentCard', null);
|
Session.set('currentCard', null);
|
||||||
Session.set('popupCard', null);
|
Session.set('popupCardId', null);
|
||||||
Session.set('popupCardBoardId', null);
|
Session.set('popupCardBoardId', null);
|
||||||
|
|
||||||
Filter.reset();
|
Filter.reset();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue