@zauru-sdk/utils 1.0.49 → 1.0.52
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/cjs/index.js +40 -0
- package/dist/cjs/zauru/4pinos-receptions-form-history.utils.js +80 -0
- package/dist/cjs/zauru/automatic-number.utils.js +28 -0
- package/dist/cjs/zauru/bitacora-edicion-masiva.utils.js +56 -0
- package/dist/cjs/zauru/bundles.utils.js +168 -0
- package/dist/cjs/zauru/cases.utils.js +21 -0
- package/dist/cjs/zauru/consolidated-history.utils.js +58 -0
- package/dist/cjs/zauru/costos-items.utils.js +617 -0
- package/dist/cjs/zauru/deliveries.utils.js +50 -0
- package/dist/cjs/zauru/discharges-histsory.utils.js +52 -0
- package/dist/cjs/zauru/employees.utils.js +44 -0
- package/dist/cjs/zauru/form.utils.js +160 -0
- package/dist/cjs/zauru/invoices.utils.js +85 -0
- package/dist/cjs/zauru/items.utils.js +126 -0
- package/dist/cjs/zauru/lotes.utils.js +313 -0
- package/dist/cjs/zauru/motivos-rechazo.utils.js +23 -0
- package/dist/cjs/zauru/payees.utils.js +136 -0
- package/dist/cjs/zauru/profiles.utils.js +41 -0
- package/dist/cjs/zauru/providers.utils.js +40 -0
- package/dist/cjs/zauru/purchase-orders.utils.js +390 -0
- package/dist/cjs/zauru/shipments.utils.js +95 -0
- package/dist/cjs/zauru/specialItem.utils.js +69 -0
- package/dist/cjs/zauru/templates.utils.js +102 -0
- package/dist/cjs/zauru/tiposMuestra.utils.js +69 -0
- package/dist/cjs/zauru/webapp-tables.utils.js +20 -0
- package/package.json +13 -10
- package/CHANGELOG.md +0 -248
- package/src/index.ts +0 -24
- package/src/zauru/4pinos-receptions-form-history.utils.ts +0 -142
- package/src/zauru/automatic-number.utils.ts +0 -38
- package/src/zauru/bitacora-edicion-masiva.utils.ts +0 -99
- package/src/zauru/bundles.utils.ts +0 -251
- package/src/zauru/cases.utils.ts +0 -31
- package/src/zauru/consolidated-history.utils.ts +0 -102
- package/src/zauru/costos-items.utils.ts +0 -871
- package/src/zauru/deliveries.utils.ts +0 -77
- package/src/zauru/discharges-histsory.utils.ts +0 -105
- package/src/zauru/employees.utils.ts +0 -59
- package/src/zauru/form.utils.ts +0 -243
- package/src/zauru/invoices.utils.ts +0 -114
- package/src/zauru/items.utils.ts +0 -221
- package/src/zauru/lotes.utils.ts +0 -411
- package/src/zauru/motivos-rechazo.utils.ts +0 -47
- package/src/zauru/payees.utils.ts +0 -213
- package/src/zauru/profiles.utils.ts +0 -44
- package/src/zauru/providers.utils.ts +0 -67
- package/src/zauru/purchase-orders.utils.ts +0 -594
- package/src/zauru/shipments.utils.ts +0 -139
- package/src/zauru/specialItem.utils.ts +0 -136
- package/src/zauru/templates.utils.ts +0 -199
- package/src/zauru/tiposMuestra.utils.ts +0 -136
- package/src/zauru/webapp-tables.utils.ts +0 -36
- package/tsconfig.json +0 -24
- /package/dist/{index.js → esm/index.js} +0 -0
- /package/dist/{zauru → esm/zauru}/4pinos-receptions-form-history.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/automatic-number.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/bitacora-edicion-masiva.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/bundles.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/cases.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/consolidated-history.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/costos-items.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/deliveries.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/discharges-histsory.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/employees.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/form.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/invoices.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/items.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/lotes.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/motivos-rechazo.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/payees.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/profiles.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/providers.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/purchase-orders.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/shipments.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/specialItem.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/templates.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/tiposMuestra.utils.js +0 -0
- /package/dist/{zauru → esm/zauru}/webapp-tables.utils.js +0 -0
|
@@ -1,251 +0,0 @@
|
|
|
1
|
-
import type { Session } from "@remix-run/node";
|
|
2
|
-
import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
|
|
3
|
-
import {
|
|
4
|
-
getVariablesByName,
|
|
5
|
-
getBundlesByItemCategoryId,
|
|
6
|
-
createBundle,
|
|
7
|
-
createForm,
|
|
8
|
-
deleteBundle,
|
|
9
|
-
getItemByName,
|
|
10
|
-
deleteItem,
|
|
11
|
-
getFormByName,
|
|
12
|
-
deleteForm,
|
|
13
|
-
} from "@zauru-sdk/services";
|
|
14
|
-
import {
|
|
15
|
-
AxiosUtilsResponse,
|
|
16
|
-
BundleGraphQL,
|
|
17
|
-
FormGraphQL,
|
|
18
|
-
ItemGraphQL,
|
|
19
|
-
} from "@zauru-sdk/types";
|
|
20
|
-
import { createNewLaboratoryItem } from "./items.utils.js";
|
|
21
|
-
|
|
22
|
-
export const LAB_BUNDLE_NAME = "LAB_BUNDLE_RECIP_";
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @param headers
|
|
27
|
-
* @param session
|
|
28
|
-
* @returns
|
|
29
|
-
*/
|
|
30
|
-
export const getBundlesRecipByLabCategory = async (
|
|
31
|
-
headers: any,
|
|
32
|
-
session: Session
|
|
33
|
-
): Promise<AxiosUtilsResponse<BundleGraphQL[]>> => {
|
|
34
|
-
return handlePossibleAxiosErrors(async () => {
|
|
35
|
-
const { lab_bundles_recip_item_category_id } = await getVariablesByName(
|
|
36
|
-
headers,
|
|
37
|
-
session,
|
|
38
|
-
["lab_bundles_recip_item_category_id"]
|
|
39
|
-
);
|
|
40
|
-
|
|
41
|
-
const response = await getBundlesByItemCategoryId(
|
|
42
|
-
session,
|
|
43
|
-
lab_bundles_recip_item_category_id
|
|
44
|
-
);
|
|
45
|
-
|
|
46
|
-
if (response.error) {
|
|
47
|
-
throw new Error(
|
|
48
|
-
`Ocurrió un error al consultar los paquetes por categoría de laboratorio: ${response.userMsg}`
|
|
49
|
-
);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
return response?.data ?? [];
|
|
53
|
-
});
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
*
|
|
58
|
-
* @param headers
|
|
59
|
-
* @param session
|
|
60
|
-
* @returns
|
|
61
|
-
*/
|
|
62
|
-
export const getBundlesByLabCategory = async (
|
|
63
|
-
headers: any,
|
|
64
|
-
session: Session
|
|
65
|
-
): Promise<AxiosUtilsResponse<BundleGraphQL[]>> => {
|
|
66
|
-
return handlePossibleAxiosErrors(async () => {
|
|
67
|
-
const { lab_bundles_item_category_id } = await getVariablesByName(
|
|
68
|
-
headers,
|
|
69
|
-
session,
|
|
70
|
-
["lab_bundles_item_category_id"]
|
|
71
|
-
);
|
|
72
|
-
|
|
73
|
-
const response = await getBundlesByItemCategoryId(
|
|
74
|
-
session,
|
|
75
|
-
lab_bundles_item_category_id
|
|
76
|
-
);
|
|
77
|
-
|
|
78
|
-
if (response.error) {
|
|
79
|
-
throw new Error(
|
|
80
|
-
`Ocurrió un error al consultar los paquetes por categoría de laboratorio: ${response.userMsg}`
|
|
81
|
-
);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
return response?.data ?? [];
|
|
85
|
-
});
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
/**
|
|
89
|
-
* createNewLabPaquete
|
|
90
|
-
* @param headers
|
|
91
|
-
* @param session
|
|
92
|
-
* @returns
|
|
93
|
-
*/
|
|
94
|
-
export const createNewLabPaquete = async (
|
|
95
|
-
headers: any,
|
|
96
|
-
session: Session,
|
|
97
|
-
body: Partial<BundleGraphQL>
|
|
98
|
-
): Promise<AxiosUtilsResponse<boolean>> => {
|
|
99
|
-
return handlePossibleAxiosErrors(async () => {
|
|
100
|
-
let msg = "";
|
|
101
|
-
const { lab_bundles_item_category_id } = await getVariablesByName(
|
|
102
|
-
headers,
|
|
103
|
-
session,
|
|
104
|
-
["lab_bundles_item_category_id"]
|
|
105
|
-
);
|
|
106
|
-
|
|
107
|
-
const sendBody: Partial<BundleGraphQL> = {
|
|
108
|
-
...body,
|
|
109
|
-
bundle_details: body?.bundle_details?.map((x) => {
|
|
110
|
-
x._destroy = false;
|
|
111
|
-
return x;
|
|
112
|
-
}),
|
|
113
|
-
item_category_id: Number(lab_bundles_item_category_id),
|
|
114
|
-
force_as_service_for_document_external_storage_service: true,
|
|
115
|
-
};
|
|
116
|
-
const bundleResponse = await createBundle(headers, sendBody);
|
|
117
|
-
if (bundleResponse.error) {
|
|
118
|
-
msg = `Ocurrió un error al intentar crear el paquete: ${bundleResponse.userMsg}`;
|
|
119
|
-
console.error(msg);
|
|
120
|
-
throw new Error(msg);
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
return true;
|
|
124
|
-
});
|
|
125
|
-
};
|
|
126
|
-
|
|
127
|
-
/**
|
|
128
|
-
* createNewLabEnsayo
|
|
129
|
-
* @param headers
|
|
130
|
-
* @param session
|
|
131
|
-
* @returns
|
|
132
|
-
*/
|
|
133
|
-
export const createNewLabEnsayo = async (
|
|
134
|
-
headers: any,
|
|
135
|
-
session: Session,
|
|
136
|
-
body: Partial<BundleGraphQL>
|
|
137
|
-
): Promise<AxiosUtilsResponse<boolean>> => {
|
|
138
|
-
return handlePossibleAxiosErrors(async () => {
|
|
139
|
-
let msg = "";
|
|
140
|
-
const {
|
|
141
|
-
lab_bundles_recip_item_category_id,
|
|
142
|
-
lab_services_item_category_id,
|
|
143
|
-
} = await getVariablesByName(headers, session, [
|
|
144
|
-
"lab_bundles_recip_item_category_id",
|
|
145
|
-
"lab_services_item_category_id",
|
|
146
|
-
]);
|
|
147
|
-
|
|
148
|
-
//PASO 1
|
|
149
|
-
//Creamos el bundle -> Paquete, donde va la receta
|
|
150
|
-
const sendBody: Partial<BundleGraphQL> = {
|
|
151
|
-
...body,
|
|
152
|
-
item_category_id: Number(lab_bundles_recip_item_category_id),
|
|
153
|
-
name: `${LAB_BUNDLE_NAME}${body.name}`,
|
|
154
|
-
};
|
|
155
|
-
const bundleResponse = await createBundle(headers, sendBody);
|
|
156
|
-
if (bundleResponse.error) {
|
|
157
|
-
msg = `Ocurrió un error al intentar crear el paquete: ${bundleResponse.userMsg}`;
|
|
158
|
-
console.error(msg);
|
|
159
|
-
throw new Error(msg);
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
console.log("-------------- BUNDLE CREADO ! ---------------");
|
|
163
|
-
//PASO 2
|
|
164
|
-
//Creamos el item
|
|
165
|
-
const itemSendBody: Partial<ItemGraphQL> = {
|
|
166
|
-
name: `LAB_SERVICE_${bundleResponse?.data?.id}; ${body.name}`,
|
|
167
|
-
code: `LAB_SERVICE_${bundleResponse?.data?.id}`,
|
|
168
|
-
stockable: false, //Esto lo vuelve servicio
|
|
169
|
-
purchasable: false,
|
|
170
|
-
sellable: true,
|
|
171
|
-
pays_vat: true,
|
|
172
|
-
item_category_id: Number(lab_services_item_category_id),
|
|
173
|
-
description: `Item creado desde la webapp de laboratorio, para representar el servicio del ensayo creado. Ensayo: ${bundleResponse?.data?.id}`,
|
|
174
|
-
};
|
|
175
|
-
const itemResponse = await createNewLaboratoryItem(headers, itemSendBody);
|
|
176
|
-
|
|
177
|
-
if (itemResponse.error) {
|
|
178
|
-
msg = `Ocurrió un error al intentar crear el item asociado al paquete: ${itemResponse.userMsg}`;
|
|
179
|
-
console.error(msg);
|
|
180
|
-
throw new Error(msg);
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
console.log("-------------- ITEM CREADO ! ---------------");
|
|
184
|
-
//PASO 3
|
|
185
|
-
//Creo el formulario
|
|
186
|
-
const formSendBody: Partial<FormGraphQL> = {
|
|
187
|
-
active: true,
|
|
188
|
-
name: `LAB_FORM_${itemResponse?.data?.id}; ${body.name}`,
|
|
189
|
-
description: `Formulario creado desde la webapp, que representa el formulario con las preguntas que se llenan en el ensayo al que hace referencia el mismo. Ensayo: ${itemResponse?.data?.id}`,
|
|
190
|
-
document_type: "invoice",
|
|
191
|
-
settings_form_fields: [
|
|
192
|
-
{
|
|
193
|
-
position: 1,
|
|
194
|
-
name: "Pregunta 1",
|
|
195
|
-
field_type: "text",
|
|
196
|
-
default_value: "",
|
|
197
|
-
print_var_name: "pregunta_1",
|
|
198
|
-
} as any,
|
|
199
|
-
],
|
|
200
|
-
};
|
|
201
|
-
const formResponse = await createForm(headers, formSendBody);
|
|
202
|
-
|
|
203
|
-
if (formResponse.error) {
|
|
204
|
-
msg = `Ocurrió un error al intentar crear el formulario asociado al paquete: ${formResponse.userMsg}`;
|
|
205
|
-
console.error(msg);
|
|
206
|
-
throw new Error(msg);
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
console.log("-------------- FORM CREADO ! ---------------");
|
|
210
|
-
return true;
|
|
211
|
-
});
|
|
212
|
-
};
|
|
213
|
-
|
|
214
|
-
/**
|
|
215
|
-
* deleteLabBundle
|
|
216
|
-
* @param headers
|
|
217
|
-
* @param session
|
|
218
|
-
* @param bundle
|
|
219
|
-
* @returns
|
|
220
|
-
*/
|
|
221
|
-
export const deleteLabBundle = async (
|
|
222
|
-
headers: any,
|
|
223
|
-
session: Session,
|
|
224
|
-
bundle: BundleGraphQL
|
|
225
|
-
): Promise<AxiosUtilsResponse<boolean>> => {
|
|
226
|
-
return handlePossibleAxiosErrors(async () => {
|
|
227
|
-
await deleteBundle(headers, bundle.id);
|
|
228
|
-
|
|
229
|
-
//busco el item-servicio para eliminarlo
|
|
230
|
-
const responseItem = await getItemByName(
|
|
231
|
-
session,
|
|
232
|
-
`LAB_SERVICE_${bundle.id}; ${bundle.name}`
|
|
233
|
-
);
|
|
234
|
-
|
|
235
|
-
if (responseItem.data && !responseItem.error) {
|
|
236
|
-
await deleteItem(headers, responseItem.data.id);
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
//busco el formulario para eliminarlo
|
|
240
|
-
const responseForm = await getFormByName(
|
|
241
|
-
session,
|
|
242
|
-
`LAB_FORM_${bundle.id}; ${bundle.name}`
|
|
243
|
-
);
|
|
244
|
-
|
|
245
|
-
if (responseForm.data && !responseForm.error) {
|
|
246
|
-
await deleteForm(headers, responseForm.data.id);
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
return true;
|
|
250
|
-
});
|
|
251
|
-
};
|
package/src/zauru/cases.utils.ts
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import type { Session } from "@remix-run/node";
|
|
2
|
-
import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
|
|
3
|
-
import { getCasesByResponsibleId } from "@zauru-sdk/services";
|
|
4
|
-
import { AxiosUtilsResponse, CaseGraphQL } from "@zauru-sdk/types";
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
*
|
|
8
|
-
* @param headers
|
|
9
|
-
* @param session
|
|
10
|
-
* @returns
|
|
11
|
-
*/
|
|
12
|
-
export const getMyCases = async (
|
|
13
|
-
session: Session,
|
|
14
|
-
wheres: string[] = []
|
|
15
|
-
): Promise<AxiosUtilsResponse<CaseGraphQL[]>> => {
|
|
16
|
-
return handlePossibleAxiosErrors(async () => {
|
|
17
|
-
const response = await getCasesByResponsibleId(
|
|
18
|
-
session,
|
|
19
|
-
session.get("employee_id"),
|
|
20
|
-
wheres
|
|
21
|
-
);
|
|
22
|
-
|
|
23
|
-
if (response.error) {
|
|
24
|
-
throw new Error(
|
|
25
|
-
`Ocurrió un error al consultar los casos asignados a este usuario: ${response.userMsg}`
|
|
26
|
-
);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
return response?.data ?? [];
|
|
30
|
-
});
|
|
31
|
-
};
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import type { Session } from "@remix-run/node";
|
|
2
|
-
import { handlePossibleAxiosErrors } from "@zauru-sdk/common";
|
|
3
|
-
import {
|
|
4
|
-
createWebAppTableRegister,
|
|
5
|
-
getVariablesByName,
|
|
6
|
-
getWebAppTableRegisters,
|
|
7
|
-
updateWebAppTableRegister,
|
|
8
|
-
} from "@zauru-sdk/services";
|
|
9
|
-
import {
|
|
10
|
-
AxiosUtilsResponse,
|
|
11
|
-
WebAppRowGraphQL,
|
|
12
|
-
ConsolidatedHistory,
|
|
13
|
-
WebAppTableUpdateResponse,
|
|
14
|
-
} from "@zauru-sdk/types";
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Get getConsolidatedHistories from the web app table.
|
|
18
|
-
* @param headers Request headers.
|
|
19
|
-
* @param session Session object.
|
|
20
|
-
* @returns A Promise of AxiosUtilsResponse<ConsolidatedHistory[]>.
|
|
21
|
-
*/
|
|
22
|
-
export const getConsolidatedHistories = (
|
|
23
|
-
headers: any,
|
|
24
|
-
session: Session
|
|
25
|
-
): Promise<AxiosUtilsResponse<WebAppRowGraphQL<ConsolidatedHistory>[]>> => {
|
|
26
|
-
return handlePossibleAxiosErrors(async () => {
|
|
27
|
-
const { purchase_order_consolidates_web_app_table_id } =
|
|
28
|
-
await getVariablesByName(headers, session, [
|
|
29
|
-
"purchase_order_consolidates_web_app_table_id",
|
|
30
|
-
]);
|
|
31
|
-
|
|
32
|
-
const response = await getWebAppTableRegisters<ConsolidatedHistory>(
|
|
33
|
-
session,
|
|
34
|
-
purchase_order_consolidates_web_app_table_id
|
|
35
|
-
);
|
|
36
|
-
|
|
37
|
-
if (response.error) {
|
|
38
|
-
throw new Error(
|
|
39
|
-
`Ocurrió un error al consultar el historial de consolidados: ${response.userMsg}`
|
|
40
|
-
);
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
const history = response?.data ?? [];
|
|
44
|
-
|
|
45
|
-
return history;
|
|
46
|
-
});
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Create a template in the web app table.
|
|
51
|
-
* @param headers Request headers.
|
|
52
|
-
* @param session Session object.
|
|
53
|
-
* @param body ConsolidatedHistory data to be created.
|
|
54
|
-
* @returns A Promise of AxiosUtilsResponse<ConsolidatedHistory>.
|
|
55
|
-
*/
|
|
56
|
-
export const createConsolidatedHistory = (
|
|
57
|
-
headers: any,
|
|
58
|
-
session: Session,
|
|
59
|
-
body: ConsolidatedHistory
|
|
60
|
-
): Promise<AxiosUtilsResponse<WebAppTableUpdateResponse>> => {
|
|
61
|
-
return handlePossibleAxiosErrors(async () => {
|
|
62
|
-
const { purchase_order_consolidates_web_app_table_id } =
|
|
63
|
-
await getVariablesByName(headers, session, [
|
|
64
|
-
"purchase_order_consolidates_web_app_table_id",
|
|
65
|
-
]);
|
|
66
|
-
const response = await createWebAppTableRegister<ConsolidatedHistory>(
|
|
67
|
-
headers,
|
|
68
|
-
purchase_order_consolidates_web_app_table_id,
|
|
69
|
-
body
|
|
70
|
-
);
|
|
71
|
-
return response;
|
|
72
|
-
});
|
|
73
|
-
};
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Put updateConsolidatedHistory from the web app table.
|
|
77
|
-
* @param headers Request headers.
|
|
78
|
-
* @param session Session object.
|
|
79
|
-
* @returns A Promise of AxiosUtilsResponse<ConsolidatedHistory[]>.
|
|
80
|
-
*/
|
|
81
|
-
export const updateConsolidatedHistory = (
|
|
82
|
-
headers: any,
|
|
83
|
-
session: Session,
|
|
84
|
-
body: ConsolidatedHistory,
|
|
85
|
-
id_registro: string | number
|
|
86
|
-
): Promise<AxiosUtilsResponse<WebAppTableUpdateResponse>> => {
|
|
87
|
-
return handlePossibleAxiosErrors(async () => {
|
|
88
|
-
const { purchase_order_consolidates_web_app_table_id } =
|
|
89
|
-
await getVariablesByName(headers, session, [
|
|
90
|
-
"purchase_order_consolidates_web_app_table_id",
|
|
91
|
-
]);
|
|
92
|
-
|
|
93
|
-
const response = await updateWebAppTableRegister<ConsolidatedHistory>(
|
|
94
|
-
headers,
|
|
95
|
-
purchase_order_consolidates_web_app_table_id,
|
|
96
|
-
id_registro,
|
|
97
|
-
{ ...body }
|
|
98
|
-
);
|
|
99
|
-
|
|
100
|
-
return response;
|
|
101
|
-
});
|
|
102
|
-
};
|