mirror of
https://github.com/wekan/wekan.git
synced 2025-04-22 04:57:07 -04:00
Fix : Setting overtime not working #1893
This commit is contained in:
parent
629fa91fa0
commit
3c6915e217
1 changed files with 6 additions and 3 deletions
|
@ -9,7 +9,6 @@ BlazeComponent.extendComponent({
|
|||
toggleOvertime() {
|
||||
this.card.setIsOvertime(!this.card.getIsOvertime());
|
||||
$('#overtime .materialCheckBox').toggleClass('is-checked');
|
||||
|
||||
$('#overtime').toggleClass('is-checked');
|
||||
},
|
||||
storeTime(spentTime, isOvertime) {
|
||||
|
@ -18,6 +17,7 @@ BlazeComponent.extendComponent({
|
|||
},
|
||||
deleteTime() {
|
||||
this.card.setSpentTime(null);
|
||||
this.card.setIsOvertime(false);
|
||||
},
|
||||
events() {
|
||||
return [
|
||||
|
@ -27,8 +27,11 @@ BlazeComponent.extendComponent({
|
|||
evt.preventDefault();
|
||||
|
||||
const spentTime = parseFloat(evt.target.time.value);
|
||||
const isOvertime = this.card.getIsOvertime();
|
||||
|
||||
//const isOvertime = this.card.getIsOvertime();
|
||||
let isOvertime = false;
|
||||
if ($('#overtime').attr('class').indexOf('is-checked') >= 0) {
|
||||
isOvertime = true;
|
||||
}
|
||||
if (spentTime >= 0) {
|
||||
this.storeTime(spentTime, isOvertime);
|
||||
Popup.close();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue