cardus 0.0.97 → 0.0.99
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +11 -6
- package/index.ts +11 -7
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -394,13 +394,18 @@ class IntegrationManager {
|
|
|
394
394
|
});
|
|
395
395
|
}
|
|
396
396
|
if (!shouldGroup && !forzarAgrupamientoDeLinea) {
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
397
|
+
if ((group === null || group === void 0 ? void 0 : group.grouped) === 1 && Number(cantidad) > 1) {
|
|
398
|
+
this.insertTempShipmentGroupLine({ idEnvioTemporal, group });
|
|
399
|
+
}
|
|
400
|
+
else {
|
|
401
|
+
const arrayFake = Array.from({ length: Number(cantidad) });
|
|
402
|
+
arrayFake.forEach(() => {
|
|
403
|
+
this.dataToInsert.lines.push({
|
|
404
|
+
id_envio: idEnvioTemporal,
|
|
405
|
+
bulto
|
|
406
|
+
});
|
|
402
407
|
});
|
|
403
|
-
}
|
|
408
|
+
}
|
|
404
409
|
}
|
|
405
410
|
}
|
|
406
411
|
catch (e) {
|
package/index.ts
CHANGED
|
@@ -647,14 +647,18 @@ export class IntegrationManager {
|
|
|
647
647
|
}
|
|
648
648
|
|
|
649
649
|
if (!shouldGroup && !forzarAgrupamientoDeLinea) {
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
650
|
+
if (group?.grouped === 1 && Number(cantidad) > 1) {
|
|
651
|
+
this.insertTempShipmentGroupLine({ idEnvioTemporal, group });
|
|
652
|
+
} else {
|
|
653
|
+
const arrayFake = Array.from({ length: Number(cantidad) });
|
|
654
|
+
|
|
655
|
+
arrayFake.forEach(() => {
|
|
656
|
+
this.dataToInsert.lines.push({
|
|
657
|
+
id_envio: idEnvioTemporal,
|
|
658
|
+
bulto
|
|
659
|
+
});
|
|
656
660
|
});
|
|
657
|
-
}
|
|
661
|
+
}
|
|
658
662
|
}
|
|
659
663
|
} catch (e) {
|
|
660
664
|
console.log(e);
|