refactor: request changes
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Vicent Llopis 2022-05-20 13:16:47 +02:00
parent eeede417eb
commit 875e9503c3
2 changed files with 4 additions and 7 deletions

View File

@ -158,7 +158,7 @@ INSERT INTO `vn`.`shelving` (`code`, `parkingFk`, `isPrinted`, `priority`, `park
INSERT INTO `vn`.`accountingType`(`id`, `description`, `receiptDescription`,`code`, `maxAmount`, `daysInFuture`)
VALUES
(1, 'CC y Polizas de crédito', 'Transferencias', 'wireTransfer', NULL, 1),
(1, 'CC and credit policies', 'Transfers', 'wireTransfer', NULL, 1),
(2, 'Cash', 'Cash', 'cash', 1000, 0),
(3, 'Credit card', 'Credit Card', 'creditCard', NULL, 0),
(4, 'Finalcial lines', NULL, NULL, NULL, 0),

View File

@ -68,12 +68,9 @@ class Controller extends Dialog {
}
this.maxAmount = accountingType && accountingType.maxAmount;
if (accountingType.daysInFuture) {
const date = new Date();
date.setDate(date.getDate() + accountingType.daysInFuture);
this.receipt.payed = date;
} else
this.receipt.payed = new Date();
this.receipt.payed = new Date();
if (accountingType.daysInFuture)
this.receipt.payed.setDate(this.receipt.payed.getDate() + accountingType.daysInFuture);
}
}