fix order, update qr

This commit is contained in:
Phuoc Nguyen
2025-12-01 15:28:07 +07:00
parent 250c453413
commit e62c466155
7 changed files with 56 additions and 205 deletions

View File

@@ -350,14 +350,9 @@ final routerProvider = Provider<GoRouter>((ref) {
name: RouteNames.paymentQr,
pageBuilder: (context, state) {
final orderId = state.uri.queryParameters['orderId'] ?? '';
final amountStr = state.uri.queryParameters['amount'] ?? '0';
final amount = double.tryParse(amountStr) ?? 0.0;
return MaterialPage(
key: state.pageKey,
child: PaymentQrPage(
orderId: orderId,
amount: amount,
),
child: PaymentQrPage(orderId: orderId),
);
},
),

View File

@@ -14,10 +14,11 @@ class AppTheme {
/// Light theme configuration
/// [seedColor] - Optional custom seed color, defaults to AppColors.defaultSeedColor
static ThemeData lightTheme([Color? seedColor]) {
final seed = seedColor ?? AppColors.defaultSeedColor;
final ColorScheme colorScheme = ColorScheme.fromSeed(
seedColor: seedColor ?? AppColors.defaultSeedColor,
seedColor: seed,
brightness: Brightness.light,
);
).copyWith(primary: seed);
return ThemeData(
useMaterial3: true,
@@ -239,10 +240,11 @@ class AppTheme {
/// Dark theme configuration
/// [seedColor] - Optional custom seed color, defaults to AppColors.defaultSeedColor
static ThemeData darkTheme([Color? seedColor]) {
final seed = seedColor ?? AppColors.defaultSeedColor;
final ColorScheme colorScheme = ColorScheme.fromSeed(
seedColor: seedColor ?? AppColors.defaultSeedColor,
seedColor: seed,
brightness: Brightness.dark,
);
).copyWith(primary: seed);
return ThemeData(
useMaterial3: true,