update order detail

This commit is contained in:
efrilm 2025-11-01 04:20:03 +07:00
parent d37a4993df
commit ef23839761

View File

@ -85,6 +85,17 @@ class OrderRightPanel extends StatelessWidget {
icon: Icon(Icons.print), icon: Icon(Icons.print),
), ),
SpaceWidth(8), SpaceWidth(8),
if (state.selectedOrder?.status == 'completed')
if (state.selectedOrder?.isRefund == false)
AppElevatedButton.outlined(
onPressed: () {
// context.push(RefundPage(
// selectedOrder: orderDetail!,
// ));
},
label: 'Refund',
icon: Icon(Icons.autorenew),
),
if (state.selectedOrder?.status == 'pending') ...[ if (state.selectedOrder?.status == 'pending') ...[
AppElevatedButton.outlined( AppElevatedButton.outlined(
onPressed: () => context.router.push( onPressed: () => context.router.push(
@ -103,6 +114,7 @@ class OrderRightPanel extends StatelessWidget {
label: 'Split Bill', label: 'Split Bill',
icon: Icon(Icons.calculate_outlined), icon: Icon(Icons.calculate_outlined),
), ),
SpaceWidth(8), SpaceWidth(8),
if (state.selectedOrder?.paymentStatus != 'partial') if (state.selectedOrder?.paymentStatus != 'partial')
AppElevatedButton.filled( AppElevatedButton.filled(