diff --git a/lib/presentation/pages/download/download_report_page.dart b/lib/presentation/pages/download/download_report_page.dart new file mode 100644 index 0000000..b09e6c7 --- /dev/null +++ b/lib/presentation/pages/download/download_report_page.dart @@ -0,0 +1,591 @@ +import 'package:flutter/material.dart'; +import 'package:auto_route/auto_route.dart'; + +import '../../../common/theme/theme.dart'; +import '../../components/appbar/appbar.dart'; + +@RoutePage() +class DownloadReportPage extends StatefulWidget { + const DownloadReportPage({super.key}); + + @override + State createState() => _DownloadReportPageState(); +} + +class _DownloadReportPageState extends State + with TickerProviderStateMixin { + late AnimationController _fadeController; + late AnimationController _slideController; + late AnimationController _scaleController; + + late Animation _fadeAnimation; + + @override + void initState() { + super.initState(); + + // Initialize animation controllers + _fadeController = AnimationController( + duration: const Duration(milliseconds: 800), + vsync: this, + ); + + _slideController = AnimationController( + duration: const Duration(milliseconds: 1000), + vsync: this, + ); + + _scaleController = AnimationController( + duration: const Duration(milliseconds: 600), + vsync: this, + ); + + // Initialize animations + _fadeAnimation = Tween(begin: 0.0, end: 1.0).animate( + CurvedAnimation(parent: _fadeController, curve: Curves.easeInOut), + ); + + // Start animations + _fadeController.forward(); + _slideController.forward(); + _scaleController.forward(); + } + + @override + void dispose() { + _fadeController.dispose(); + _slideController.dispose(); + _scaleController.dispose(); + super.dispose(); + } + + void _showDateRangePicker(String reportType) { + showModalBottomSheet( + context: context, + isScrollControlled: true, + backgroundColor: Colors.transparent, + builder: (context) => _DateRangeBottomSheet( + reportType: reportType, + onDateRangeSelected: (dateRange) { + setState(() {}); + // Handle download logic here + _downloadReport(reportType, dateRange); + }, + ), + ); + } + + void _downloadReport(String reportType, DateTimeRange dateRange) { + // Implement download logic here + ScaffoldMessenger.of(context).showSnackBar( + SnackBar( + content: Text( + 'Downloading $reportType from ${_formatDate(dateRange.start)} to ${_formatDate(dateRange.end)}', + ), + backgroundColor: AppColor.success, + ), + ); + } + + String _formatDate(DateTime date) { + return '${date.day}/${date.month}/${date.year}'; + } + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColor.background, + body: CustomScrollView( + slivers: [ + // SliverAppBar with gradient + SliverAppBar( + expandedHeight: 120, + floating: false, + pinned: true, + elevation: 0, + backgroundColor: AppColor.primary, + flexibleSpace: CustomAppBar(title: 'Download Report'), + ), + + // Content + SliverToBoxAdapter( + child: Padding( + padding: const EdgeInsets.all(20), + child: Column( + children: [ + // Report Options + FadeTransition( + opacity: _fadeAnimation, + child: Column( + children: [ + // Transaction Report Card + _ReportOptionCard( + title: 'Transaction Report', + subtitle: + 'Export all transaction data with detailed analytics', + icon: Icons.receipt_long_outlined, + gradient: const [ + AppColor.primary, + AppColor.primaryLight, + ], + onTap: () => + _showDateRangePicker('Transaction Report'), + delay: 200, + ), + + const SizedBox(height: 20), + + // Inventory Report Card + _ReportOptionCard( + title: 'Inventory Report', + subtitle: + 'Export inventory and stock data with trends', + icon: Icons.inventory_2_outlined, + gradient: const [ + AppColor.secondary, + AppColor.secondaryLight, + ], + onTap: () => _showDateRangePicker('Inventory Report'), + delay: 400, + ), + + const SizedBox(height: 20), + + // Additional Report Options + _ReportOptionCard( + title: 'Sales Report', + subtitle: 'Export sales performance and revenue data', + icon: Icons.trending_up_outlined, + gradient: const [AppColor.info, Color(0xFF64B5F6)], + onTap: () => _showDateRangePicker('Sales Report'), + delay: 600, + ), + + const SizedBox(height: 20), + + _ReportOptionCard( + title: 'Customer Report', + subtitle: + 'Export customer data and behavior analytics', + icon: Icons.people_outline, + gradient: const [AppColor.warning, Color(0xFFFFB74D)], + onTap: () => _showDateRangePicker('Customer Report'), + delay: 800, + ), + ], + ), + ), + + const SizedBox(height: 40), + ], + ), + ), + ), + ], + ), + ); + } +} + +class _ReportOptionCard extends StatefulWidget { + final String title; + final String subtitle; + final IconData icon; + final List gradient; + final VoidCallback onTap; + final int delay; + + const _ReportOptionCard({ + required this.title, + required this.subtitle, + required this.icon, + required this.gradient, + required this.onTap, + required this.delay, + }); + + @override + State<_ReportOptionCard> createState() => _ReportOptionCardState(); +} + +class _ReportOptionCardState extends State<_ReportOptionCard> + with SingleTickerProviderStateMixin { + late AnimationController _animationController; + late Animation _scaleAnimation; + bool _isPressed = false; + + @override + void initState() { + super.initState(); + _animationController = AnimationController( + duration: const Duration(milliseconds: 150), + vsync: this, + ); + _scaleAnimation = Tween(begin: 1.0, end: 0.95).animate( + CurvedAnimation(parent: _animationController, curve: Curves.easeInOut), + ); + } + + @override + void dispose() { + _animationController.dispose(); + super.dispose(); + } + + @override + Widget build(BuildContext context) { + return GestureDetector( + onTapDown: (_) { + setState(() => _isPressed = true); + _animationController.forward(); + }, + onTapUp: (_) { + setState(() => _isPressed = false); + _animationController.reverse(); + widget.onTap(); + }, + onTapCancel: () { + setState(() => _isPressed = false); + _animationController.reverse(); + }, + child: ScaleTransition( + scale: _scaleAnimation, + child: AnimatedContainer( + duration: const Duration(milliseconds: 200), + padding: const EdgeInsets.all(20), + decoration: BoxDecoration( + gradient: LinearGradient( + begin: Alignment.topLeft, + end: Alignment.bottomRight, + colors: _isPressed + ? widget.gradient.map((c) => c.withOpacity(0.8)).toList() + : widget.gradient, + ), + borderRadius: BorderRadius.circular(20), + boxShadow: [ + BoxShadow( + color: widget.gradient.first.withOpacity(0.3), + blurRadius: _isPressed ? 8 : 15, + offset: Offset(0, _isPressed ? 2 : 8), + ), + ], + ), + child: Row( + children: [ + Container( + padding: const EdgeInsets.all(16), + decoration: BoxDecoration( + color: AppColor.white.withOpacity(0.2), + borderRadius: BorderRadius.circular(16), + ), + child: Icon(widget.icon, color: AppColor.white, size: 32), + ), + const SizedBox(width: 20), + Expanded( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + widget.title, + style: AppStyle.lg.copyWith( + color: AppColor.white, + fontWeight: FontWeight.bold, + ), + ), + const SizedBox(height: 4), + Text( + widget.subtitle, + style: AppStyle.sm.copyWith( + color: AppColor.white.withOpacity(0.8), + ), + ), + ], + ), + ), + Icon( + Icons.arrow_forward_ios, + color: AppColor.white.withOpacity(0.8), + size: 20, + ), + ], + ), + ), + ), + ); + } +} + +class _DateRangeBottomSheet extends StatefulWidget { + final String reportType; + final Function(DateTimeRange) onDateRangeSelected; + + const _DateRangeBottomSheet({ + required this.reportType, + required this.onDateRangeSelected, + }); + + @override + State<_DateRangeBottomSheet> createState() => _DateRangeBottomSheetState(); +} + +class _DateRangeBottomSheetState extends State<_DateRangeBottomSheet> + with SingleTickerProviderStateMixin { + late AnimationController _controller; + late Animation _animation; + + DateTime? _startDate; + DateTime? _endDate; + + @override + void initState() { + super.initState(); + _controller = AnimationController( + duration: const Duration(milliseconds: 300), + vsync: this, + ); + _animation = CurvedAnimation( + parent: _controller, + curve: Curves.easeOutCubic, + ); + _controller.forward(); + } + + @override + void dispose() { + _controller.dispose(); + super.dispose(); + } + + void _selectStartDate() async { + final date = await showDatePicker( + context: context, + initialDate: _startDate ?? DateTime.now(), + firstDate: DateTime(2020), + lastDate: DateTime.now(), + builder: (context, child) { + return Theme( + data: Theme.of(context).copyWith( + colorScheme: const ColorScheme.light(primary: AppColor.primary), + ), + child: child!, + ); + }, + ); + if (date != null) { + setState(() => _startDate = date); + } + } + + void _selectEndDate() async { + final date = await showDatePicker( + context: context, + initialDate: _endDate ?? DateTime.now(), + firstDate: _startDate ?? DateTime(2020), + lastDate: DateTime.now(), + builder: (context, child) { + return Theme( + data: Theme.of(context).copyWith( + colorScheme: const ColorScheme.light(primary: AppColor.primary), + ), + child: child!, + ); + }, + ); + if (date != null) { + setState(() => _endDate = date); + } + } + + void _downloadReport() { + if (_startDate != null && _endDate != null) { + final dateRange = DateTimeRange(start: _startDate!, end: _endDate!); + widget.onDateRangeSelected(dateRange); + Navigator.pop(context); + } + } + + String _formatDate(DateTime? date) { + if (date == null) return 'Select Date'; + return '${date.day}/${date.month}/${date.year}'; + } + + @override + Widget build(BuildContext context) { + return AnimatedBuilder( + animation: _animation, + builder: (context, child) { + return Transform.translate( + offset: Offset(0, (1 - _animation.value) * 300), + child: Container( + decoration: const BoxDecoration( + color: AppColor.white, + borderRadius: BorderRadius.only( + topLeft: Radius.circular(30), + topRight: Radius.circular(30), + ), + ), + child: Padding( + padding: EdgeInsets.only( + left: 20, + right: 20, + top: 20, + bottom: MediaQuery.of(context).viewInsets.bottom + 20, + ), + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + // Handle bar + Container( + width: 50, + height: 4, + decoration: BoxDecoration( + color: AppColor.border, + borderRadius: BorderRadius.circular(2), + ), + ), + + const SizedBox(height: 20), + + // Title + Text( + widget.reportType, + style: AppStyle.h6.copyWith(fontWeight: FontWeight.bold), + ), + + const SizedBox(height: 8), + + Text( + 'Select date range for your report', + style: AppStyle.md.copyWith(color: AppColor.textSecondary), + ), + + const SizedBox(height: 30), + + // Date Selection + Row( + children: [ + Expanded( + child: _DateSelectionCard( + title: 'Start Date', + date: _formatDate(_startDate), + onTap: _selectStartDate, + ), + ), + const SizedBox(width: 16), + Expanded( + child: _DateSelectionCard( + title: 'End Date', + date: _formatDate(_endDate), + onTap: _selectEndDate, + ), + ), + ], + ), + + const SizedBox(height: 30), + + // Download Button + SizedBox( + width: double.infinity, + child: ElevatedButton( + onPressed: _startDate != null && _endDate != null + ? _downloadReport + : null, + style: ElevatedButton.styleFrom( + backgroundColor: AppColor.primary, + padding: const EdgeInsets.symmetric(vertical: 16), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(16), + ), + elevation: 0, + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + const Icon( + Icons.download_rounded, + color: AppColor.white, + ), + const SizedBox(width: 8), + Text( + 'Download Report', + style: AppStyle.lg.copyWith( + color: AppColor.white, + fontWeight: FontWeight.bold, + ), + ), + ], + ), + ), + ), + + const SizedBox(height: 10), + ], + ), + ), + ), + ); + }, + ); + } +} + +class _DateSelectionCard extends StatelessWidget { + final String title; + final String date; + final VoidCallback onTap; + + const _DateSelectionCard({ + required this.title, + required this.date, + required this.onTap, + }); + + @override + Widget build(BuildContext context) { + return GestureDetector( + onTap: onTap, + child: Container( + padding: const EdgeInsets.all(16), + decoration: BoxDecoration( + color: AppColor.background, + borderRadius: BorderRadius.circular(12), + border: Border.all(color: AppColor.border), + ), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + title, + style: AppStyle.sm.copyWith( + color: AppColor.textSecondary, + fontWeight: FontWeight.w500, + ), + ), + const SizedBox(height: 8), + Row( + children: [ + Expanded( + child: Text( + date, + style: AppStyle.md.copyWith( + fontWeight: FontWeight.w600, + color: date == 'Select Date' + ? AppColor.textLight + : AppColor.textPrimary, + ), + ), + ), + Icon( + Icons.calendar_today_outlined, + color: AppColor.primary, + size: 18, + ), + ], + ), + ], + ), + ), + ); + } +} diff --git a/lib/presentation/pages/profile/widgets/business_setting.dart b/lib/presentation/pages/profile/widgets/business_setting.dart index d8a1be7..fee212a 100644 --- a/lib/presentation/pages/profile/widgets/business_setting.dart +++ b/lib/presentation/pages/profile/widgets/business_setting.dart @@ -63,6 +63,14 @@ class ProfileBusinessSetting extends StatelessWidget { subtitle: 'Manage your products', onTap: () => context.router.push(ProductRoute()), ), + ProfileDivider(), + + ProfileTile( + icon: Icons.download_outlined, + title: 'Download Report', + subtitle: 'Download your sales or inventory report', + onTap: () => context.router.push(DownloadReportRoute()), + ), ], ), ); diff --git a/lib/presentation/router/app_router.dart b/lib/presentation/router/app_router.dart index 05d0e79..c125c98 100644 --- a/lib/presentation/router/app_router.dart +++ b/lib/presentation/router/app_router.dart @@ -56,6 +56,9 @@ class AppRouter extends RootStackRouter { // Outlet AutoRoute(page: OutletInformationRoute.page), + // Download Report + AutoRoute(page: DownloadReportRoute.page), + // Error AutoRoute(page: ErrorRoute.page), diff --git a/lib/presentation/router/app_router.gr.dart b/lib/presentation/router/app_router.gr.dart index 0f23b15..e465783 100644 --- a/lib/presentation/router/app_router.gr.dart +++ b/lib/presentation/router/app_router.gr.dart @@ -9,61 +9,63 @@ // coverage:ignore-file // ignore_for_file: no_leading_underscores_for_library_prefixes -import 'package:apskel_owner_flutter/domain/order/order.dart' as _i24; +import 'package:apskel_owner_flutter/domain/order/order.dart' as _i25; import 'package:apskel_owner_flutter/presentation/pages/auth/login/login_page.dart' - as _i9; + as _i10; import 'package:apskel_owner_flutter/presentation/pages/coming_soon/coming_soon_page.dart' as _i1; import 'package:apskel_owner_flutter/presentation/pages/customer/customer_page.dart' as _i2; -import 'package:apskel_owner_flutter/presentation/pages/error/error_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/download/download_report_page.dart' as _i4; -import 'package:apskel_owner_flutter/presentation/pages/finance/finance_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/error/error_page.dart' as _i5; +import 'package:apskel_owner_flutter/presentation/pages/finance/finance_page.dart' + as _i6; import 'package:apskel_owner_flutter/presentation/pages/form/daily_task_form_page.dart' as _i3; import 'package:apskel_owner_flutter/presentation/pages/home/home_page.dart' - as _i6; -import 'package:apskel_owner_flutter/presentation/pages/inventory/inventory_page.dart' as _i7; -import 'package:apskel_owner_flutter/presentation/pages/language/language_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/inventory/inventory_page.dart' as _i8; +import 'package:apskel_owner_flutter/presentation/pages/language/language_page.dart' + as _i9; import 'package:apskel_owner_flutter/presentation/pages/main/main_page.dart' - as _i10; -import 'package:apskel_owner_flutter/presentation/pages/order/order_detail/order_detail_page.dart' as _i11; -import 'package:apskel_owner_flutter/presentation/pages/order/order_list/order_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/order/order_detail/order_detail_page.dart' as _i12; -import 'package:apskel_owner_flutter/presentation/pages/outlet/outlet_information_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/order/order_list/order_page.dart' as _i13; -import 'package:apskel_owner_flutter/presentation/pages/product/product_analytic/product_analytic_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/outlet/outlet_information_page.dart' as _i14; -import 'package:apskel_owner_flutter/presentation/pages/product/product_list/product_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/product/product_analytic/product_analytic_page.dart' as _i15; -import 'package:apskel_owner_flutter/presentation/pages/profile/profile_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/product/product_list/product_page.dart' as _i16; -import 'package:apskel_owner_flutter/presentation/pages/purchase/purchase_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/profile/profile_page.dart' as _i17; -import 'package:apskel_owner_flutter/presentation/pages/report/report_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/purchase/purchase_page.dart' as _i18; -import 'package:apskel_owner_flutter/presentation/pages/sales/sales_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/report/report_page.dart' as _i19; -import 'package:apskel_owner_flutter/presentation/pages/schedule/schedule_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/sales/sales_page.dart' as _i20; -import 'package:apskel_owner_flutter/presentation/pages/splash/splash_page.dart' +import 'package:apskel_owner_flutter/presentation/pages/schedule/schedule_page.dart' as _i21; -import 'package:auto_route/auto_route.dart' as _i22; -import 'package:flutter/material.dart' as _i23; +import 'package:apskel_owner_flutter/presentation/pages/splash/splash_page.dart' + as _i22; +import 'package:auto_route/auto_route.dart' as _i23; +import 'package:flutter/material.dart' as _i24; /// generated route for /// [_i1.ComingSoonPage] -class ComingSoonRoute extends _i22.PageRouteInfo { - const ComingSoonRoute({List<_i22.PageRouteInfo>? children}) +class ComingSoonRoute extends _i23.PageRouteInfo { + const ComingSoonRoute({List<_i23.PageRouteInfo>? children}) : super(ComingSoonRoute.name, initialChildren: children); static const String name = 'ComingSoonRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { return const _i1.ComingSoonPage(); @@ -73,29 +75,29 @@ class ComingSoonRoute extends _i22.PageRouteInfo { /// generated route for /// [_i2.CustomerPage] -class CustomerRoute extends _i22.PageRouteInfo { - const CustomerRoute({List<_i22.PageRouteInfo>? children}) +class CustomerRoute extends _i23.PageRouteInfo { + const CustomerRoute({List<_i23.PageRouteInfo>? children}) : super(CustomerRoute.name, initialChildren: children); static const String name = 'CustomerRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i2.CustomerPage()); + return _i23.WrappedRoute(child: const _i2.CustomerPage()); }, ); } /// generated route for /// [_i3.DailyTasksFormPage] -class DailyTasksFormRoute extends _i22.PageRouteInfo { - const DailyTasksFormRoute({List<_i22.PageRouteInfo>? children}) +class DailyTasksFormRoute extends _i23.PageRouteInfo { + const DailyTasksFormRoute({List<_i23.PageRouteInfo>? children}) : super(DailyTasksFormRoute.name, initialChildren: children); static const String name = 'DailyTasksFormRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { return const _i3.DailyTasksFormPage(); @@ -104,17 +106,33 @@ class DailyTasksFormRoute extends _i22.PageRouteInfo { } /// generated route for -/// [_i4.ErrorPage] -class ErrorRoute extends _i22.PageRouteInfo { +/// [_i4.DownloadReportPage] +class DownloadReportRoute extends _i23.PageRouteInfo { + const DownloadReportRoute({List<_i23.PageRouteInfo>? children}) + : super(DownloadReportRoute.name, initialChildren: children); + + static const String name = 'DownloadReportRoute'; + + static _i23.PageInfo page = _i23.PageInfo( + name, + builder: (data) { + return const _i4.DownloadReportPage(); + }, + ); +} + +/// generated route for +/// [_i5.ErrorPage] +class ErrorRoute extends _i23.PageRouteInfo { ErrorRoute({ - _i23.Key? key, + _i24.Key? key, String? title, String? message, - _i23.VoidCallback? onRetry, - _i23.VoidCallback? onBack, + _i24.VoidCallback? onRetry, + _i24.VoidCallback? onBack, String? errorCode, - _i23.IconData? errorIcon, - List<_i22.PageRouteInfo>? children, + _i24.IconData? errorIcon, + List<_i23.PageRouteInfo>? children, }) : super( ErrorRoute.name, args: ErrorRouteArgs( @@ -131,13 +149,13 @@ class ErrorRoute extends _i22.PageRouteInfo { static const String name = 'ErrorRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { final args = data.argsAs( orElse: () => const ErrorRouteArgs(), ); - return _i4.ErrorPage( + return _i5.ErrorPage( key: args.key, title: args.title, message: args.message, @@ -161,19 +179,19 @@ class ErrorRouteArgs { this.errorIcon, }); - final _i23.Key? key; + final _i24.Key? key; final String? title; final String? message; - final _i23.VoidCallback? onRetry; + final _i24.VoidCallback? onRetry; - final _i23.VoidCallback? onBack; + final _i24.VoidCallback? onBack; final String? errorCode; - final _i23.IconData? errorIcon; + final _i24.IconData? errorIcon; @override String toString() { @@ -182,108 +200,108 @@ class ErrorRouteArgs { } /// generated route for -/// [_i5.FinancePage] -class FinanceRoute extends _i22.PageRouteInfo { - const FinanceRoute({List<_i22.PageRouteInfo>? children}) +/// [_i6.FinancePage] +class FinanceRoute extends _i23.PageRouteInfo { + const FinanceRoute({List<_i23.PageRouteInfo>? children}) : super(FinanceRoute.name, initialChildren: children); static const String name = 'FinanceRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i5.FinancePage()); + return _i23.WrappedRoute(child: const _i6.FinancePage()); }, ); } /// generated route for -/// [_i6.HomePage] -class HomeRoute extends _i22.PageRouteInfo { - const HomeRoute({List<_i22.PageRouteInfo>? children}) +/// [_i7.HomePage] +class HomeRoute extends _i23.PageRouteInfo { + const HomeRoute({List<_i23.PageRouteInfo>? children}) : super(HomeRoute.name, initialChildren: children); static const String name = 'HomeRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i6.HomePage()); + return _i23.WrappedRoute(child: const _i7.HomePage()); }, ); } /// generated route for -/// [_i7.InventoryPage] -class InventoryRoute extends _i22.PageRouteInfo { - const InventoryRoute({List<_i22.PageRouteInfo>? children}) +/// [_i8.InventoryPage] +class InventoryRoute extends _i23.PageRouteInfo { + const InventoryRoute({List<_i23.PageRouteInfo>? children}) : super(InventoryRoute.name, initialChildren: children); static const String name = 'InventoryRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i7.InventoryPage()); + return _i23.WrappedRoute(child: const _i8.InventoryPage()); }, ); } /// generated route for -/// [_i8.LanguagePage] -class LanguageRoute extends _i22.PageRouteInfo { - const LanguageRoute({List<_i22.PageRouteInfo>? children}) +/// [_i9.LanguagePage] +class LanguageRoute extends _i23.PageRouteInfo { + const LanguageRoute({List<_i23.PageRouteInfo>? children}) : super(LanguageRoute.name, initialChildren: children); static const String name = 'LanguageRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return const _i8.LanguagePage(); + return const _i9.LanguagePage(); }, ); } /// generated route for -/// [_i9.LoginPage] -class LoginRoute extends _i22.PageRouteInfo { - const LoginRoute({List<_i22.PageRouteInfo>? children}) +/// [_i10.LoginPage] +class LoginRoute extends _i23.PageRouteInfo { + const LoginRoute({List<_i23.PageRouteInfo>? children}) : super(LoginRoute.name, initialChildren: children); static const String name = 'LoginRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i9.LoginPage()); + return _i23.WrappedRoute(child: const _i10.LoginPage()); }, ); } /// generated route for -/// [_i10.MainPage] -class MainRoute extends _i22.PageRouteInfo { - const MainRoute({List<_i22.PageRouteInfo>? children}) +/// [_i11.MainPage] +class MainRoute extends _i23.PageRouteInfo { + const MainRoute({List<_i23.PageRouteInfo>? children}) : super(MainRoute.name, initialChildren: children); static const String name = 'MainRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return const _i10.MainPage(); + return const _i11.MainPage(); }, ); } /// generated route for -/// [_i11.OrderDetailPage] -class OrderDetailRoute extends _i22.PageRouteInfo { +/// [_i12.OrderDetailPage] +class OrderDetailRoute extends _i23.PageRouteInfo { OrderDetailRoute({ - _i23.Key? key, - required _i24.Order order, - List<_i22.PageRouteInfo>? children, + _i24.Key? key, + required _i25.Order order, + List<_i23.PageRouteInfo>? children, }) : super( OrderDetailRoute.name, args: OrderDetailRouteArgs(key: key, order: order), @@ -292,11 +310,11 @@ class OrderDetailRoute extends _i22.PageRouteInfo { static const String name = 'OrderDetailRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { final args = data.argsAs(); - return _i11.OrderDetailPage(key: args.key, order: args.order); + return _i12.OrderDetailPage(key: args.key, order: args.order); }, ); } @@ -304,9 +322,9 @@ class OrderDetailRoute extends _i22.PageRouteInfo { class OrderDetailRouteArgs { const OrderDetailRouteArgs({this.key, required this.order}); - final _i23.Key? key; + final _i24.Key? key; - final _i24.Order order; + final _i25.Order order; @override String toString() { @@ -315,161 +333,161 @@ class OrderDetailRouteArgs { } /// generated route for -/// [_i12.OrderPage] -class OrderRoute extends _i22.PageRouteInfo { - const OrderRoute({List<_i22.PageRouteInfo>? children}) +/// [_i13.OrderPage] +class OrderRoute extends _i23.PageRouteInfo { + const OrderRoute({List<_i23.PageRouteInfo>? children}) : super(OrderRoute.name, initialChildren: children); static const String name = 'OrderRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i12.OrderPage()); + return _i23.WrappedRoute(child: const _i13.OrderPage()); }, ); } /// generated route for -/// [_i13.OutletInformationPage] -class OutletInformationRoute extends _i22.PageRouteInfo { - const OutletInformationRoute({List<_i22.PageRouteInfo>? children}) +/// [_i14.OutletInformationPage] +class OutletInformationRoute extends _i23.PageRouteInfo { + const OutletInformationRoute({List<_i23.PageRouteInfo>? children}) : super(OutletInformationRoute.name, initialChildren: children); static const String name = 'OutletInformationRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i13.OutletInformationPage()); + return _i23.WrappedRoute(child: const _i14.OutletInformationPage()); }, ); } /// generated route for -/// [_i14.ProductAnalyticPage] -class ProductAnalyticRoute extends _i22.PageRouteInfo { - const ProductAnalyticRoute({List<_i22.PageRouteInfo>? children}) +/// [_i15.ProductAnalyticPage] +class ProductAnalyticRoute extends _i23.PageRouteInfo { + const ProductAnalyticRoute({List<_i23.PageRouteInfo>? children}) : super(ProductAnalyticRoute.name, initialChildren: children); static const String name = 'ProductAnalyticRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i14.ProductAnalyticPage()); + return _i23.WrappedRoute(child: const _i15.ProductAnalyticPage()); }, ); } /// generated route for -/// [_i15.ProductPage] -class ProductRoute extends _i22.PageRouteInfo { - const ProductRoute({List<_i22.PageRouteInfo>? children}) +/// [_i16.ProductPage] +class ProductRoute extends _i23.PageRouteInfo { + const ProductRoute({List<_i23.PageRouteInfo>? children}) : super(ProductRoute.name, initialChildren: children); static const String name = 'ProductRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i15.ProductPage()); + return _i23.WrappedRoute(child: const _i16.ProductPage()); }, ); } /// generated route for -/// [_i16.ProfilePage] -class ProfileRoute extends _i22.PageRouteInfo { - const ProfileRoute({List<_i22.PageRouteInfo>? children}) +/// [_i17.ProfilePage] +class ProfileRoute extends _i23.PageRouteInfo { + const ProfileRoute({List<_i23.PageRouteInfo>? children}) : super(ProfileRoute.name, initialChildren: children); static const String name = 'ProfileRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i16.ProfilePage()); + return _i23.WrappedRoute(child: const _i17.ProfilePage()); }, ); } /// generated route for -/// [_i17.PurchasePage] -class PurchaseRoute extends _i22.PageRouteInfo { - const PurchaseRoute({List<_i22.PageRouteInfo>? children}) +/// [_i18.PurchasePage] +class PurchaseRoute extends _i23.PageRouteInfo { + const PurchaseRoute({List<_i23.PageRouteInfo>? children}) : super(PurchaseRoute.name, initialChildren: children); static const String name = 'PurchaseRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return const _i17.PurchasePage(); + return const _i18.PurchasePage(); }, ); } /// generated route for -/// [_i18.ReportPage] -class ReportRoute extends _i22.PageRouteInfo { - const ReportRoute({List<_i22.PageRouteInfo>? children}) +/// [_i19.ReportPage] +class ReportRoute extends _i23.PageRouteInfo { + const ReportRoute({List<_i23.PageRouteInfo>? children}) : super(ReportRoute.name, initialChildren: children); static const String name = 'ReportRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i18.ReportPage()); + return _i23.WrappedRoute(child: const _i19.ReportPage()); }, ); } /// generated route for -/// [_i19.SalesPage] -class SalesRoute extends _i22.PageRouteInfo { - const SalesRoute({List<_i22.PageRouteInfo>? children}) +/// [_i20.SalesPage] +class SalesRoute extends _i23.PageRouteInfo { + const SalesRoute({List<_i23.PageRouteInfo>? children}) : super(SalesRoute.name, initialChildren: children); static const String name = 'SalesRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return _i22.WrappedRoute(child: const _i19.SalesPage()); + return _i23.WrappedRoute(child: const _i20.SalesPage()); }, ); } /// generated route for -/// [_i20.SchedulePage] -class ScheduleRoute extends _i22.PageRouteInfo { - const ScheduleRoute({List<_i22.PageRouteInfo>? children}) +/// [_i21.SchedulePage] +class ScheduleRoute extends _i23.PageRouteInfo { + const ScheduleRoute({List<_i23.PageRouteInfo>? children}) : super(ScheduleRoute.name, initialChildren: children); static const String name = 'ScheduleRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return const _i20.SchedulePage(); + return const _i21.SchedulePage(); }, ); } /// generated route for -/// [_i21.SplashPage] -class SplashRoute extends _i22.PageRouteInfo { - const SplashRoute({List<_i22.PageRouteInfo>? children}) +/// [_i22.SplashPage] +class SplashRoute extends _i23.PageRouteInfo { + const SplashRoute({List<_i23.PageRouteInfo>? children}) : super(SplashRoute.name, initialChildren: children); static const String name = 'SplashRoute'; - static _i22.PageInfo page = _i22.PageInfo( + static _i23.PageInfo page = _i23.PageInfo( name, builder: (data) { - return const _i21.SplashPage(); + return const _i22.SplashPage(); }, ); }