From d111025aa630083ae3b7dabe0e36bc5ba0a92989 Mon Sep 17 00:00:00 2001 From: efrilm Date: Sat, 1 Nov 2025 03:29:13 +0700 Subject: [PATCH] update order page --- .../components/card/order_card.dart | 5 +++++ .../order/widgets/order_right_panel.dart | 21 ++++++++++--------- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/lib/presentation/components/card/order_card.dart b/lib/presentation/components/card/order_card.dart index 55319ac..631b510 100644 --- a/lib/presentation/components/card/order_card.dart +++ b/lib/presentation/components/card/order_card.dart @@ -34,6 +34,11 @@ class OrderCard extends StatelessWidget { style: AppStyle.sm.copyWith(fontWeight: FontWeight.w600), ), ), + if (order.splitType != '') + Text( + "Split Bill: ${order.splitType}", + style: AppStyle.sm.copyWith(fontWeight: FontWeight.w600), + ), if (order.isRefund == true) Container( padding: const EdgeInsets.symmetric( diff --git a/lib/presentation/pages/order/widgets/order_right_panel.dart b/lib/presentation/pages/order/widgets/order_right_panel.dart index a3ffd7b..872e32b 100644 --- a/lib/presentation/pages/order/widgets/order_right_panel.dart +++ b/lib/presentation/pages/order/widgets/order_right_panel.dart @@ -104,16 +104,17 @@ class OrderRightPanel extends StatelessWidget { icon: Icon(Icons.calculate_outlined), ), SpaceWidth(8), - AppElevatedButton.filled( - width: 120, - onPressed: () { - context.router.push( - PaymentRoute(order: state.selectedOrder!), - ); - }, - label: 'Bayar', - icon: Icon(Icons.payment, color: Colors.white), - ), + if (state.selectedOrder?.paymentStatus != 'partial') + AppElevatedButton.filled( + width: 120, + onPressed: () { + context.router.push( + PaymentRoute(order: state.selectedOrder!), + ); + }, + label: 'Bayar', + icon: Icon(Icons.payment, color: Colors.white), + ), ], ], ),