feat: prevent from change after completed
This commit is contained in:
parent
e77aa8faf4
commit
e655bf282c
1 changed files with 2 additions and 0 deletions
|
|
@ -127,6 +127,8 @@ export class QuotationPayment extends Controller {
|
|||
|
||||
if (!record) throw notFoundError("Payment");
|
||||
|
||||
if (record.paymentStatus === "PaymentSuccess") return record;
|
||||
|
||||
return await prisma.$transaction(async (tx) => {
|
||||
const current = new Date();
|
||||
const year = `${current.getFullYear()}`.slice(-2).padStart(2, "0");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue