update carton and fcs shipment
This commit is contained in:
@@ -22,7 +22,6 @@ import 'package:fcs/pages/main/util.dart';
|
||||
import 'package:fcs/pages/payment_methods/model/payment_method_model.dart';
|
||||
import 'package:fcs/pages/rates/custom_list.dart';
|
||||
import 'package:fcs/pages/rates/model/shipment_rate_model.dart';
|
||||
import 'package:fcs/pages/shipment/model/shipment_model.dart';
|
||||
import 'package:fcs/pages/widgets/display_text.dart';
|
||||
import 'package:fcs/pages/widgets/fcs_icons.dart';
|
||||
import 'package:fcs/pages/widgets/local_app_bar.dart';
|
||||
@@ -104,8 +103,8 @@ class _InvoiceEditorState extends State<InvoiceEditor> {
|
||||
}
|
||||
|
||||
_loadShipments() async {
|
||||
ShipmentModel shipmentModel =
|
||||
Provider.of<ShipmentModel>(context, listen: false);
|
||||
InvoiceModel shipmentModel =
|
||||
Provider.of<InvoiceModel>(context, listen: false);
|
||||
List<Shipment?>? shipments = await shipmentModel.getShipmentWithHandlingFee(
|
||||
widget.fcsShipment!.id!, widget.customer!.id!);
|
||||
shipments!.forEach((s) {
|
||||
@@ -361,14 +360,6 @@ class _InvoiceEditorState extends State<InvoiceEditor> {
|
||||
);
|
||||
}
|
||||
|
||||
_addCustom(CustomDuty customDuty) {
|
||||
if (customDuty == null) return;
|
||||
setState(() {
|
||||
_invoice!.customDuties.remove(customDuty);
|
||||
_invoice!.customDuties.add(customDuty);
|
||||
});
|
||||
}
|
||||
|
||||
_addShipment(Shipment shipment) {
|
||||
if (shipment == null) return;
|
||||
shipment.isSelected = true;
|
||||
|
||||
Reference in New Issue
Block a user