feat: pre create payment data
This commit is contained in:
parent
cbd8daccca
commit
648fb20bbc
1 changed files with 7 additions and 0 deletions
|
|
@ -448,6 +448,13 @@ export class QuotationController extends Controller {
|
||||||
data: {
|
data: {
|
||||||
...rest,
|
...rest,
|
||||||
...price,
|
...price,
|
||||||
|
quotationPaymentData: {
|
||||||
|
create: rest.paySplit?.map((v) => ({
|
||||||
|
paymentStatus: "PaymentWait",
|
||||||
|
amount: v.amount,
|
||||||
|
date: new Date(),
|
||||||
|
})),
|
||||||
|
},
|
||||||
statusOrder: +(rest.status === "INACTIVE"),
|
statusOrder: +(rest.status === "INACTIVE"),
|
||||||
code: `${currentYear.toString().padStart(2, "0")}${currentMonth.toString().padStart(2, "0")}${currentDate.toString().padStart(2, "0")}${lastQuotation.value.toString().padStart(4, "0")}`,
|
code: `${currentYear.toString().padStart(2, "0")}${currentMonth.toString().padStart(2, "0")}${currentDate.toString().padStart(2, "0")}${lastQuotation.value.toString().padStart(4, "0")}`,
|
||||||
worker: {
|
worker: {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue