diff options
-rw-r--r-- | CHANGELOG.md | 8 | ||||
-rw-r--r-- | Stackerfile.yml | 2 | ||||
-rw-r--r-- | client/components/boards/boardHeader.jade | 30 | ||||
-rw-r--r-- | client/components/boards/boardHeader.js | 53 | ||||
-rw-r--r-- | client/components/sidebar/sidebar.jade | 30 | ||||
-rw-r--r-- | models/activities.js | 24 | ||||
-rw-r--r-- | package.json | 2 | ||||
-rw-r--r-- | sandstorm-pkgdef.capnp | 4 | ||||
-rw-r--r-- | server/notifications/outgoing.js | 3 |
9 files changed, 110 insertions, 46 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ef87aae..e9eac1dd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +# v2.37 2019-03-04 Wekan release + +This release fixes the following bugs: + +- [Fix Adding Labels to cards is not possible anymore](https://github.com/wekan/wekan/issues/2223). + +Thanks to GitHub user xet7 for contributions. + # v2.36 2019-03-03 Wekan release This release adds the following UI changes: diff --git a/Stackerfile.yml b/Stackerfile.yml index 33c0d388..f4f1f655 100644 --- a/Stackerfile.yml +++ b/Stackerfile.yml @@ -1,5 +1,5 @@ appId: wekan-public/apps/77b94f60-dec9-0136-304e-16ff53095928 -appVersion: "v2.36.0" +appVersion: "v2.37.0" files: userUploads: - README.md diff --git a/client/components/boards/boardHeader.jade b/client/components/boards/boardHeader.jade index 78b05c84..823bd806 100644 --- a/client/components/boards/boardHeader.jade +++ b/client/components/boards/boardHeader.jade @@ -133,6 +133,36 @@ template(name="boardVisibilityList") i.fa.fa-check span.sub-name {{_ 'public-desc'}} +template(name="boardChangeVisibilityPopup") + +boardVisibilityList + +template(name="boardChangeWatchPopup") + ul.pop-over-list + li + with "watching" + a.js-select-watch + i.fa.fa-eye.colorful + | {{_ 'watching'}} + if watchCheck + i.fa.fa-check + span.sub-name {{_ 'watching-info'}} + li + with "tracking" + a.js-select-watch + i.fa.fa-bell.colorful + | {{_ 'tracking'}} + if watchCheck + i.fa.fa-check + span.sub-name {{_ 'tracking-info'}} + li + with "muted" + a.js-select-watch + i.fa.fa-bell-slash.colorful + | {{_ 'muted'}} + if watchCheck + i.fa.fa-check + span.sub-name {{_ 'muted-info'}} + template(name="createBoard") form label diff --git a/client/components/boards/boardHeader.js b/client/components/boards/boardHeader.js index 08fcd473..86fbebb3 100644 --- a/client/components/boards/boardHeader.js +++ b/client/components/boards/boardHeader.js @@ -1,3 +1,49 @@ +Template.boardMenuPopup.events({ + 'click .js-rename-board': Popup.open('boardChangeTitle'), + 'click .js-custom-fields'() { + Sidebar.setView('customFields'); + Popup.close(); + }, + 'click .js-open-archives'() { + Sidebar.setView('archives'); + Popup.close(); + }, + 'click .js-change-board-color': Popup.open('boardChangeColor'), + 'click .js-change-language': Popup.open('changeLanguage'), + 'click .js-archive-board ': Popup.afterConfirm('archiveBoard', function() { + const currentBoard = Boards.findOne(Session.get('currentBoard')); + currentBoard.archive(); + // XXX We should have some kind of notification on top of the page to + // confirm that the board was successfully archived. + FlowRouter.go('home'); + }), + 'click .js-delete-board': Popup.afterConfirm('deleteBoard', function() { + const currentBoard = Boards.findOne(Session.get('currentBoard')); + Popup.close(); + Boards.remove(currentBoard._id); + FlowRouter.go('home'); + }), + 'click .js-outgoing-webhooks': Popup.open('outgoingWebhooks'), + 'click .js-import-board': Popup.open('chooseBoardSource'), + 'click .js-subtask-settings': Popup.open('boardSubtaskSettings'), +}); + +Template.boardMenuPopup.helpers({ + exportUrl() { + const params = { + boardId: Session.get('currentBoard'), + }; + const queryParams = { + authToken: Accounts._storedLoginToken(), + }; + return FlowRouter.path('/api/boards/:boardId/export', params, queryParams); + }, + exportFilename() { + const boardId = Session.get('currentBoard'); + return `wekan-export-board-${boardId}.json`; + }, +}); + Template.boardChangeTitlePopup.events({ submit(evt, tpl) { const newTitle = tpl.$('.js-board-name').val().trim(); @@ -35,8 +81,12 @@ BlazeComponent.extendComponent({ 'click .js-star-board'() { Meteor.user().toggleBoardStar(Session.get('currentBoard')); }, + 'click .js-open-board-menu': Popup.open('boardMenu'), 'click .js-change-visibility': Popup.open('boardChangeVisibility'), 'click .js-watch-board': Popup.open('boardChangeWatch'), + 'click .js-open-archived-board'() { + Modal.open('archivedBoards'); + }, 'click .js-toggle-board-view'() { const currentUser = Meteor.user(); if (currentUser.profile.boardView === 'board-view-swimlanes') { @@ -136,6 +186,9 @@ const CreateBoard = BlazeComponent.extendComponent({ this.setVisibility(this.currentData()); }, 'click .js-change-visibility': this.toggleVisibilityMenu, + 'click .js-import': Popup.open('boardImportBoard'), + submit: this.onSubmit, + 'click .js-import-board': Popup.open('chooseBoardSource'), 'click .js-board-template': Popup.open('searchElement'), }]; }, diff --git a/client/components/sidebar/sidebar.jade b/client/components/sidebar/sidebar.jade index a7881656..4e4d355c 100644 --- a/client/components/sidebar/sidebar.jade +++ b/client/components/sidebar/sidebar.jade @@ -56,36 +56,6 @@ template(name="membersWidget") button.js-member-invite-accept.primary {{_ 'accept'}} button.js-member-invite-decline {{_ 'decline'}} -template(name="boardChangeVisibilityPopup") - +boardVisibilityList - -template(name="boardChangeWatchPopup") - ul.pop-over-list - li - with "watching" - a.js-select-watch - i.fa.fa-eye.colorful - | {{_ 'watching'}} - if watchCheck - i.fa.fa-check - span.sub-name {{_ 'watching-info'}} - li - with "tracking" - a.js-select-watch - i.fa.fa-bell.colorful - | {{_ 'tracking'}} - if watchCheck - i.fa.fa-check - span.sub-name {{_ 'tracking-info'}} - li - with "muted" - a.js-select-watch - i.fa.fa-bell-slash.colorful - | {{_ 'muted'}} - if watchCheck - i.fa.fa-check - span.sub-name {{_ 'muted-info'}} - template(name="boardChangeColorPopup") .board-backgrounds-list.clearfix each backgroundColors diff --git a/models/activities.js b/models/activities.js index b26278b1..84c45856 100644 --- a/models/activities.js +++ b/models/activities.js @@ -56,23 +56,22 @@ Activities.helpers({ customField() { return CustomFields.findOne(this.customFieldId); }, - label() { - return Labels.findOne(this.labelId); - }, + // Label activity did not work yet, unable to edit labels when tried this. + //label() { + // return Cards.findOne(this.labelId); + //}, }); Activities.before.insert((userId, doc) => { doc.createdAt = new Date(); }); - Activities.after.insert((userId, doc) => { const activity = Activities._transform(doc); RulesHelper.executeRules(activity); }); - if (Meteor.isServer) { // For efficiency create indexes on the date of creation, and on the date of // creation in conjunction with the card or board id, as corresponding views @@ -84,7 +83,9 @@ if (Meteor.isServer) { Activities._collection._ensureIndex({ commentId: 1 }, { partialFilterExpression: { commentId: { $exists: true } } }); Activities._collection._ensureIndex({ attachmentId: 1 }, { partialFilterExpression: { attachmentId: { $exists: true } } }); Activities._collection._ensureIndex({ customFieldId: 1 }, { partialFilterExpression: { customFieldId: { $exists: true } } }); - Activities._collection._ensureIndex({ labelId: 1 }, { partialFilterExpression: { labelId: { $exists: true } } }); + // Label activity did not work yet, unable to edit labels when tried this. + //Activities._collection._dropIndex({ labelId: 1 }, { "indexKey": -1 }); + //Activities._collection._dropIndex({ labelId: 1 }, { partialFilterExpression: { labelId: { $exists: true } } }); }); Activities.after.insert((userId, doc) => { @@ -173,11 +174,12 @@ if (Meteor.isServer) { const customField = activity.customField(); params.customField = customField.name; } - if (activity.labelId) { - const label = activity.label(); - params.label = label.name; - params.labelId = activity.labelId; - } + // Label activity did not work yet, unable to edit labels when tried this. + //if (activity.labelId) { + // const label = activity.label(); + // params.label = label.name; + // params.labelId = activity.labelId; + //} if (board) { const watchingUsers = _.pluck(_.where(board.watchers, {level: 'watching'}), 'userId'); const trackingUsers = _.pluck(_.where(board.watchers, {level: 'tracking'}), 'userId'); diff --git a/package.json b/package.json index a68abc52..46375210 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wekan", - "version": "v2.36.0", + "version": "v2.37.0", "description": "Open-Source kanban", "private": true, "scripts": { diff --git a/sandstorm-pkgdef.capnp b/sandstorm-pkgdef.capnp index 8d555c33..4933796e 100644 --- a/sandstorm-pkgdef.capnp +++ b/sandstorm-pkgdef.capnp @@ -22,10 +22,10 @@ const pkgdef :Spk.PackageDefinition = ( appTitle = (defaultText = "Wekan"), # The name of the app as it is displayed to the user. - appVersion = 238, + appVersion = 239, # Increment this for every release. - appMarketingVersion = (defaultText = "2.36.0~2019-03-03"), + appMarketingVersion = (defaultText = "2.37.0~2019-03-04"), # Human-readable presentation of the app version. minUpgradableAppVersion = 0, diff --git a/server/notifications/outgoing.js b/server/notifications/outgoing.js index ada3679e..257fbda1 100644 --- a/server/notifications/outgoing.js +++ b/server/notifications/outgoing.js @@ -16,8 +16,9 @@ Meteor.methods({ check(description, String); check(params, Object); + // label activity did not work yet, see wekan/models/activities.js const quoteParams = _.clone(params); - ['card', 'list', 'oldList', 'board', 'oldBoard', 'comment', 'checklist', 'label', 'swimlane', 'oldSwimlane'].forEach((key) => { + ['card', 'list', 'oldList', 'board', 'oldBoard', 'comment', 'checklist', 'swimlane', 'oldSwimlane'].forEach((key) => { if (quoteParams[key]) quoteParams[key] = `"${params[key]}"`; }); |