fixed selecting a spool with filament weight but no spool switching to the remaining weight option
This commit is contained in:
@@ -72,11 +72,15 @@ export const SpoolCreate: React.FC<IResourceComponentsProps & CreateOrCloneProps
|
|||||||
const newFilamentWeight = newSelectedFilament?.weight || 0;
|
const newFilamentWeight = newSelectedFilament?.weight || 0;
|
||||||
const newSpoolWeight = newSelectedFilament?.spool_weight || 0;
|
const newSpoolWeight = newSelectedFilament?.spool_weight || 0;
|
||||||
|
|
||||||
if (!(newFilamentWeight && newSpoolWeight)) {
|
if (weightToEnter >= 3) {
|
||||||
setWeightToEnter(2);
|
if (!(newFilamentWeight && newSpoolWeight)) {
|
||||||
|
setWeightToEnter(2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (!newFilamentWeight) {
|
if (weightToEnter >= 2) {
|
||||||
setWeightToEnter(1);
|
if (!newFilamentWeight) {
|
||||||
|
setWeightToEnter(1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user