mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 23:40:13 +01:00
At right sidebar, moved Minicard Settings to Card Settings popup.
Thanks to xet7 !
This commit is contained in:
parent
80db4cd645
commit
2f2a039e3c
2 changed files with 59 additions and 106 deletions
|
|
@ -175,7 +175,7 @@ template(name="boardInfoOnMyBoardsPopup")
|
||||||
|
|
||||||
template(name="boardCardSettingsPopup")
|
template(name="boardCardSettingsPopup")
|
||||||
form.board-card-settings
|
form.board-card-settings
|
||||||
h3 {{_ 'show-on-card'}}
|
h3 {{_ 'show-on-card'}}, {{_ 'show-on-minicard'}}
|
||||||
div.check-div
|
div.check-div
|
||||||
a.flex.js-field-has-receiveddate(class="{{#if allowsReceivedDate}}is-checked{{/if}}")
|
a.flex.js-field-has-receiveddate(class="{{#if allowsReceivedDate}}is-checked{{/if}}")
|
||||||
.materialCheckBox(class="{{#if allowsReceivedDate}}is-checked{{/if}}")
|
.materialCheckBox(class="{{#if allowsReceivedDate}}is-checked{{/if}}")
|
||||||
|
|
@ -206,14 +206,12 @@ template(name="boardCardSettingsPopup")
|
||||||
span
|
span
|
||||||
i.fa.fa-users
|
i.fa.fa-users
|
||||||
| {{_ 'members'}}
|
| {{_ 'members'}}
|
||||||
|
|
||||||
div.check-div
|
div.check-div
|
||||||
a.flex.js-field-has-creator(class="{{#if allowsCreator}}is-checked{{/if}}")
|
a.flex.js-field-has-creator(class="{{#if allowsCreator}}is-checked{{/if}}")
|
||||||
.materialCheckBox(class="{{#if allowsCreator}}is-checked{{/if}}")
|
.materialCheckBox(class="{{#if allowsCreator}}is-checked{{/if}}")
|
||||||
span
|
span
|
||||||
i.fa.fa-user
|
i.fa.fa-user
|
||||||
| {{_ 'creator'}}
|
| {{_ 'creator'}}
|
||||||
|
|
||||||
div.check-div
|
div.check-div
|
||||||
a.flex.js-field-has-assignee(class="{{#if allowsAssignee}}is-checked{{/if}}")
|
a.flex.js-field-has-assignee(class="{{#if allowsAssignee}}is-checked{{/if}}")
|
||||||
.materialCheckBox(class="{{#if allowsAssignee}}is-checked{{/if}}")
|
.materialCheckBox(class="{{#if allowsAssignee}}is-checked{{/if}}")
|
||||||
|
|
@ -238,6 +236,12 @@ template(name="boardCardSettingsPopup")
|
||||||
span
|
span
|
||||||
i.fa.fa-sort
|
i.fa.fa-sort
|
||||||
| {{_ 'card-sorting-by-number'}}
|
| {{_ 'card-sorting-by-number'}}
|
||||||
|
div.check-div
|
||||||
|
a.flex.js-field-has-card-sorting-by-number-on-minicard(class="{{#if allowsCardSortingByNumberOnMinicard}}is-checked{{/if}}")
|
||||||
|
.materialCheckBox(class="{{#if allowsCardSortingByNumberOnMinicard}}is-checked{{/if}}")
|
||||||
|
span
|
||||||
|
i.fa.fa-sort
|
||||||
|
| {{_ 'card-sorting-by-number-on-minicard'}}
|
||||||
div.check-div
|
div.check-div
|
||||||
a.flex.js-field-has-card-show-lists(class="{{#if allowsShowLists}}is-checked{{/if}}")
|
a.flex.js-field-has-card-show-lists(class="{{#if allowsShowLists}}is-checked{{/if}}")
|
||||||
.materialCheckBox(class="{{#if allowsShowLists}}is-checked{{/if}}")
|
.materialCheckBox(class="{{#if allowsShowLists}}is-checked{{/if}}")
|
||||||
|
|
@ -271,6 +275,12 @@ template(name="boardCardSettingsPopup")
|
||||||
i.fa.fa-align-left
|
i.fa.fa-align-left
|
||||||
| {{_ 'description'}}
|
| {{_ 'description'}}
|
||||||
| {{_ 'custom-field-text'}}
|
| {{_ 'custom-field-text'}}
|
||||||
|
div.check-div
|
||||||
|
a.flex.js-field-has-description-text-on-minicard(class="{{#if allowsDescriptionTextOnMinicard}}is-checked{{/if}}")
|
||||||
|
.materialCheckBox(class="{{#if allowsDescriptionTextOnMinicard}}is-checked{{/if}}")
|
||||||
|
span
|
||||||
|
i.fa.fa-align-left
|
||||||
|
| {{_ 'description-on-minicard'}}
|
||||||
div.check-div
|
div.check-div
|
||||||
a.flex.js-field-has-checklists(class="{{#if allowsChecklists}}is-checked{{/if}}")
|
a.flex.js-field-has-checklists(class="{{#if allowsChecklists}}is-checked{{/if}}")
|
||||||
.materialCheckBox(class="{{#if allowsChecklists}}is-checked{{/if}}")
|
.materialCheckBox(class="{{#if allowsChecklists}}is-checked{{/if}}")
|
||||||
|
|
@ -289,6 +299,19 @@ template(name="boardCardSettingsPopup")
|
||||||
span
|
span
|
||||||
i.fa.fa-paperclip
|
i.fa.fa-paperclip
|
||||||
| {{_ 'attachments'}}
|
| {{_ 'attachments'}}
|
||||||
|
div.check-div
|
||||||
|
a.flex.js-field-has-badge-attachment-on-minicard(class="{{#if allowsBadgeAttachmentOnMinicard}}is-checked{{/if}}")
|
||||||
|
.materialCheckBox(class="{{#if allowsBadgeAttachmentOnMinicard}}is-checked{{/if}}")
|
||||||
|
span
|
||||||
|
i.fa.fa-paperclip
|
||||||
|
| {{_ 'badge-attachment-on-minicard'}}
|
||||||
|
div.check-div
|
||||||
|
a.flex.js-field-has-cover-attachment-on-minicard(class="{{#if allowsCoverAttachmentOnMinicard}}is-checked{{/if}}")
|
||||||
|
.materialCheckBox(class="{{#if allowsCoverAttachmentOnMinicard}}is-checked{{/if}}")
|
||||||
|
span
|
||||||
|
i.fa.fa-book
|
||||||
|
i.fa.fa-picture-o
|
||||||
|
| {{_ 'cover-attachment-on-minicard'}}
|
||||||
//div.check-div
|
//div.check-div
|
||||||
// a.flex.js-field-has-comments(class="{{#if allowsComments}}is-checked{{/if}}")
|
// a.flex.js-field-has-comments(class="{{#if allowsComments}}is-checked{{/if}}")
|
||||||
// .materialCheckBox(class="{{#if allowsComments}}is-checked{{/if}}")
|
// .materialCheckBox(class="{{#if allowsComments}}is-checked{{/if}}")
|
||||||
|
|
@ -302,35 +325,6 @@ template(name="boardCardSettingsPopup")
|
||||||
// i.fa.fa-history
|
// i.fa.fa-history
|
||||||
// | {{_ 'activities'}}
|
// | {{_ 'activities'}}
|
||||||
|
|
||||||
template(name="boardMinicardSettingsPopup")
|
|
||||||
form.board-minicard-settings
|
|
||||||
h3 {{_ 'show-on-minicard'}}
|
|
||||||
div.check-div
|
|
||||||
a.flex.js-field-has-description-text-on-minicard(class="{{#if allowsDescriptionTextOnMinicard}}is-checked{{/if}}")
|
|
||||||
.materialCheckBox(class="{{#if allowsDescriptionTextOnMinicard}}is-checked{{/if}}")
|
|
||||||
span
|
|
||||||
i.fa.fa-align-left
|
|
||||||
| {{_ 'description-on-minicard'}}
|
|
||||||
div.check-div
|
|
||||||
a.flex.js-field-has-cover-attachment-on-minicard(class="{{#if allowsCoverAttachmentOnMinicard}}is-checked{{/if}}")
|
|
||||||
.materialCheckBox(class="{{#if allowsCoverAttachmentOnMinicard}}is-checked{{/if}}")
|
|
||||||
span
|
|
||||||
i.fa.fa-book
|
|
||||||
i.fa.fa-picture-o
|
|
||||||
| {{_ 'cover-attachment-on-minicard'}}
|
|
||||||
div.check-div
|
|
||||||
a.flex.js-field-has-badge-attachment-on-minicard(class="{{#if allowsBadgeAttachmentOnMinicard}}is-checked{{/if}}")
|
|
||||||
.materialCheckBox(class="{{#if allowsBadgeAttachmentOnMinicard}}is-checked{{/if}}")
|
|
||||||
span
|
|
||||||
i.fa.fa-paperclip
|
|
||||||
| {{_ 'badge-attachment-on-minicard'}}
|
|
||||||
div.check-div
|
|
||||||
a.flex.js-field-has-card-sorting-by-number-on-minicard(class="{{#if allowsCardSortingByNumberOnMinicard}}is-checked{{/if}}")
|
|
||||||
.materialCheckBox(class="{{#if allowsCardSortingByNumberOnMinicard}}is-checked{{/if}}")
|
|
||||||
span
|
|
||||||
i.fa.fa-sort
|
|
||||||
| {{_ 'card-sorting-by-number-on-minicard'}}
|
|
||||||
|
|
||||||
template(name="boardSubtaskSettingsPopup")
|
template(name="boardSubtaskSettingsPopup")
|
||||||
form.board-subtask-settings
|
form.board-subtask-settings
|
||||||
h3 {{_ 'show-parent-in-minicard'}}
|
h3 {{_ 'show-parent-in-minicard'}}
|
||||||
|
|
@ -473,10 +467,6 @@ template(name="boardMenuPopup")
|
||||||
a.js-card-settings
|
a.js-card-settings
|
||||||
i.fa.fa-id-card-o
|
i.fa.fa-id-card-o
|
||||||
| {{_ 'card-settings'}}
|
| {{_ 'card-settings'}}
|
||||||
li
|
|
||||||
a.js-minicard-settings
|
|
||||||
i.fa.fa-id-card-o
|
|
||||||
| {{_ 'minicard-settings'}}
|
|
||||||
li
|
li
|
||||||
a.js-subtask-settings
|
a.js-subtask-settings
|
||||||
i.fa.fa-sitemap
|
i.fa.fa-sitemap
|
||||||
|
|
|
||||||
|
|
@ -236,7 +236,6 @@ Template.boardMenuPopup.events({
|
||||||
'click .js-import-board': Popup.open('chooseBoardSource'),
|
'click .js-import-board': Popup.open('chooseBoardSource'),
|
||||||
'click .js-subtask-settings': Popup.open('boardSubtaskSettings'),
|
'click .js-subtask-settings': Popup.open('boardSubtaskSettings'),
|
||||||
'click .js-card-settings': Popup.open('boardCardSettings'),
|
'click .js-card-settings': Popup.open('boardCardSettings'),
|
||||||
'click .js-minicard-settings': Popup.open('boardMinicardSettings'),
|
|
||||||
'click .js-export-board': Popup.open('exportBoard'),
|
'click .js-export-board': Popup.open('exportBoard'),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -984,6 +983,22 @@ BlazeComponent.extendComponent({
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
allowsDescriptionTextOnMinicard() {
|
||||||
|
return this.currentBoard.allowsDescriptionTextOnMinicard;
|
||||||
|
},
|
||||||
|
|
||||||
|
allowsCoverAttachmentOnMinicard() {
|
||||||
|
return this.currentBoard.allowsCoverAttachmentOnMinicard;
|
||||||
|
},
|
||||||
|
|
||||||
|
allowsBadgeAttachmentOnMinicard() {
|
||||||
|
return this.currentBoard.allowsBadgeAttachmentOnMinicard;
|
||||||
|
},
|
||||||
|
|
||||||
|
allowsCardSortingByNumberOnMinicard() {
|
||||||
|
return this.currentBoard.allowsCardSortingByNumberOnMinicard;
|
||||||
|
},
|
||||||
|
|
||||||
boards() {
|
boards() {
|
||||||
const ret = ReactiveCache.getBoards(
|
const ret = ReactiveCache.getBoards(
|
||||||
{
|
{
|
||||||
|
|
@ -1241,6 +1256,22 @@ BlazeComponent.extendComponent({
|
||||||
this.currentBoard.allowsCardNumber,
|
this.currentBoard.allowsCardNumber,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
'click .js-field-has-description-text-on-minicard'(evt) {
|
||||||
|
evt.preventDefault();
|
||||||
|
this.currentBoard.allowsDescriptionTextOnMinicard = !this.currentBoard
|
||||||
|
.allowsDescriptionTextOnMinicard;
|
||||||
|
this.currentBoard.setallowsDescriptionTextOnMinicard(
|
||||||
|
this.currentBoard.allowsDescriptionTextOnMinicard,
|
||||||
|
);
|
||||||
|
$(`.js-field-has-description-text-on-minicard ${MCB}`).toggleClass(
|
||||||
|
CKCLS,
|
||||||
|
this.currentBoard.allowsDescriptionTextOnMinicard,
|
||||||
|
);
|
||||||
|
$('.js-field-has-description-text-on-minicard').toggleClass(
|
||||||
|
CKCLS,
|
||||||
|
this.currentBoard.allowsDescriptionTextOnMinicard,
|
||||||
|
);
|
||||||
|
},
|
||||||
'click .js-field-has-description-text'(evt) {
|
'click .js-field-has-description-text'(evt) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
this.currentBoard.allowsDescriptionText = !this.currentBoard
|
this.currentBoard.allowsDescriptionText = !this.currentBoard
|
||||||
|
|
@ -1318,74 +1349,6 @@ BlazeComponent.extendComponent({
|
||||||
this.currentBoard.allowsActivities,
|
this.currentBoard.allowsActivities,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
},
|
|
||||||
];
|
|
||||||
},
|
|
||||||
}).register('boardCardSettingsPopup');
|
|
||||||
|
|
||||||
|
|
||||||
BlazeComponent.extendComponent({
|
|
||||||
onCreated() {
|
|
||||||
this.currentBoard = Utils.getCurrentBoard();
|
|
||||||
},
|
|
||||||
|
|
||||||
allowsDescriptionTextOnMinicard() {
|
|
||||||
return this.currentBoard.allowsDescriptionTextOnMinicard;
|
|
||||||
},
|
|
||||||
|
|
||||||
allowsCoverAttachmentOnMinicard() {
|
|
||||||
return this.currentBoard.allowsCoverAttachmentOnMinicard;
|
|
||||||
},
|
|
||||||
|
|
||||||
allowsBadgeAttachmentOnMinicard() {
|
|
||||||
return this.currentBoard.allowsBadgeAttachmentOnMinicard;
|
|
||||||
},
|
|
||||||
|
|
||||||
allowsCardSortingByNumberOnMinicard() {
|
|
||||||
return this.currentBoard.allowsCardSortingByNumberOnMinicard;
|
|
||||||
},
|
|
||||||
|
|
||||||
lists() {
|
|
||||||
return ReactiveCache.getLists(
|
|
||||||
{
|
|
||||||
boardId: this.currentBoard._id,
|
|
||||||
archived: false,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
sort: ['title'],
|
|
||||||
},
|
|
||||||
);
|
|
||||||
},
|
|
||||||
|
|
||||||
hasLists() {
|
|
||||||
return this.lists().length > 0;
|
|
||||||
},
|
|
||||||
|
|
||||||
isListSelected() {
|
|
||||||
return (
|
|
||||||
this.currentBoard.dateSettingsDefaultBoardId === this.currentData()._id
|
|
||||||
);
|
|
||||||
},
|
|
||||||
|
|
||||||
events() {
|
|
||||||
return [
|
|
||||||
{
|
|
||||||
'click .js-field-has-description-text-on-minicard'(evt) {
|
|
||||||
evt.preventDefault();
|
|
||||||
this.currentBoard.allowsDescriptionTextOnMinicard = !this.currentBoard
|
|
||||||
.allowsDescriptionTextOnMinicard;
|
|
||||||
this.currentBoard.setallowsDescriptionTextOnMinicard(
|
|
||||||
this.currentBoard.allowsDescriptionTextOnMinicard,
|
|
||||||
);
|
|
||||||
$(`.js-field-has-description-text-on-minicard ${MCB}`).toggleClass(
|
|
||||||
CKCLS,
|
|
||||||
this.currentBoard.allowsDescriptionTextOnMinicard,
|
|
||||||
);
|
|
||||||
$('.js-field-has-description-text-on-minicard').toggleClass(
|
|
||||||
CKCLS,
|
|
||||||
this.currentBoard.allowsDescriptionTextOnMinicard,
|
|
||||||
);
|
|
||||||
},
|
|
||||||
'click .js-field-has-cover-attachment-on-minicard'(evt) {
|
'click .js-field-has-cover-attachment-on-minicard'(evt) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
this.currentBoard.allowsCoverAttachmentOnMinicard = !this.currentBoard
|
this.currentBoard.allowsCoverAttachmentOnMinicard = !this.currentBoard
|
||||||
|
|
@ -1437,7 +1400,7 @@ BlazeComponent.extendComponent({
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
},
|
},
|
||||||
}).register('boardMinicardSettingsPopup');
|
}).register('boardCardSettingsPopup');
|
||||||
|
|
||||||
BlazeComponent.extendComponent({
|
BlazeComponent.extendComponent({
|
||||||
onCreated() {
|
onCreated() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue