cardus 0.0.96 → 0.0.98
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
|
@@ -385,13 +385,18 @@ class IntegrationManager {
|
|
|
385
385
|
});
|
|
386
386
|
}
|
|
387
387
|
if (!shouldGroup && !forzarAgrupamientoDeLinea) {
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
388
|
+
if ((group === null || group === void 0 ? void 0 : group.grouped) === 1 && Number(cantidad) > 1) {
|
|
389
|
+
this.insertTempShipmentGroupLine({ idEnvioTemporal, group });
|
|
390
|
+
}
|
|
391
|
+
else {
|
|
392
|
+
const arrayFake = Array.from({ length: Number(cantidad) });
|
|
393
|
+
arrayFake.forEach(() => {
|
|
394
|
+
this.dataToInsert.lines.push({
|
|
395
|
+
id_envio: idEnvioTemporal,
|
|
396
|
+
bulto
|
|
397
|
+
});
|
|
393
398
|
});
|
|
394
|
-
}
|
|
399
|
+
}
|
|
395
400
|
}
|
|
396
401
|
}
|
|
397
402
|
catch (e) {
|
package/index.ts
CHANGED
|
@@ -633,14 +633,18 @@ export class IntegrationManager {
|
|
|
633
633
|
}
|
|
634
634
|
|
|
635
635
|
if (!shouldGroup && !forzarAgrupamientoDeLinea) {
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
636
|
+
if (group?.grouped === 1 && Number(cantidad) > 1) {
|
|
637
|
+
this.insertTempShipmentGroupLine({ idEnvioTemporal, group });
|
|
638
|
+
} else {
|
|
639
|
+
const arrayFake = Array.from({ length: Number(cantidad) });
|
|
640
|
+
|
|
641
|
+
arrayFake.forEach(() => {
|
|
642
|
+
this.dataToInsert.lines.push({
|
|
643
|
+
id_envio: idEnvioTemporal,
|
|
644
|
+
bulto
|
|
645
|
+
});
|
|
642
646
|
});
|
|
643
|
-
}
|
|
647
|
+
}
|
|
644
648
|
}
|
|
645
649
|
} catch (e) {
|
|
646
650
|
console.log(e);
|