cardus 0.0.22 → 0.0.23
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 +4 -2
- package/index.ts +4 -2
- package/package.json +1 -1
- package/types/index.ts +5 -1
package/dist/index.js
CHANGED
|
@@ -59,7 +59,9 @@ class IntegrationManager {
|
|
|
59
59
|
servicio: this.type,
|
|
60
60
|
id_interno_shopify: order.idInternoShopify,
|
|
61
61
|
fecha_creacion_externa: (0, moment_1.default)(order === null || order === void 0 ? void 0 : order.fechaCreacionExterna).isValid() ? (0, moment_1.default)(order.fechaCreacionExterna).format("YYYY-MM-DD HH:mm:ss") : null,
|
|
62
|
-
marketplaceId: order.marketplaceId
|
|
62
|
+
marketplaceId: order.marketplaceId,
|
|
63
|
+
id_documento_holded: order.idDocumentoHolded,
|
|
64
|
+
tipo_documento_holded: order.tipoDocumentoHolded,
|
|
63
65
|
});
|
|
64
66
|
return idEnvioExterno;
|
|
65
67
|
});
|
|
@@ -98,7 +100,7 @@ class IntegrationManager {
|
|
|
98
100
|
: yield addressesService.getAddress(addressId, idUsuario);
|
|
99
101
|
const allOrders = yield fetchAllOrders();
|
|
100
102
|
const filteredOrders = yield integrationsService.filterExternalDuplicatedOrders({
|
|
101
|
-
idUsuario,
|
|
103
|
+
id_usuario: idUsuario,
|
|
102
104
|
orders: allOrders,
|
|
103
105
|
type: this.type
|
|
104
106
|
});
|
package/index.ts
CHANGED
|
@@ -79,7 +79,7 @@ export class IntegrationManager {
|
|
|
79
79
|
const allOrders = await fetchAllOrders();
|
|
80
80
|
const filteredOrders =
|
|
81
81
|
await integrationsService.filterExternalDuplicatedOrders({
|
|
82
|
-
idUsuario,
|
|
82
|
+
id_usuario: idUsuario,
|
|
83
83
|
orders: allOrders,
|
|
84
84
|
type: this.type
|
|
85
85
|
});
|
|
@@ -268,7 +268,9 @@ export class IntegrationManager {
|
|
|
268
268
|
servicio: this.type,
|
|
269
269
|
id_interno_shopify: order.idInternoShopify,
|
|
270
270
|
fecha_creacion_externa: moment(order?.fechaCreacionExterna).isValid() ? moment(order.fechaCreacionExterna).format("YYYY-MM-DD HH:mm:ss") : null,
|
|
271
|
-
marketplaceId: order.marketplaceId
|
|
271
|
+
marketplaceId: order.marketplaceId,
|
|
272
|
+
id_documento_holded: order.idDocumentoHolded,
|
|
273
|
+
tipo_documento_holded: order.tipoDocumentoHolded,
|
|
272
274
|
});
|
|
273
275
|
|
|
274
276
|
return idEnvioExterno;
|
package/package.json
CHANGED
package/types/index.ts
CHANGED
|
@@ -92,6 +92,8 @@ export type ModifiedOrder = {
|
|
|
92
92
|
precio: number | null;
|
|
93
93
|
fechaCreacionExterna?: string | null;
|
|
94
94
|
marketplaceId?: string | null
|
|
95
|
+
idDocumentoHolded?: string
|
|
96
|
+
tipoDocumentoHolded?: string
|
|
95
97
|
};
|
|
96
98
|
|
|
97
99
|
export interface ModifiedOrderExtended extends ModifiedOrder {
|
|
@@ -139,7 +141,7 @@ export interface InsertParams {
|
|
|
139
141
|
|
|
140
142
|
export type IntegrationsService = {
|
|
141
143
|
filterExternalDuplicatedOrders: (params: {
|
|
142
|
-
|
|
144
|
+
id_usuario: number;
|
|
143
145
|
orders: OriginalOrder[];
|
|
144
146
|
type: Type;
|
|
145
147
|
}) => Promise<OriginalOrder[]>;
|
|
@@ -160,6 +162,8 @@ export type IntegrationsService = {
|
|
|
160
162
|
id_interno_shopify?: string;
|
|
161
163
|
fecha_creacion_externa: string | null
|
|
162
164
|
marketplaceId?: string | null
|
|
165
|
+
id_documento_holded?: string
|
|
166
|
+
tipo_documento_holded?: string
|
|
163
167
|
}) => number | false;
|
|
164
168
|
|
|
165
169
|
insertTempShipmentLines: (params: {
|