null safety
This commit is contained in:
@@ -56,7 +56,7 @@ class _ShipmentAssignState extends State<ShipmentAssign> {
|
||||
_selectedShipmentType = _shipment!.shipmentType;
|
||||
_fromTimeEditingController.text = _shipment!.pickupTimeStart!;
|
||||
_toTimeEditingController.text = _shipment!.pickupTimeEnd!;
|
||||
_pickupDate.text = dateFormatter.format(_shipment!.pickupDate! ?? now);
|
||||
_pickupDate.text = dateFormatter.format(_shipment!.pickupDate ?? now);
|
||||
_handlingFee.text = _shipment!.handlingFee != null
|
||||
? _shipment!.handlingFee.toString()
|
||||
: "0";
|
||||
|
||||
@@ -37,7 +37,7 @@ class _ShipmentConfirmState extends State<ShipmentConfirm> {
|
||||
super.initState();
|
||||
|
||||
_shipment = widget.shipment;
|
||||
_handlingFee.text = _shipment!.handlingFee?.toString() ?? "0";
|
||||
_handlingFee.text = _shipment!.handlingFee.toString();
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
@@ -223,7 +223,7 @@ class _ShipmentInfoState extends State<ShipmentInfo> {
|
||||
iconData: MaterialCommunityIcons.worker);
|
||||
var handlingFeeBox = DisplayText(
|
||||
labelTextKey: "shipment.handling.fee",
|
||||
text: (_shipment!.handlingFee ?? 0).toString(),
|
||||
text: (_shipment!.handlingFee).toString(),
|
||||
iconData: FontAwesome.truck);
|
||||
|
||||
final assignCompleteBtn = LocalButton(
|
||||
|
||||
Reference in New Issue
Block a user