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