split bill

This commit is contained in:
efrilm
2025-10-31 20:43:37 +07:00
parent 6b42cd86ff
commit 35f02e6b76
18 changed files with 1763 additions and 27 deletions
+38 -4
View File
@@ -9,6 +9,7 @@
// coverage:ignore-file
// ignore_for_file: no_leading_underscores_for_library_prefixes
import 'package:apskel_pos_flutter_v2/common/types/split_type.dart' as _i22;
import 'package:apskel_pos_flutter_v2/domain/order/order.dart' as _i21;
import 'package:apskel_pos_flutter_v2/presentation/pages/auth/login/login_page.dart'
as _i4;
@@ -174,10 +175,21 @@ class PaymentRoute extends _i19.PageRouteInfo<PaymentRouteArgs> {
PaymentRoute({
_i20.Key? key,
required _i21.Order order,
bool isSplit = false,
_i22.SplitType splitType = _i22.SplitType.unknown,
String? customerId,
String? customerName,
List<_i19.PageRouteInfo>? children,
}) : super(
PaymentRoute.name,
args: PaymentRouteArgs(key: key, order: order),
args: PaymentRouteArgs(
key: key,
order: order,
isSplit: isSplit,
splitType: splitType,
customerId: customerId,
customerName: customerName,
),
initialChildren: children,
);
@@ -188,22 +200,44 @@ class PaymentRoute extends _i19.PageRouteInfo<PaymentRouteArgs> {
builder: (data) {
final args = data.argsAs<PaymentRouteArgs>();
return _i19.WrappedRoute(
child: _i7.PaymentPage(key: args.key, order: args.order),
child: _i7.PaymentPage(
key: args.key,
order: args.order,
isSplit: args.isSplit,
splitType: args.splitType,
customerId: args.customerId,
customerName: args.customerName,
),
);
},
);
}
class PaymentRouteArgs {
const PaymentRouteArgs({this.key, required this.order});
const PaymentRouteArgs({
this.key,
required this.order,
this.isSplit = false,
this.splitType = _i22.SplitType.unknown,
this.customerId,
this.customerName,
});
final _i20.Key? key;
final _i21.Order order;
final bool isSplit;
final _i22.SplitType splitType;
final String? customerId;
final String? customerName;
@override
String toString() {
return 'PaymentRouteArgs{key: $key, order: $order}';
return 'PaymentRouteArgs{key: $key, order: $order, isSplit: $isSplit, splitType: $splitType, customerId: $customerId, customerName: $customerName}';
}
}