feat: print on receipt

This commit is contained in:
efrilm
2025-08-07 11:39:33 +07:00
parent 811ae06e58
commit 8022fa6b32
4 changed files with 336 additions and 6 deletions
@@ -961,6 +961,23 @@ class _ConfirmPaymentPageState extends State<ConfirmPaymentPage> {
) =>
products,
);
int tax = state.maybeWhen(
orElse: () => 0,
loaded: (
products,
discountModel,
discount,
discountAmount,
tax,
serviceCharge,
totalQuantity,
totalPrice,
draftName,
orderType,
deliveryType,
) =>
tax,
);
return Container(
padding: EdgeInsets.all(16),
@@ -1018,6 +1035,11 @@ class _ConfirmPaymentPageState extends State<ConfirmPaymentPage> {
.pushReplacement(SuccessOrderPage(
productQuantity: items,
order: data,
paymentMethod:
selectedPaymentMethod?.name ?? "",
nominalBayar: totalPriceController
.text.toIntegerFromText,
taxPercentage: tax,
));
},
error: (message) => AppFlushbar.showError(