add printer checker checks
This commit is contained in:
@@ -125,6 +125,7 @@ class Order with _$Order {
|
||||
createdAt: DateTime.now().subtract(const Duration(hours: 1)),
|
||||
updatedAt: DateTime.now(),
|
||||
printerType: 'Barista',
|
||||
printToChecker: false,
|
||||
paidQuantity: 2,
|
||||
categoryId: 'CAT-001',
|
||||
categoryName: 'Minuman',
|
||||
@@ -145,6 +146,7 @@ class Order with _$Order {
|
||||
createdAt: DateTime.now().subtract(const Duration(hours: 1)),
|
||||
updatedAt: DateTime.now(),
|
||||
printerType: 'Kitchen',
|
||||
printToChecker: false,
|
||||
paidQuantity: 1,
|
||||
categoryId: 'CAT-002',
|
||||
categoryName: 'Makanan',
|
||||
@@ -165,6 +167,7 @@ class Order with _$Order {
|
||||
createdAt: DateTime.now().subtract(const Duration(hours: 1)),
|
||||
updatedAt: DateTime.now(),
|
||||
printerType: 'Kitchen',
|
||||
printToChecker: false,
|
||||
paidQuantity: 1,
|
||||
categoryId: 'CAT-002',
|
||||
categoryName: 'Makanan',
|
||||
@@ -230,6 +233,7 @@ class OrderItem with _$OrderItem {
|
||||
required DateTime createdAt,
|
||||
required DateTime updatedAt,
|
||||
required String printerType,
|
||||
required bool printToChecker,
|
||||
required int paidQuantity,
|
||||
required String categoryId,
|
||||
required String categoryName,
|
||||
@@ -251,6 +255,7 @@ class OrderItem with _$OrderItem {
|
||||
createdAt: DateTime(1970),
|
||||
updatedAt: DateTime(1970),
|
||||
printerType: '',
|
||||
printToChecker: false,
|
||||
paidQuantity: 0,
|
||||
categoryId: '',
|
||||
categoryName: '',
|
||||
@@ -274,6 +279,7 @@ class OrderItem with _$OrderItem {
|
||||
createdAt: DateTime.now(),
|
||||
updatedAt: DateTime.now(),
|
||||
printerType: productQuantity.product.printerType,
|
||||
printToChecker: productQuantity.product.printToChecker,
|
||||
paidQuantity: 0,
|
||||
categoryId: '',
|
||||
categoryName: '',
|
||||
|
||||
@@ -1002,6 +1002,7 @@ mixin _$OrderItem {
|
||||
DateTime get createdAt => throw _privateConstructorUsedError;
|
||||
DateTime get updatedAt => throw _privateConstructorUsedError;
|
||||
String get printerType => throw _privateConstructorUsedError;
|
||||
bool get printToChecker => throw _privateConstructorUsedError;
|
||||
int get paidQuantity => throw _privateConstructorUsedError;
|
||||
String get categoryId => throw _privateConstructorUsedError;
|
||||
String get categoryName => throw _privateConstructorUsedError;
|
||||
@@ -1034,6 +1035,7 @@ abstract class $OrderItemCopyWith<$Res> {
|
||||
DateTime createdAt,
|
||||
DateTime updatedAt,
|
||||
String printerType,
|
||||
bool printToChecker,
|
||||
int paidQuantity,
|
||||
String categoryId,
|
||||
String categoryName,
|
||||
@@ -1070,6 +1072,7 @@ class _$OrderItemCopyWithImpl<$Res, $Val extends OrderItem>
|
||||
Object? createdAt = null,
|
||||
Object? updatedAt = null,
|
||||
Object? printerType = null,
|
||||
Object? printToChecker = null,
|
||||
Object? paidQuantity = null,
|
||||
Object? categoryId = null,
|
||||
Object? categoryName = null,
|
||||
@@ -1136,6 +1139,10 @@ class _$OrderItemCopyWithImpl<$Res, $Val extends OrderItem>
|
||||
? _value.printerType
|
||||
: printerType // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
printToChecker: null == printToChecker
|
||||
? _value.printToChecker
|
||||
: printToChecker // ignore: cast_nullable_to_non_nullable
|
||||
as bool,
|
||||
paidQuantity: null == paidQuantity
|
||||
? _value.paidQuantity
|
||||
: paidQuantity // ignore: cast_nullable_to_non_nullable
|
||||
@@ -1179,6 +1186,7 @@ abstract class _$$OrderItemImplCopyWith<$Res>
|
||||
DateTime createdAt,
|
||||
DateTime updatedAt,
|
||||
String printerType,
|
||||
bool printToChecker,
|
||||
int paidQuantity,
|
||||
String categoryId,
|
||||
String categoryName,
|
||||
@@ -1214,6 +1222,7 @@ class __$$OrderItemImplCopyWithImpl<$Res>
|
||||
Object? createdAt = null,
|
||||
Object? updatedAt = null,
|
||||
Object? printerType = null,
|
||||
Object? printToChecker = null,
|
||||
Object? paidQuantity = null,
|
||||
Object? categoryId = null,
|
||||
Object? categoryName = null,
|
||||
@@ -1280,6 +1289,10 @@ class __$$OrderItemImplCopyWithImpl<$Res>
|
||||
? _value.printerType
|
||||
: printerType // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
printToChecker: null == printToChecker
|
||||
? _value.printToChecker
|
||||
: printToChecker // ignore: cast_nullable_to_non_nullable
|
||||
as bool,
|
||||
paidQuantity: null == paidQuantity
|
||||
? _value.paidQuantity
|
||||
: paidQuantity // ignore: cast_nullable_to_non_nullable
|
||||
@@ -1316,6 +1329,7 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
required this.createdAt,
|
||||
required this.updatedAt,
|
||||
required this.printerType,
|
||||
required this.printToChecker,
|
||||
required this.paidQuantity,
|
||||
required this.categoryId,
|
||||
required this.categoryName,
|
||||
@@ -1358,6 +1372,8 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
@override
|
||||
final String printerType;
|
||||
@override
|
||||
final bool printToChecker;
|
||||
@override
|
||||
final int paidQuantity;
|
||||
@override
|
||||
final String categoryId;
|
||||
@@ -1366,7 +1382,7 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'OrderItem(id: $id, orderId: $orderId, productId: $productId, productName: $productName, productVariantId: $productVariantId, productVariantName: $productVariantName, quantity: $quantity, unitPrice: $unitPrice, totalPrice: $totalPrice, modifiers: $modifiers, notes: $notes, status: $status, createdAt: $createdAt, updatedAt: $updatedAt, printerType: $printerType, paidQuantity: $paidQuantity, categoryId: $categoryId, categoryName: $categoryName)';
|
||||
return 'OrderItem(id: $id, orderId: $orderId, productId: $productId, productName: $productName, productVariantId: $productVariantId, productVariantName: $productVariantName, quantity: $quantity, unitPrice: $unitPrice, totalPrice: $totalPrice, modifiers: $modifiers, notes: $notes, status: $status, createdAt: $createdAt, updatedAt: $updatedAt, printerType: $printerType, printToChecker: $printToChecker, paidQuantity: $paidQuantity, categoryId: $categoryId, categoryName: $categoryName)';
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -1402,6 +1418,8 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
other.updatedAt == updatedAt) &&
|
||||
(identical(other.printerType, printerType) ||
|
||||
other.printerType == printerType) &&
|
||||
(identical(other.printToChecker, printToChecker) ||
|
||||
other.printToChecker == printToChecker) &&
|
||||
(identical(other.paidQuantity, paidQuantity) ||
|
||||
other.paidQuantity == paidQuantity) &&
|
||||
(identical(other.categoryId, categoryId) ||
|
||||
@@ -1411,7 +1429,7 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
}
|
||||
|
||||
@override
|
||||
int get hashCode => Object.hash(
|
||||
int get hashCode => Object.hashAll([
|
||||
runtimeType,
|
||||
id,
|
||||
orderId,
|
||||
@@ -1428,10 +1446,11 @@ class _$OrderItemImpl implements _OrderItem {
|
||||
createdAt,
|
||||
updatedAt,
|
||||
printerType,
|
||||
printToChecker,
|
||||
paidQuantity,
|
||||
categoryId,
|
||||
categoryName,
|
||||
);
|
||||
]);
|
||||
|
||||
/// Create a copy of OrderItem
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@@ -1459,6 +1478,7 @@ abstract class _OrderItem implements OrderItem {
|
||||
required final DateTime createdAt,
|
||||
required final DateTime updatedAt,
|
||||
required final String printerType,
|
||||
required final bool printToChecker,
|
||||
required final int paidQuantity,
|
||||
required final String categoryId,
|
||||
required final String categoryName,
|
||||
@@ -1495,6 +1515,8 @@ abstract class _OrderItem implements OrderItem {
|
||||
@override
|
||||
String get printerType;
|
||||
@override
|
||||
bool get printToChecker;
|
||||
@override
|
||||
int get paidQuantity;
|
||||
@override
|
||||
String get categoryId;
|
||||
|
||||
@@ -33,6 +33,7 @@ class Product with _$Product {
|
||||
required String businessType,
|
||||
required String imageUrl,
|
||||
required String printerType,
|
||||
required bool printToChecker,
|
||||
required Map<String, dynamic> metadata,
|
||||
required bool isActive,
|
||||
required String createdAt,
|
||||
@@ -52,6 +53,7 @@ class Product with _$Product {
|
||||
businessType: '',
|
||||
imageUrl: '',
|
||||
printerType: '',
|
||||
printToChecker: false,
|
||||
metadata: {},
|
||||
isActive: false,
|
||||
createdAt: '',
|
||||
|
||||
@@ -279,6 +279,7 @@ mixin _$Product {
|
||||
String get businessType => throw _privateConstructorUsedError;
|
||||
String get imageUrl => throw _privateConstructorUsedError;
|
||||
String get printerType => throw _privateConstructorUsedError;
|
||||
bool get printToChecker => throw _privateConstructorUsedError;
|
||||
Map<String, dynamic> get metadata => throw _privateConstructorUsedError;
|
||||
bool get isActive => throw _privateConstructorUsedError;
|
||||
String get createdAt => throw _privateConstructorUsedError;
|
||||
@@ -308,6 +309,7 @@ abstract class $ProductCopyWith<$Res> {
|
||||
String businessType,
|
||||
String imageUrl,
|
||||
String printerType,
|
||||
bool printToChecker,
|
||||
Map<String, dynamic> metadata,
|
||||
bool isActive,
|
||||
String createdAt,
|
||||
@@ -342,6 +344,7 @@ class _$ProductCopyWithImpl<$Res, $Val extends Product>
|
||||
Object? businessType = null,
|
||||
Object? imageUrl = null,
|
||||
Object? printerType = null,
|
||||
Object? printToChecker = null,
|
||||
Object? metadata = null,
|
||||
Object? isActive = null,
|
||||
Object? createdAt = null,
|
||||
@@ -394,6 +397,10 @@ class _$ProductCopyWithImpl<$Res, $Val extends Product>
|
||||
? _value.printerType
|
||||
: printerType // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
printToChecker: null == printToChecker
|
||||
? _value.printToChecker
|
||||
: printToChecker // ignore: cast_nullable_to_non_nullable
|
||||
as bool,
|
||||
metadata: null == metadata
|
||||
? _value.metadata
|
||||
: metadata // ignore: cast_nullable_to_non_nullable
|
||||
@@ -440,6 +447,7 @@ abstract class _$$ProductImplCopyWith<$Res> implements $ProductCopyWith<$Res> {
|
||||
String businessType,
|
||||
String imageUrl,
|
||||
String printerType,
|
||||
bool printToChecker,
|
||||
Map<String, dynamic> metadata,
|
||||
bool isActive,
|
||||
String createdAt,
|
||||
@@ -473,6 +481,7 @@ class __$$ProductImplCopyWithImpl<$Res>
|
||||
Object? businessType = null,
|
||||
Object? imageUrl = null,
|
||||
Object? printerType = null,
|
||||
Object? printToChecker = null,
|
||||
Object? metadata = null,
|
||||
Object? isActive = null,
|
||||
Object? createdAt = null,
|
||||
@@ -525,6 +534,10 @@ class __$$ProductImplCopyWithImpl<$Res>
|
||||
? _value.printerType
|
||||
: printerType // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
printToChecker: null == printToChecker
|
||||
? _value.printToChecker
|
||||
: printToChecker // ignore: cast_nullable_to_non_nullable
|
||||
as bool,
|
||||
metadata: null == metadata
|
||||
? _value._metadata
|
||||
: metadata // ignore: cast_nullable_to_non_nullable
|
||||
@@ -565,6 +578,7 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
required this.businessType,
|
||||
required this.imageUrl,
|
||||
required this.printerType,
|
||||
required this.printToChecker,
|
||||
required final Map<String, dynamic> metadata,
|
||||
required this.isActive,
|
||||
required this.createdAt,
|
||||
@@ -595,6 +609,8 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
final String imageUrl;
|
||||
@override
|
||||
final String printerType;
|
||||
@override
|
||||
final bool printToChecker;
|
||||
final Map<String, dynamic> _metadata;
|
||||
@override
|
||||
Map<String, dynamic> get metadata {
|
||||
@@ -619,7 +635,7 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
|
||||
@override
|
||||
String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) {
|
||||
return 'Product(id: $id, organizationId: $organizationId, categoryId: $categoryId, sku: $sku, name: $name, description: $description, price: $price, cost: $cost, businessType: $businessType, imageUrl: $imageUrl, printerType: $printerType, metadata: $metadata, isActive: $isActive, createdAt: $createdAt, updatedAt: $updatedAt, variants: $variants)';
|
||||
return 'Product(id: $id, organizationId: $organizationId, categoryId: $categoryId, sku: $sku, name: $name, description: $description, price: $price, cost: $cost, businessType: $businessType, imageUrl: $imageUrl, printerType: $printerType, printToChecker: $printToChecker, metadata: $metadata, isActive: $isActive, createdAt: $createdAt, updatedAt: $updatedAt, variants: $variants)';
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -638,6 +654,7 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
..add(DiagnosticsProperty('businessType', businessType))
|
||||
..add(DiagnosticsProperty('imageUrl', imageUrl))
|
||||
..add(DiagnosticsProperty('printerType', printerType))
|
||||
..add(DiagnosticsProperty('printToChecker', printToChecker))
|
||||
..add(DiagnosticsProperty('metadata', metadata))
|
||||
..add(DiagnosticsProperty('isActive', isActive))
|
||||
..add(DiagnosticsProperty('createdAt', createdAt))
|
||||
@@ -667,6 +684,8 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
other.imageUrl == imageUrl) &&
|
||||
(identical(other.printerType, printerType) ||
|
||||
other.printerType == printerType) &&
|
||||
(identical(other.printToChecker, printToChecker) ||
|
||||
other.printToChecker == printToChecker) &&
|
||||
const DeepCollectionEquality().equals(other._metadata, _metadata) &&
|
||||
(identical(other.isActive, isActive) ||
|
||||
other.isActive == isActive) &&
|
||||
@@ -691,6 +710,7 @@ class _$ProductImpl with DiagnosticableTreeMixin implements _Product {
|
||||
businessType,
|
||||
imageUrl,
|
||||
printerType,
|
||||
printToChecker,
|
||||
const DeepCollectionEquality().hash(_metadata),
|
||||
isActive,
|
||||
createdAt,
|
||||
@@ -720,6 +740,7 @@ abstract class _Product implements Product {
|
||||
required final String businessType,
|
||||
required final String imageUrl,
|
||||
required final String printerType,
|
||||
required final bool printToChecker,
|
||||
required final Map<String, dynamic> metadata,
|
||||
required final bool isActive,
|
||||
required final String createdAt,
|
||||
@@ -750,6 +771,8 @@ abstract class _Product implements Product {
|
||||
@override
|
||||
String get printerType;
|
||||
@override
|
||||
bool get printToChecker;
|
||||
@override
|
||||
Map<String, dynamic> get metadata;
|
||||
@override
|
||||
bool get isActive;
|
||||
|
||||
Reference in New Issue
Block a user