update carton
This commit is contained in:
@@ -74,7 +74,7 @@ class Carton {
|
||||
height <= 0 ||
|
||||
volumetricRatio == null ||
|
||||
volumetricRatio <= 0) return 0;
|
||||
|
||||
|
||||
return ((length * width * height) / volumetricRatio).round();
|
||||
}
|
||||
|
||||
@@ -199,9 +199,9 @@ class Carton {
|
||||
shipmentNumber: map['shipment_number'],
|
||||
receiverNumber: map['receiver_number'],
|
||||
boxNumber: map['box_number'],
|
||||
length: map['length'],
|
||||
width: map['width'],
|
||||
height: map['height'],
|
||||
length: double.tryParse(map['length']?.toString()),
|
||||
width: double.tryParse(map['width']?.toString()),
|
||||
height: double.tryParse(map['height']?.toString()),
|
||||
userName: map['user_name'],
|
||||
fcsID: map['fcs_id'],
|
||||
cartonType: map['carton_type'],
|
||||
|
||||
@@ -138,6 +138,14 @@ class Package {
|
||||
package.fcsID != this.fcsID;
|
||||
}
|
||||
|
||||
bool isChangedForEditProcessing(Package package) {
|
||||
return package.trackingID != this.trackingID ||
|
||||
package.fcsID != this.fcsID ||
|
||||
package.market != this.market ||
|
||||
package.desc != this.desc ||
|
||||
package.remark != this.remark;
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => other is Package && other.id == id;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user