mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 07:20:12 +01:00
Settings, "Show cards count" now shows also 1 card
This commit is contained in:
parent
40907ef1d8
commit
8475201db8
3 changed files with 5 additions and 5 deletions
|
|
@ -82,7 +82,7 @@ BlazeComponent.extendComponent({
|
||||||
|
|
||||||
showCardsCountForList(count) {
|
showCardsCountForList(count) {
|
||||||
const limit = this.limitToShowCardsCount();
|
const limit = this.limitToShowCardsCount();
|
||||||
return limit > 0 && count > limit;
|
return limit >= 0 && count > limit;
|
||||||
},
|
},
|
||||||
|
|
||||||
events() {
|
events() {
|
||||||
|
|
|
||||||
|
|
@ -143,7 +143,7 @@ template(name="changeSettingsPopup")
|
||||||
label.bold.clear
|
label.bold.clear
|
||||||
i.fa.fa-sort-numeric-asc
|
i.fa.fa-sort-numeric-asc
|
||||||
| {{_ 'show-cards-minimum-count'}}
|
| {{_ 'show-cards-minimum-count'}}
|
||||||
input#show-cards-count-at.inline-input.left(type="number" value="#{showCardsCountAt}" min="0")
|
input#show-cards-count-at.inline-input.left(type="number" value="#{showCardsCountAt}" min="-1")
|
||||||
label.bold.clear
|
label.bold.clear
|
||||||
i.fa.fa-calendar
|
i.fa.fa-calendar
|
||||||
| {{_ 'start-day-of-week'}}
|
| {{_ 'start-day-of-week'}}
|
||||||
|
|
|
||||||
|
|
@ -274,7 +274,7 @@ Template.changeSettingsPopup.events({
|
||||||
'keypress/paste #show-cards-count-at'() {
|
'keypress/paste #show-cards-count-at'() {
|
||||||
let keyCode = event.keyCode;
|
let keyCode = event.keyCode;
|
||||||
let charCode = String.fromCharCode(keyCode);
|
let charCode = String.fromCharCode(keyCode);
|
||||||
let regex = new RegExp("[0-9]");
|
let regex = new RegExp("[-0-9]");
|
||||||
let ret = regex.test(charCode);
|
let ret = regex.test(charCode);
|
||||||
return ret;
|
return ret;
|
||||||
},
|
},
|
||||||
|
|
@ -309,8 +309,8 @@ Template.changeSettingsPopup.events({
|
||||||
10,
|
10,
|
||||||
);
|
);
|
||||||
const currentUser = Meteor.user();
|
const currentUser = Meteor.user();
|
||||||
if (isNaN(minLimit)) {
|
if (isNaN(minLimit) || minLimit < -1) {
|
||||||
minLimit = 0;
|
minLimit = -1;
|
||||||
}
|
}
|
||||||
if (!isNaN(minLimit)) {
|
if (!isNaN(minLimit)) {
|
||||||
if (currentUser) {
|
if (currentUser) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue