wurong
2 years ago
13 changed files with 86 additions and 50 deletions
After Width: | Height: | Size: 834 B |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 630 B |
@ -0,0 +1,42 @@
|
||||
/// dineInTakeStatus : true |
||||
/// takeawayStatus : null |
||||
/// expressDeliveryStatus : null |
||||
|
||||
class PickupType { |
||||
PickupType({ |
||||
bool dineInTakeStatus, |
||||
dynamic takeawayStatus, |
||||
dynamic expressDeliveryStatus,}){ |
||||
_dineInTakeStatus = dineInTakeStatus; |
||||
_takeawayStatus = takeawayStatus; |
||||
_expressDeliveryStatus = expressDeliveryStatus; |
||||
} |
||||
|
||||
PickupType.fromJson(dynamic json) { |
||||
_dineInTakeStatus = json['dineInTakeStatus']; |
||||
_takeawayStatus = json['takeawayStatus']; |
||||
_expressDeliveryStatus = json['expressDeliveryStatus']; |
||||
} |
||||
bool _dineInTakeStatus; |
||||
dynamic _takeawayStatus; |
||||
dynamic _expressDeliveryStatus; |
||||
PickupType copyWith({ bool dineInTakeStatus, |
||||
dynamic takeawayStatus, |
||||
dynamic expressDeliveryStatus, |
||||
}) => PickupType( dineInTakeStatus: dineInTakeStatus ?? _dineInTakeStatus, |
||||
takeawayStatus: takeawayStatus ?? _takeawayStatus, |
||||
expressDeliveryStatus: expressDeliveryStatus ?? _expressDeliveryStatus, |
||||
); |
||||
bool get dineInTakeStatus => _dineInTakeStatus; |
||||
dynamic get takeawayStatus => _takeawayStatus; |
||||
dynamic get expressDeliveryStatus => _expressDeliveryStatus; |
||||
|
||||
Map<String, dynamic> toJson() { |
||||
final map = <String, dynamic>{}; |
||||
map['dineInTakeStatus'] = _dineInTakeStatus; |
||||
map['takeawayStatus'] = _takeawayStatus; |
||||
map['expressDeliveryStatus'] = _expressDeliveryStatus; |
||||
return map; |
||||
} |
||||
|
||||
} |
Loading…
Reference in new issue