progress on batches
This commit is contained in:
@@ -25,6 +25,14 @@ import 'package:qpay/screens/receipt/receipt_screen.dart';
|
||||
import 'package:qpay/screens/recipient/recipients_screen.dart';
|
||||
import 'package:qpay/screens/transaction_controller.dart';
|
||||
import 'package:qpay/screens/profile_screen.dart';
|
||||
import 'package:qpay/screens/groups/groups_screen.dart';
|
||||
import 'package:qpay/screens/groups/group_create_screen.dart';
|
||||
import 'package:qpay/screens/groups/group_detail_screen.dart';
|
||||
import 'package:qpay/screens/groups/batch_create_screen.dart';
|
||||
import 'package:qpay/screens/groups/batch_detail_screen.dart';
|
||||
import 'package:qpay/screens/groups/batch_item_screen.dart';
|
||||
import 'package:qpay/screens/groups/models/recipient_group_model.dart';
|
||||
import 'package:qpay/screens/groups/models/group_batch_model.dart';
|
||||
import 'package:qpay/theme/app_theme.dart';
|
||||
import 'package:flutter_dotenv/flutter_dotenv.dart';
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
@@ -49,6 +57,7 @@ String resolveEnvFile(String env) {
|
||||
/// navigation to the originally intended URL.
|
||||
class SplashState extends ChangeNotifier {
|
||||
bool _complete = false;
|
||||
|
||||
/// The route the user originally intended to visit before being
|
||||
/// redirected to /splash. Set by the redirect callback on first
|
||||
/// invocation.
|
||||
@@ -188,9 +197,8 @@ class _MyAppState extends State<MyApp> {
|
||||
),
|
||||
GoRoute(
|
||||
path: '/poll/:id',
|
||||
builder: (context, state) => PollScreen(
|
||||
transactionId: state.pathParameters['id'],
|
||||
),
|
||||
builder: (context, state) =>
|
||||
PollScreen(transactionId: state.pathParameters['id']),
|
||||
),
|
||||
GoRoute(
|
||||
path: '/poll',
|
||||
@@ -222,6 +230,43 @@ class _MyAppState extends State<MyApp> {
|
||||
path: '/profile',
|
||||
builder: (context, state) => const ProfileScreen(),
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups',
|
||||
builder: (context, state) => const GroupsScreen(),
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups/create',
|
||||
builder: (context, state) => const GroupCreateScreen(),
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups/:groupId',
|
||||
builder: (context, state) {
|
||||
final group = state.extra as RecipientGroup;
|
||||
return GroupDetailScreen(group: group);
|
||||
},
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups/:groupId/batches/create',
|
||||
builder: (context, state) {
|
||||
final group = state.extra as RecipientGroup;
|
||||
return BatchCreateScreen(group: group);
|
||||
},
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups/:groupId/batches/:batchId',
|
||||
builder: (context, state) {
|
||||
final batchId = state.pathParameters['batchId']!;
|
||||
final groupId = state.pathParameters['groupId']!;
|
||||
return BatchDetailScreen(batchId: batchId, groupId: groupId);
|
||||
},
|
||||
),
|
||||
GoRoute(
|
||||
path: '/groups/:groupId/batches/:batchId/items/:itemId',
|
||||
builder: (context, state) {
|
||||
final item = state.extra as GroupBatchItem;
|
||||
return BatchItemScreen(item: item);
|
||||
},
|
||||
),
|
||||
GoRoute(
|
||||
path: '/onboarding/landing',
|
||||
builder: (context, state) => const LandingScreen(),
|
||||
@@ -256,4 +301,4 @@ class _MyAppState extends State<MyApp> {
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user