diff options
author | Pouyan Savoli <papoola@hotmail.com> | 2017-09-05 02:34:18 +0200 |
---|---|---|
committer | Pouyan Savoli <papoola@hotmail.com> | 2017-09-22 22:59:32 +0200 |
commit | 6ff89b43b61ace7ea26d50f091ea6b714fa79c84 (patch) | |
tree | 362c1bc771df9d20ab756cd4d8f26cf9f2d10246 /client/components/cards/cardCustomFields.js | |
parent | 733b14dcd8f4b94047ffd444e7ab7ded49c245c0 (diff) | |
download | wekan-6ff89b43b61ace7ea26d50f091ea6b714fa79c84.tar.gz wekan-6ff89b43b61ace7ea26d50f091ea6b714fa79c84.tar.bz2 wekan-6ff89b43b61ace7ea26d50f091ea6b714fa79c84.zip |
show custom fields on cards but still with dummy value
Diffstat (limited to 'client/components/cards/cardCustomFields.js')
-rw-r--r-- | client/components/cards/cardCustomFields.js | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/client/components/cards/cardCustomFields.js b/client/components/cards/cardCustomFields.js new file mode 100644 index 00000000..73dda02e --- /dev/null +++ b/client/components/cards/cardCustomFields.js @@ -0,0 +1,41 @@ +Template.cardCustomFieldsPopup.events({ + 'click .js-select-field'(evt) { + const card = Cards.findOne(Session.get('currentCard')); + const customFieldId = this._id; + card.toggleCustomField(customFieldId); + evt.preventDefault(); + }, + 'click .js-configure-custom-fields'(evt) { + EscapeActions.executeUpTo('detailsPane'); + Sidebar.setView('customFields'); + evt.preventDefault(); + } +}); + +const CardCustomField = BlazeComponent.extendComponent({ + template() { + return 'cardCustomFieldText'; + }, + + onCreated() { + const self = this; + self.date = ReactiveVar(); + self.now = ReactiveVar(moment()); + }, + + value() { + return "this is the value"; + }, + + showISODate() { + return this.date.get().toISOString(); + }, + + events() { + return [{ + 'click .js-edit-date': Popup.open('editCardStartDate'), + }]; + }, +}); + +CardCustomField.register('cardCustomField');
\ No newline at end of file |