summaryrefslogtreecommitdiffstats
path: root/client/components/lists/listHeader.js
diff options
context:
space:
mode:
authoramadilsons <joao.amado.95@gmail.com>2017-09-29 16:52:53 +0200
committeramadilsons <joao.amado.95@gmail.com>2017-09-29 16:52:53 +0200
commita918d36533bd61765f954f60c0e3af78b014907a (patch)
treee3c54f048ca5ef1470476aa917fbe3abd088b41a /client/components/lists/listHeader.js
parentc9c650664fd92f0924afb4548a50c7bca167d955 (diff)
downloadwekan-a918d36533bd61765f954f60c0e3af78b014907a.tar.gz
wekan-a918d36533bd61765f954f60c0e3af78b014907a.tar.bz2
wekan-a918d36533bd61765f954f60c0e3af78b014907a.zip
mostly frontend work, lists coll update with wipLimit field
Diffstat (limited to 'client/components/lists/listHeader.js')
-rw-r--r--client/components/lists/listHeader.js20
1 files changed, 15 insertions, 5 deletions
diff --git a/client/components/lists/listHeader.js b/client/components/lists/listHeader.js
index 47fddd27..0dc15315 100644
--- a/client/components/lists/listHeader.js
+++ b/client/components/lists/listHeader.js
@@ -8,6 +8,10 @@ BlazeComponent.extendComponent({
}
},
+ hasWipLimit() {
+ return this.currentData().wipLimit > 0 ? true : false;
+ },
+
isWatching() {
const list = this.currentData();
return list.findWatcher(Meteor.userId());
@@ -21,11 +25,6 @@ BlazeComponent.extendComponent({
return count > this.limitToShowCardsCount();
},
- hasWipLimit() {
- return null;
- //return this.currentData().wipLimit ? true : false;
- },
-
events() {
return [{
'click .js-open-list-menu': Popup.open('listAction'),
@@ -42,6 +41,10 @@ BlazeComponent.extendComponent({
}).register('listHeader');
Template.listActionPopup.helpers({
+ hasWipLimit() {
+ return this.wipLimit > 0 ? true : false;
+ },
+
isWatching() {
return this.findWatcher(Meteor.userId());
},
@@ -70,6 +73,13 @@ Template.listActionPopup.events({
'click .js-more': Popup.open('listMore'),
});
+Template.setWipLimitPopup.events({
+ 'click .wip-limit-apply'(_, instance) {
+ const limit = instance.$('.wip-limit-value').val();
+ this.setWipLimit(limit);
+ },
+});
+
Template.listMorePopup.events({
'click .js-delete': Popup.afterConfirm('listDelete', function () {
Popup.close();