2
0
mirror of https://github.com/frappe/books.git synced 2024-12-22 02:49:03 +00:00

fix: hide coupons table when no coupons are available after submission

This commit is contained in:
AbleKSaju 2024-12-07 12:38:51 +05:30
parent 7ff492adfc
commit 614d8931f5

View File

@ -843,7 +843,7 @@ export abstract class Invoice extends Transactional {
loyaltyProgram: () => !this.loyaltyProgram,
loyaltyPoints: () => !this.redeemLoyaltyPoints || this.isReturn,
redeemLoyaltyPoints: () => !this.loyaltyProgram || this.isReturn,
coupons: () => !this.coupons?.length,
coupons: () => this.isSubmitted && !this.coupons?.length,
priceList: () =>
!this.fyo.singles.AccountingSettings?.enablePriceList ||
(!this.canEdit && !this.priceList),