add carton editor for package

This commit is contained in:
tzw
2024-02-05 17:49:12 +06:30
parent afb980e6ae
commit a9e16ede8f
17 changed files with 1216 additions and 82 deletions

View File

@@ -37,7 +37,7 @@ class _MixCartonEditorState extends State<MixCartonEditor> {
LocalStep(lable: 'Cartons', stepType: StepType.CARTONS),
LocalStep(lable: 'Submit', stepType: StepType.SUBMIT)
];
List<Carton> _cartions = [];
List<Carton> _cartons = [];
int currentStep = 0;
double _length = 0;
@@ -146,16 +146,16 @@ class _MixCartonEditorState extends State<MixCartonEditor> {
return Expanded(
child: CartonSelectionWidget(
shipment: _shipment!,
cartons: _cartions,
cartons: _cartons,
onContinue: (cartons) {
setState(() {
_cartions = List.from(cartons);
_cartons = List.from(cartons);
currentStep += 1;
});
},
onPrevious: (cartons) {
setState(() {
_cartions = List.from(cartons);
_cartons = List.from(cartons);
currentStep -= 1;
});
},
@@ -170,7 +170,7 @@ class _MixCartonEditorState extends State<MixCartonEditor> {
width: _width,
height: _height,
shipment: _shipment!,
cartons: _cartions,
cartons: _cartons,
onCreate: () {
_create();
},