add payment detail

This commit is contained in:
Phuoc Nguyen
2025-10-27 11:46:03 +07:00
parent 90a02e1000
commit c941d6d983
3 changed files with 866 additions and 18 deletions

View File

@@ -11,6 +11,7 @@ import 'package:worker/features/favorites/presentation/pages/favorites_page.dart
import 'package:worker/features/loyalty/presentation/pages/rewards_page.dart';
import 'package:worker/features/main/presentation/pages/main_scaffold.dart';
import 'package:worker/features/orders/presentation/pages/orders_page.dart';
import 'package:worker/features/orders/presentation/pages/payment_detail_page.dart';
import 'package:worker/features/orders/presentation/pages/payments_page.dart';
import 'package:worker/features/products/presentation/pages/product_detail_page.dart';
import 'package:worker/features/products/presentation/pages/products_page.dart';
@@ -128,6 +129,19 @@ class AppRouter {
),
),
// Payment Detail Route
GoRoute(
path: RouteNames.paymentDetail,
name: RouteNames.paymentDetail,
pageBuilder: (context, state) {
final invoiceId = state.pathParameters['id'];
return MaterialPage(
key: state.pageKey,
child: PaymentDetailPage(invoiceId: invoiceId ?? ''),
);
},
),
// TODO: Add more routes as features are implemented
],
@@ -224,6 +238,7 @@ class RouteNames {
static const String orders = '/orders';
static const String orderDetail = '/orders/:id';
static const String payments = '/payments';
static const String paymentDetail = '/payments/:id';
// Projects & Quotes Routes
static const String projects = '/projects';