bdpformulas 1.0.9 → 1.0.10
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/build/models/pecuary/sales.schema.d.ts +716 -0
- package/build/models/pecuary/sales.schema.js +30 -0
- package/build/strategies/pecuary/Constantes.d.ts +1 -0
- package/build/strategies/pecuary/Constantes.js +8 -1
- package/build/strategies/pecuary/desarrollo.detail/hatoDisponibleCalc.js +1 -1
- package/build/strategies/pecuary/ventas.detail/estacionalidadCalc.d.ts +3 -0
- package/build/strategies/pecuary/ventas.detail/estacionalidadCalc.js +64 -0
- package/build/strategies/pecuary/ventas.detail/ventasIngresosCalc.d.ts +1 -0
- package/build/strategies/pecuary/ventas.detail/ventasIngresosCalc.js +16 -0
- package/build/strategies/pecuary/ventas.strategy.d.ts +5 -0
- package/build/strategies/pecuary/ventas.strategy.js +44 -0
- package/package.json +1 -1
|
@@ -0,0 +1,716 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const VentasPecSchema: z.ZodObject<{
|
|
3
|
+
EvaluacionId: z.ZodNumber;
|
|
4
|
+
ActividadEconomicaId: z.ZodNumber;
|
|
5
|
+
PID: z.ZodNumber;
|
|
6
|
+
Ventas: z.ZodArray<z.ZodObject<{
|
|
7
|
+
RubroId: z.ZodString;
|
|
8
|
+
IndicadorABM: z.ZodEnum<["N", "M"]>;
|
|
9
|
+
Unidad: z.ZodString;
|
|
10
|
+
CicloId: z.ZodString;
|
|
11
|
+
}, "strip", z.ZodTypeAny, {
|
|
12
|
+
RubroId: string;
|
|
13
|
+
IndicadorABM: "N" | "M";
|
|
14
|
+
Unidad: string;
|
|
15
|
+
CicloId: string;
|
|
16
|
+
}, {
|
|
17
|
+
RubroId: string;
|
|
18
|
+
IndicadorABM: "N" | "M";
|
|
19
|
+
Unidad: string;
|
|
20
|
+
CicloId: string;
|
|
21
|
+
}>, "many">;
|
|
22
|
+
Estacionalidad: z.ZodArray<z.ZodObject<{
|
|
23
|
+
IndicadorABM: z.ZodEnum<["N", "M"]>;
|
|
24
|
+
RubroId: z.ZodString;
|
|
25
|
+
Correlativo: z.ZodNumber;
|
|
26
|
+
Monto: z.ZodNumber;
|
|
27
|
+
}, "strip", z.ZodTypeAny, {
|
|
28
|
+
RubroId: string;
|
|
29
|
+
IndicadorABM: "N" | "M";
|
|
30
|
+
Monto: number;
|
|
31
|
+
Correlativo: number;
|
|
32
|
+
}, {
|
|
33
|
+
RubroId: string;
|
|
34
|
+
IndicadorABM: "N" | "M";
|
|
35
|
+
Monto: number;
|
|
36
|
+
Correlativo: number;
|
|
37
|
+
}>, "many">;
|
|
38
|
+
}, "strip", z.ZodTypeAny, {
|
|
39
|
+
EvaluacionId: number;
|
|
40
|
+
ActividadEconomicaId: number;
|
|
41
|
+
PID: number;
|
|
42
|
+
Ventas: {
|
|
43
|
+
RubroId: string;
|
|
44
|
+
IndicadorABM: "N" | "M";
|
|
45
|
+
Unidad: string;
|
|
46
|
+
CicloId: string;
|
|
47
|
+
}[];
|
|
48
|
+
Estacionalidad: {
|
|
49
|
+
RubroId: string;
|
|
50
|
+
IndicadorABM: "N" | "M";
|
|
51
|
+
Monto: number;
|
|
52
|
+
Correlativo: number;
|
|
53
|
+
}[];
|
|
54
|
+
}, {
|
|
55
|
+
EvaluacionId: number;
|
|
56
|
+
ActividadEconomicaId: number;
|
|
57
|
+
PID: number;
|
|
58
|
+
Ventas: {
|
|
59
|
+
RubroId: string;
|
|
60
|
+
IndicadorABM: "N" | "M";
|
|
61
|
+
Unidad: string;
|
|
62
|
+
CicloId: string;
|
|
63
|
+
}[];
|
|
64
|
+
Estacionalidad: {
|
|
65
|
+
RubroId: string;
|
|
66
|
+
IndicadorABM: "N" | "M";
|
|
67
|
+
Monto: number;
|
|
68
|
+
Correlativo: number;
|
|
69
|
+
}[];
|
|
70
|
+
}>;
|
|
71
|
+
export type VentasPecType = z.infer<typeof VentasPecSchema>;
|
|
72
|
+
declare const CalcVentas: z.ZodObject<{
|
|
73
|
+
Auxiliar: z.ZodObject<{
|
|
74
|
+
EvaluacionId: z.ZodNumber;
|
|
75
|
+
ActividadEconomicaId: z.ZodNumber;
|
|
76
|
+
PID: z.ZodNumber;
|
|
77
|
+
PropiedadesGanaderas: z.ZodArray<z.ZodObject<{
|
|
78
|
+
UUID: z.ZodString;
|
|
79
|
+
IndicadorABM: z.ZodEnum<["A", "N", "M", "B"]>;
|
|
80
|
+
TipoGanadoId: z.ZodString;
|
|
81
|
+
RazaGanadoId: z.ZodString;
|
|
82
|
+
Fecha: z.ZodString;
|
|
83
|
+
TipoDocumentoId: z.ZodString;
|
|
84
|
+
Rubros: z.ZodArray<z.ZodObject<{
|
|
85
|
+
RubroId: z.ZodString;
|
|
86
|
+
CantidadCabezas: z.ZodNumber;
|
|
87
|
+
PesoPromedio: z.ZodNumber;
|
|
88
|
+
PrecioCabeza: z.ZodNumber;
|
|
89
|
+
PrecioCabezaBalance: z.ZodNumber;
|
|
90
|
+
Total: z.ZodOptional<z.ZodNumber>;
|
|
91
|
+
}, "strip", z.ZodTypeAny, {
|
|
92
|
+
RubroId: string;
|
|
93
|
+
CantidadCabezas: number;
|
|
94
|
+
PesoPromedio: number;
|
|
95
|
+
PrecioCabeza: number;
|
|
96
|
+
PrecioCabezaBalance: number;
|
|
97
|
+
Total?: number | undefined;
|
|
98
|
+
}, {
|
|
99
|
+
RubroId: string;
|
|
100
|
+
CantidadCabezas: number;
|
|
101
|
+
PesoPromedio: number;
|
|
102
|
+
PrecioCabeza: number;
|
|
103
|
+
PrecioCabezaBalance: number;
|
|
104
|
+
Total?: number | undefined;
|
|
105
|
+
}>, "many">;
|
|
106
|
+
Total: z.ZodOptional<z.ZodNumber>;
|
|
107
|
+
PesoAclaracion: z.ZodString;
|
|
108
|
+
PrecioAclaracion: z.ZodString;
|
|
109
|
+
TipoGanadoDesc: z.ZodOptional<z.ZodString>;
|
|
110
|
+
RazaGanadoDesc: z.ZodOptional<z.ZodString>;
|
|
111
|
+
TipoDocumentoDesc: z.ZodOptional<z.ZodString>;
|
|
112
|
+
}, "strip", z.ZodTypeAny, {
|
|
113
|
+
UUID: string;
|
|
114
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
115
|
+
TipoGanadoId: string;
|
|
116
|
+
RazaGanadoId: string;
|
|
117
|
+
Fecha: string;
|
|
118
|
+
TipoDocumentoId: string;
|
|
119
|
+
Rubros: {
|
|
120
|
+
RubroId: string;
|
|
121
|
+
CantidadCabezas: number;
|
|
122
|
+
PesoPromedio: number;
|
|
123
|
+
PrecioCabeza: number;
|
|
124
|
+
PrecioCabezaBalance: number;
|
|
125
|
+
Total?: number | undefined;
|
|
126
|
+
}[];
|
|
127
|
+
PesoAclaracion: string;
|
|
128
|
+
PrecioAclaracion: string;
|
|
129
|
+
Total?: number | undefined;
|
|
130
|
+
TipoGanadoDesc?: string | undefined;
|
|
131
|
+
RazaGanadoDesc?: string | undefined;
|
|
132
|
+
TipoDocumentoDesc?: string | undefined;
|
|
133
|
+
}, {
|
|
134
|
+
UUID: string;
|
|
135
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
136
|
+
TipoGanadoId: string;
|
|
137
|
+
RazaGanadoId: string;
|
|
138
|
+
Fecha: string;
|
|
139
|
+
TipoDocumentoId: string;
|
|
140
|
+
Rubros: {
|
|
141
|
+
RubroId: string;
|
|
142
|
+
CantidadCabezas: number;
|
|
143
|
+
PesoPromedio: number;
|
|
144
|
+
PrecioCabeza: number;
|
|
145
|
+
PrecioCabezaBalance: number;
|
|
146
|
+
Total?: number | undefined;
|
|
147
|
+
}[];
|
|
148
|
+
PesoAclaracion: string;
|
|
149
|
+
PrecioAclaracion: string;
|
|
150
|
+
Total?: number | undefined;
|
|
151
|
+
TipoGanadoDesc?: string | undefined;
|
|
152
|
+
RazaGanadoDesc?: string | undefined;
|
|
153
|
+
TipoDocumentoDesc?: string | undefined;
|
|
154
|
+
}>, "many">;
|
|
155
|
+
HistoricoHato: z.ZodArray<z.ZodObject<{
|
|
156
|
+
RubroId: z.ZodString;
|
|
157
|
+
Gestion: z.ZodNumber;
|
|
158
|
+
CantidadCabezas: z.ZodNumber;
|
|
159
|
+
PrecioCabeza: z.ZodNumber;
|
|
160
|
+
}, "strip", z.ZodTypeAny, {
|
|
161
|
+
RubroId: string;
|
|
162
|
+
CantidadCabezas: number;
|
|
163
|
+
PrecioCabeza: number;
|
|
164
|
+
Gestion: number;
|
|
165
|
+
}, {
|
|
166
|
+
RubroId: string;
|
|
167
|
+
CantidadCabezas: number;
|
|
168
|
+
PrecioCabeza: number;
|
|
169
|
+
Gestion: number;
|
|
170
|
+
}>, "many">;
|
|
171
|
+
Inventario: z.ZodArray<z.ZodObject<{
|
|
172
|
+
RubroId: z.ZodString;
|
|
173
|
+
IndicadorABM: z.ZodEnum<["A", "N", "M", "B"]>;
|
|
174
|
+
UUID: z.ZodString;
|
|
175
|
+
Descripcion: z.ZodString;
|
|
176
|
+
Cantidad: z.ZodNumber;
|
|
177
|
+
Precio: z.ZodNumber;
|
|
178
|
+
}, "strip", z.ZodTypeAny, {
|
|
179
|
+
RubroId: string;
|
|
180
|
+
UUID: string;
|
|
181
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
182
|
+
Descripcion: string;
|
|
183
|
+
Cantidad: number;
|
|
184
|
+
Precio: number;
|
|
185
|
+
}, {
|
|
186
|
+
RubroId: string;
|
|
187
|
+
UUID: string;
|
|
188
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
189
|
+
Descripcion: string;
|
|
190
|
+
Cantidad: number;
|
|
191
|
+
Precio: number;
|
|
192
|
+
}>, "many">;
|
|
193
|
+
}, "strip", z.ZodTypeAny, {
|
|
194
|
+
EvaluacionId: number;
|
|
195
|
+
ActividadEconomicaId: number;
|
|
196
|
+
PID: number;
|
|
197
|
+
PropiedadesGanaderas: {
|
|
198
|
+
UUID: string;
|
|
199
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
200
|
+
TipoGanadoId: string;
|
|
201
|
+
RazaGanadoId: string;
|
|
202
|
+
Fecha: string;
|
|
203
|
+
TipoDocumentoId: string;
|
|
204
|
+
Rubros: {
|
|
205
|
+
RubroId: string;
|
|
206
|
+
CantidadCabezas: number;
|
|
207
|
+
PesoPromedio: number;
|
|
208
|
+
PrecioCabeza: number;
|
|
209
|
+
PrecioCabezaBalance: number;
|
|
210
|
+
Total?: number | undefined;
|
|
211
|
+
}[];
|
|
212
|
+
PesoAclaracion: string;
|
|
213
|
+
PrecioAclaracion: string;
|
|
214
|
+
Total?: number | undefined;
|
|
215
|
+
TipoGanadoDesc?: string | undefined;
|
|
216
|
+
RazaGanadoDesc?: string | undefined;
|
|
217
|
+
TipoDocumentoDesc?: string | undefined;
|
|
218
|
+
}[];
|
|
219
|
+
HistoricoHato: {
|
|
220
|
+
RubroId: string;
|
|
221
|
+
CantidadCabezas: number;
|
|
222
|
+
PrecioCabeza: number;
|
|
223
|
+
Gestion: number;
|
|
224
|
+
}[];
|
|
225
|
+
Inventario: {
|
|
226
|
+
RubroId: string;
|
|
227
|
+
UUID: string;
|
|
228
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
229
|
+
Descripcion: string;
|
|
230
|
+
Cantidad: number;
|
|
231
|
+
Precio: number;
|
|
232
|
+
}[];
|
|
233
|
+
}, {
|
|
234
|
+
EvaluacionId: number;
|
|
235
|
+
ActividadEconomicaId: number;
|
|
236
|
+
PID: number;
|
|
237
|
+
PropiedadesGanaderas: {
|
|
238
|
+
UUID: string;
|
|
239
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
240
|
+
TipoGanadoId: string;
|
|
241
|
+
RazaGanadoId: string;
|
|
242
|
+
Fecha: string;
|
|
243
|
+
TipoDocumentoId: string;
|
|
244
|
+
Rubros: {
|
|
245
|
+
RubroId: string;
|
|
246
|
+
CantidadCabezas: number;
|
|
247
|
+
PesoPromedio: number;
|
|
248
|
+
PrecioCabeza: number;
|
|
249
|
+
PrecioCabezaBalance: number;
|
|
250
|
+
Total?: number | undefined;
|
|
251
|
+
}[];
|
|
252
|
+
PesoAclaracion: string;
|
|
253
|
+
PrecioAclaracion: string;
|
|
254
|
+
Total?: number | undefined;
|
|
255
|
+
TipoGanadoDesc?: string | undefined;
|
|
256
|
+
RazaGanadoDesc?: string | undefined;
|
|
257
|
+
TipoDocumentoDesc?: string | undefined;
|
|
258
|
+
}[];
|
|
259
|
+
HistoricoHato: {
|
|
260
|
+
RubroId: string;
|
|
261
|
+
CantidadCabezas: number;
|
|
262
|
+
PrecioCabeza: number;
|
|
263
|
+
Gestion: number;
|
|
264
|
+
}[];
|
|
265
|
+
Inventario: {
|
|
266
|
+
RubroId: string;
|
|
267
|
+
UUID: string;
|
|
268
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
269
|
+
Descripcion: string;
|
|
270
|
+
Cantidad: number;
|
|
271
|
+
Precio: number;
|
|
272
|
+
}[];
|
|
273
|
+
}>;
|
|
274
|
+
Desarrollo: z.ZodObject<{
|
|
275
|
+
EvaluacionId: z.ZodNumber;
|
|
276
|
+
FechaEvaluacion: z.ZodString;
|
|
277
|
+
ActividadEconomicaId: z.ZodNumber;
|
|
278
|
+
PersonaId: z.ZodNumber;
|
|
279
|
+
PID: z.ZodString;
|
|
280
|
+
NombreCompleto: z.ZodString;
|
|
281
|
+
Municipio: z.ZodString;
|
|
282
|
+
NombrePropiedad: z.ZodString;
|
|
283
|
+
TamannoHectareas: z.ZodNumber;
|
|
284
|
+
ActividadGanadera: z.ZodString;
|
|
285
|
+
CantidadProyeccion: z.ZodNumber;
|
|
286
|
+
Solicitudes: z.ZodArray<z.ZodObject<{
|
|
287
|
+
SolicitudOperacionId: z.ZodNumber;
|
|
288
|
+
TipoSolicitudOperacionId: z.ZodString;
|
|
289
|
+
Monto: z.ZodString;
|
|
290
|
+
Moneda: z.ZodString;
|
|
291
|
+
MonedaDesc: z.ZodString;
|
|
292
|
+
Plazo: z.ZodString;
|
|
293
|
+
TipoOperacionId: z.ZodString;
|
|
294
|
+
TipoOperacionDesc: z.ZodString;
|
|
295
|
+
}, "strip", z.ZodTypeAny, {
|
|
296
|
+
SolicitudOperacionId: number;
|
|
297
|
+
TipoSolicitudOperacionId: string;
|
|
298
|
+
Monto: string;
|
|
299
|
+
Moneda: string;
|
|
300
|
+
MonedaDesc: string;
|
|
301
|
+
Plazo: string;
|
|
302
|
+
TipoOperacionId: string;
|
|
303
|
+
TipoOperacionDesc: string;
|
|
304
|
+
}, {
|
|
305
|
+
SolicitudOperacionId: number;
|
|
306
|
+
TipoSolicitudOperacionId: string;
|
|
307
|
+
Monto: string;
|
|
308
|
+
Moneda: string;
|
|
309
|
+
MonedaDesc: string;
|
|
310
|
+
Plazo: string;
|
|
311
|
+
TipoOperacionId: string;
|
|
312
|
+
TipoOperacionDesc: string;
|
|
313
|
+
}>, "many">;
|
|
314
|
+
Avaluo: z.ZodArray<z.ZodObject<{
|
|
315
|
+
RubroId: z.ZodString;
|
|
316
|
+
Descripcion: z.ZodString;
|
|
317
|
+
PlanInversion: z.ZodNullable<z.ZodNumber>;
|
|
318
|
+
Equivalencia: z.ZodNullable<z.ZodNumber>;
|
|
319
|
+
Porcentaje: z.ZodNullable<z.ZodNumber>;
|
|
320
|
+
Justificaciones: z.ZodNullable<z.ZodString>;
|
|
321
|
+
HatoInicial: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
322
|
+
PrecioVenta: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
323
|
+
}, "strip", z.ZodTypeAny, {
|
|
324
|
+
RubroId: string;
|
|
325
|
+
Descripcion: string;
|
|
326
|
+
PlanInversion: number | null;
|
|
327
|
+
Equivalencia: number | null;
|
|
328
|
+
Porcentaje: number | null;
|
|
329
|
+
Justificaciones: string | null;
|
|
330
|
+
HatoInicial?: number | null | undefined;
|
|
331
|
+
PrecioVenta?: number | null | undefined;
|
|
332
|
+
}, {
|
|
333
|
+
RubroId: string;
|
|
334
|
+
Descripcion: string;
|
|
335
|
+
PlanInversion: number | null;
|
|
336
|
+
Equivalencia: number | null;
|
|
337
|
+
Porcentaje: number | null;
|
|
338
|
+
Justificaciones: string | null;
|
|
339
|
+
HatoInicial?: number | null | undefined;
|
|
340
|
+
PrecioVenta?: number | null | undefined;
|
|
341
|
+
}>, "many">;
|
|
342
|
+
Parametros: z.ZodArray<z.ZodObject<{
|
|
343
|
+
RubroId: z.ZodString;
|
|
344
|
+
Descripcion: z.ZodString;
|
|
345
|
+
Tipo: z.ZodNullable<z.ZodString>;
|
|
346
|
+
Porcentaje: z.ZodNullable<z.ZodString>;
|
|
347
|
+
Bandera: z.ZodNullable<z.ZodString>;
|
|
348
|
+
Justificaciones: z.ZodNullable<z.ZodString>;
|
|
349
|
+
}, "strip", z.ZodTypeAny, {
|
|
350
|
+
RubroId: string;
|
|
351
|
+
Descripcion: string;
|
|
352
|
+
Porcentaje: string | null;
|
|
353
|
+
Justificaciones: string | null;
|
|
354
|
+
Tipo: string | null;
|
|
355
|
+
Bandera: string | null;
|
|
356
|
+
}, {
|
|
357
|
+
RubroId: string;
|
|
358
|
+
Descripcion: string;
|
|
359
|
+
Porcentaje: string | null;
|
|
360
|
+
Justificaciones: string | null;
|
|
361
|
+
Tipo: string | null;
|
|
362
|
+
Bandera: string | null;
|
|
363
|
+
}>, "many">;
|
|
364
|
+
}, "strip", z.ZodTypeAny, {
|
|
365
|
+
EvaluacionId: number;
|
|
366
|
+
ActividadEconomicaId: number;
|
|
367
|
+
PID: string;
|
|
368
|
+
FechaEvaluacion: string;
|
|
369
|
+
PersonaId: number;
|
|
370
|
+
NombreCompleto: string;
|
|
371
|
+
Municipio: string;
|
|
372
|
+
NombrePropiedad: string;
|
|
373
|
+
TamannoHectareas: number;
|
|
374
|
+
ActividadGanadera: string;
|
|
375
|
+
CantidadProyeccion: number;
|
|
376
|
+
Solicitudes: {
|
|
377
|
+
SolicitudOperacionId: number;
|
|
378
|
+
TipoSolicitudOperacionId: string;
|
|
379
|
+
Monto: string;
|
|
380
|
+
Moneda: string;
|
|
381
|
+
MonedaDesc: string;
|
|
382
|
+
Plazo: string;
|
|
383
|
+
TipoOperacionId: string;
|
|
384
|
+
TipoOperacionDesc: string;
|
|
385
|
+
}[];
|
|
386
|
+
Avaluo: {
|
|
387
|
+
RubroId: string;
|
|
388
|
+
Descripcion: string;
|
|
389
|
+
PlanInversion: number | null;
|
|
390
|
+
Equivalencia: number | null;
|
|
391
|
+
Porcentaje: number | null;
|
|
392
|
+
Justificaciones: string | null;
|
|
393
|
+
HatoInicial?: number | null | undefined;
|
|
394
|
+
PrecioVenta?: number | null | undefined;
|
|
395
|
+
}[];
|
|
396
|
+
Parametros: {
|
|
397
|
+
RubroId: string;
|
|
398
|
+
Descripcion: string;
|
|
399
|
+
Porcentaje: string | null;
|
|
400
|
+
Justificaciones: string | null;
|
|
401
|
+
Tipo: string | null;
|
|
402
|
+
Bandera: string | null;
|
|
403
|
+
}[];
|
|
404
|
+
}, {
|
|
405
|
+
EvaluacionId: number;
|
|
406
|
+
ActividadEconomicaId: number;
|
|
407
|
+
PID: string;
|
|
408
|
+
FechaEvaluacion: string;
|
|
409
|
+
PersonaId: number;
|
|
410
|
+
NombreCompleto: string;
|
|
411
|
+
Municipio: string;
|
|
412
|
+
NombrePropiedad: string;
|
|
413
|
+
TamannoHectareas: number;
|
|
414
|
+
ActividadGanadera: string;
|
|
415
|
+
CantidadProyeccion: number;
|
|
416
|
+
Solicitudes: {
|
|
417
|
+
SolicitudOperacionId: number;
|
|
418
|
+
TipoSolicitudOperacionId: string;
|
|
419
|
+
Monto: string;
|
|
420
|
+
Moneda: string;
|
|
421
|
+
MonedaDesc: string;
|
|
422
|
+
Plazo: string;
|
|
423
|
+
TipoOperacionId: string;
|
|
424
|
+
TipoOperacionDesc: string;
|
|
425
|
+
}[];
|
|
426
|
+
Avaluo: {
|
|
427
|
+
RubroId: string;
|
|
428
|
+
Descripcion: string;
|
|
429
|
+
PlanInversion: number | null;
|
|
430
|
+
Equivalencia: number | null;
|
|
431
|
+
Porcentaje: number | null;
|
|
432
|
+
Justificaciones: string | null;
|
|
433
|
+
HatoInicial?: number | null | undefined;
|
|
434
|
+
PrecioVenta?: number | null | undefined;
|
|
435
|
+
}[];
|
|
436
|
+
Parametros: {
|
|
437
|
+
RubroId: string;
|
|
438
|
+
Descripcion: string;
|
|
439
|
+
Porcentaje: string | null;
|
|
440
|
+
Justificaciones: string | null;
|
|
441
|
+
Tipo: string | null;
|
|
442
|
+
Bandera: string | null;
|
|
443
|
+
}[];
|
|
444
|
+
}>;
|
|
445
|
+
Ventas: z.ZodObject<{
|
|
446
|
+
EvaluacionId: z.ZodNumber;
|
|
447
|
+
ActividadEconomicaId: z.ZodNumber;
|
|
448
|
+
PID: z.ZodNumber;
|
|
449
|
+
Ventas: z.ZodArray<z.ZodObject<{
|
|
450
|
+
RubroId: z.ZodString;
|
|
451
|
+
IndicadorABM: z.ZodEnum<["N", "M"]>;
|
|
452
|
+
Unidad: z.ZodString;
|
|
453
|
+
CicloId: z.ZodString;
|
|
454
|
+
}, "strip", z.ZodTypeAny, {
|
|
455
|
+
RubroId: string;
|
|
456
|
+
IndicadorABM: "N" | "M";
|
|
457
|
+
Unidad: string;
|
|
458
|
+
CicloId: string;
|
|
459
|
+
}, {
|
|
460
|
+
RubroId: string;
|
|
461
|
+
IndicadorABM: "N" | "M";
|
|
462
|
+
Unidad: string;
|
|
463
|
+
CicloId: string;
|
|
464
|
+
}>, "many">;
|
|
465
|
+
Estacionalidad: z.ZodArray<z.ZodObject<{
|
|
466
|
+
IndicadorABM: z.ZodEnum<["N", "M"]>;
|
|
467
|
+
RubroId: z.ZodString;
|
|
468
|
+
Correlativo: z.ZodNumber;
|
|
469
|
+
Monto: z.ZodNumber;
|
|
470
|
+
}, "strip", z.ZodTypeAny, {
|
|
471
|
+
RubroId: string;
|
|
472
|
+
IndicadorABM: "N" | "M";
|
|
473
|
+
Monto: number;
|
|
474
|
+
Correlativo: number;
|
|
475
|
+
}, {
|
|
476
|
+
RubroId: string;
|
|
477
|
+
IndicadorABM: "N" | "M";
|
|
478
|
+
Monto: number;
|
|
479
|
+
Correlativo: number;
|
|
480
|
+
}>, "many">;
|
|
481
|
+
}, "strip", z.ZodTypeAny, {
|
|
482
|
+
EvaluacionId: number;
|
|
483
|
+
ActividadEconomicaId: number;
|
|
484
|
+
PID: number;
|
|
485
|
+
Ventas: {
|
|
486
|
+
RubroId: string;
|
|
487
|
+
IndicadorABM: "N" | "M";
|
|
488
|
+
Unidad: string;
|
|
489
|
+
CicloId: string;
|
|
490
|
+
}[];
|
|
491
|
+
Estacionalidad: {
|
|
492
|
+
RubroId: string;
|
|
493
|
+
IndicadorABM: "N" | "M";
|
|
494
|
+
Monto: number;
|
|
495
|
+
Correlativo: number;
|
|
496
|
+
}[];
|
|
497
|
+
}, {
|
|
498
|
+
EvaluacionId: number;
|
|
499
|
+
ActividadEconomicaId: number;
|
|
500
|
+
PID: number;
|
|
501
|
+
Ventas: {
|
|
502
|
+
RubroId: string;
|
|
503
|
+
IndicadorABM: "N" | "M";
|
|
504
|
+
Unidad: string;
|
|
505
|
+
CicloId: string;
|
|
506
|
+
}[];
|
|
507
|
+
Estacionalidad: {
|
|
508
|
+
RubroId: string;
|
|
509
|
+
IndicadorABM: "N" | "M";
|
|
510
|
+
Monto: number;
|
|
511
|
+
Correlativo: number;
|
|
512
|
+
}[];
|
|
513
|
+
}>;
|
|
514
|
+
}, "strip", z.ZodTypeAny, {
|
|
515
|
+
Desarrollo: {
|
|
516
|
+
EvaluacionId: number;
|
|
517
|
+
ActividadEconomicaId: number;
|
|
518
|
+
PID: string;
|
|
519
|
+
FechaEvaluacion: string;
|
|
520
|
+
PersonaId: number;
|
|
521
|
+
NombreCompleto: string;
|
|
522
|
+
Municipio: string;
|
|
523
|
+
NombrePropiedad: string;
|
|
524
|
+
TamannoHectareas: number;
|
|
525
|
+
ActividadGanadera: string;
|
|
526
|
+
CantidadProyeccion: number;
|
|
527
|
+
Solicitudes: {
|
|
528
|
+
SolicitudOperacionId: number;
|
|
529
|
+
TipoSolicitudOperacionId: string;
|
|
530
|
+
Monto: string;
|
|
531
|
+
Moneda: string;
|
|
532
|
+
MonedaDesc: string;
|
|
533
|
+
Plazo: string;
|
|
534
|
+
TipoOperacionId: string;
|
|
535
|
+
TipoOperacionDesc: string;
|
|
536
|
+
}[];
|
|
537
|
+
Avaluo: {
|
|
538
|
+
RubroId: string;
|
|
539
|
+
Descripcion: string;
|
|
540
|
+
PlanInversion: number | null;
|
|
541
|
+
Equivalencia: number | null;
|
|
542
|
+
Porcentaje: number | null;
|
|
543
|
+
Justificaciones: string | null;
|
|
544
|
+
HatoInicial?: number | null | undefined;
|
|
545
|
+
PrecioVenta?: number | null | undefined;
|
|
546
|
+
}[];
|
|
547
|
+
Parametros: {
|
|
548
|
+
RubroId: string;
|
|
549
|
+
Descripcion: string;
|
|
550
|
+
Porcentaje: string | null;
|
|
551
|
+
Justificaciones: string | null;
|
|
552
|
+
Tipo: string | null;
|
|
553
|
+
Bandera: string | null;
|
|
554
|
+
}[];
|
|
555
|
+
};
|
|
556
|
+
Auxiliar: {
|
|
557
|
+
EvaluacionId: number;
|
|
558
|
+
ActividadEconomicaId: number;
|
|
559
|
+
PID: number;
|
|
560
|
+
PropiedadesGanaderas: {
|
|
561
|
+
UUID: string;
|
|
562
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
563
|
+
TipoGanadoId: string;
|
|
564
|
+
RazaGanadoId: string;
|
|
565
|
+
Fecha: string;
|
|
566
|
+
TipoDocumentoId: string;
|
|
567
|
+
Rubros: {
|
|
568
|
+
RubroId: string;
|
|
569
|
+
CantidadCabezas: number;
|
|
570
|
+
PesoPromedio: number;
|
|
571
|
+
PrecioCabeza: number;
|
|
572
|
+
PrecioCabezaBalance: number;
|
|
573
|
+
Total?: number | undefined;
|
|
574
|
+
}[];
|
|
575
|
+
PesoAclaracion: string;
|
|
576
|
+
PrecioAclaracion: string;
|
|
577
|
+
Total?: number | undefined;
|
|
578
|
+
TipoGanadoDesc?: string | undefined;
|
|
579
|
+
RazaGanadoDesc?: string | undefined;
|
|
580
|
+
TipoDocumentoDesc?: string | undefined;
|
|
581
|
+
}[];
|
|
582
|
+
HistoricoHato: {
|
|
583
|
+
RubroId: string;
|
|
584
|
+
CantidadCabezas: number;
|
|
585
|
+
PrecioCabeza: number;
|
|
586
|
+
Gestion: number;
|
|
587
|
+
}[];
|
|
588
|
+
Inventario: {
|
|
589
|
+
RubroId: string;
|
|
590
|
+
UUID: string;
|
|
591
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
592
|
+
Descripcion: string;
|
|
593
|
+
Cantidad: number;
|
|
594
|
+
Precio: number;
|
|
595
|
+
}[];
|
|
596
|
+
};
|
|
597
|
+
Ventas: {
|
|
598
|
+
EvaluacionId: number;
|
|
599
|
+
ActividadEconomicaId: number;
|
|
600
|
+
PID: number;
|
|
601
|
+
Ventas: {
|
|
602
|
+
RubroId: string;
|
|
603
|
+
IndicadorABM: "N" | "M";
|
|
604
|
+
Unidad: string;
|
|
605
|
+
CicloId: string;
|
|
606
|
+
}[];
|
|
607
|
+
Estacionalidad: {
|
|
608
|
+
RubroId: string;
|
|
609
|
+
IndicadorABM: "N" | "M";
|
|
610
|
+
Monto: number;
|
|
611
|
+
Correlativo: number;
|
|
612
|
+
}[];
|
|
613
|
+
};
|
|
614
|
+
}, {
|
|
615
|
+
Desarrollo: {
|
|
616
|
+
EvaluacionId: number;
|
|
617
|
+
ActividadEconomicaId: number;
|
|
618
|
+
PID: string;
|
|
619
|
+
FechaEvaluacion: string;
|
|
620
|
+
PersonaId: number;
|
|
621
|
+
NombreCompleto: string;
|
|
622
|
+
Municipio: string;
|
|
623
|
+
NombrePropiedad: string;
|
|
624
|
+
TamannoHectareas: number;
|
|
625
|
+
ActividadGanadera: string;
|
|
626
|
+
CantidadProyeccion: number;
|
|
627
|
+
Solicitudes: {
|
|
628
|
+
SolicitudOperacionId: number;
|
|
629
|
+
TipoSolicitudOperacionId: string;
|
|
630
|
+
Monto: string;
|
|
631
|
+
Moneda: string;
|
|
632
|
+
MonedaDesc: string;
|
|
633
|
+
Plazo: string;
|
|
634
|
+
TipoOperacionId: string;
|
|
635
|
+
TipoOperacionDesc: string;
|
|
636
|
+
}[];
|
|
637
|
+
Avaluo: {
|
|
638
|
+
RubroId: string;
|
|
639
|
+
Descripcion: string;
|
|
640
|
+
PlanInversion: number | null;
|
|
641
|
+
Equivalencia: number | null;
|
|
642
|
+
Porcentaje: number | null;
|
|
643
|
+
Justificaciones: string | null;
|
|
644
|
+
HatoInicial?: number | null | undefined;
|
|
645
|
+
PrecioVenta?: number | null | undefined;
|
|
646
|
+
}[];
|
|
647
|
+
Parametros: {
|
|
648
|
+
RubroId: string;
|
|
649
|
+
Descripcion: string;
|
|
650
|
+
Porcentaje: string | null;
|
|
651
|
+
Justificaciones: string | null;
|
|
652
|
+
Tipo: string | null;
|
|
653
|
+
Bandera: string | null;
|
|
654
|
+
}[];
|
|
655
|
+
};
|
|
656
|
+
Auxiliar: {
|
|
657
|
+
EvaluacionId: number;
|
|
658
|
+
ActividadEconomicaId: number;
|
|
659
|
+
PID: number;
|
|
660
|
+
PropiedadesGanaderas: {
|
|
661
|
+
UUID: string;
|
|
662
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
663
|
+
TipoGanadoId: string;
|
|
664
|
+
RazaGanadoId: string;
|
|
665
|
+
Fecha: string;
|
|
666
|
+
TipoDocumentoId: string;
|
|
667
|
+
Rubros: {
|
|
668
|
+
RubroId: string;
|
|
669
|
+
CantidadCabezas: number;
|
|
670
|
+
PesoPromedio: number;
|
|
671
|
+
PrecioCabeza: number;
|
|
672
|
+
PrecioCabezaBalance: number;
|
|
673
|
+
Total?: number | undefined;
|
|
674
|
+
}[];
|
|
675
|
+
PesoAclaracion: string;
|
|
676
|
+
PrecioAclaracion: string;
|
|
677
|
+
Total?: number | undefined;
|
|
678
|
+
TipoGanadoDesc?: string | undefined;
|
|
679
|
+
RazaGanadoDesc?: string | undefined;
|
|
680
|
+
TipoDocumentoDesc?: string | undefined;
|
|
681
|
+
}[];
|
|
682
|
+
HistoricoHato: {
|
|
683
|
+
RubroId: string;
|
|
684
|
+
CantidadCabezas: number;
|
|
685
|
+
PrecioCabeza: number;
|
|
686
|
+
Gestion: number;
|
|
687
|
+
}[];
|
|
688
|
+
Inventario: {
|
|
689
|
+
RubroId: string;
|
|
690
|
+
UUID: string;
|
|
691
|
+
IndicadorABM: "A" | "N" | "M" | "B";
|
|
692
|
+
Descripcion: string;
|
|
693
|
+
Cantidad: number;
|
|
694
|
+
Precio: number;
|
|
695
|
+
}[];
|
|
696
|
+
};
|
|
697
|
+
Ventas: {
|
|
698
|
+
EvaluacionId: number;
|
|
699
|
+
ActividadEconomicaId: number;
|
|
700
|
+
PID: number;
|
|
701
|
+
Ventas: {
|
|
702
|
+
RubroId: string;
|
|
703
|
+
IndicadorABM: "N" | "M";
|
|
704
|
+
Unidad: string;
|
|
705
|
+
CicloId: string;
|
|
706
|
+
}[];
|
|
707
|
+
Estacionalidad: {
|
|
708
|
+
RubroId: string;
|
|
709
|
+
IndicadorABM: "N" | "M";
|
|
710
|
+
Monto: number;
|
|
711
|
+
Correlativo: number;
|
|
712
|
+
}[];
|
|
713
|
+
};
|
|
714
|
+
}>;
|
|
715
|
+
export type CalcVentasType = z.infer<typeof CalcVentas>;
|
|
716
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.VentasPecSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const auxiliar_schema_1 = require("./auxiliar.schema");
|
|
6
|
+
const desarrolloResponse_Schema_1 = require("./desarrolloResponse.Schema");
|
|
7
|
+
const ventas = zod_1.z.object({
|
|
8
|
+
RubroId: zod_1.z.string().max(50),
|
|
9
|
+
IndicadorABM: zod_1.z.enum(['N', 'M']),
|
|
10
|
+
Unidad: zod_1.z.string().max(50),
|
|
11
|
+
CicloId: zod_1.z.string().max(20),
|
|
12
|
+
});
|
|
13
|
+
const estacionalidad = zod_1.z.object({
|
|
14
|
+
IndicadorABM: zod_1.z.enum(['N', 'M']),
|
|
15
|
+
RubroId: zod_1.z.string().max(50),
|
|
16
|
+
Correlativo: zod_1.z.number(),
|
|
17
|
+
Monto: zod_1.z.number(),
|
|
18
|
+
});
|
|
19
|
+
exports.VentasPecSchema = zod_1.z.object({
|
|
20
|
+
EvaluacionId: zod_1.z.number(),
|
|
21
|
+
ActividadEconomicaId: zod_1.z.number(),
|
|
22
|
+
PID: zod_1.z.number(),
|
|
23
|
+
Ventas: zod_1.z.array(ventas),
|
|
24
|
+
Estacionalidad: zod_1.z.array(estacionalidad),
|
|
25
|
+
});
|
|
26
|
+
const CalcVentas = zod_1.z.object({
|
|
27
|
+
Auxiliar: auxiliar_schema_1.AuxiliarSchema,
|
|
28
|
+
Desarrollo: desarrolloResponse_Schema_1.DesarrolloSchema,
|
|
29
|
+
Ventas: exports.VentasPecSchema,
|
|
30
|
+
});
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
// ACT_PEC_M36 TOROS
|
|
10
10
|
// ACT_PEC_NOV NOVILLOS > 3 AÑOS
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.getOrden = exports.RUBROS = exports.PARAMETROS = void 0;
|
|
12
|
+
exports.getMap = exports.getOrden = exports.RUBROS = exports.PARAMETROS = void 0;
|
|
13
13
|
// ACT_PEC_DES01 Índice de parición
|
|
14
14
|
// ACT_PEC_DES02 Índice de mortalidad < 1 año
|
|
15
15
|
// ACT_PEC_DES03 Índice de mortalidad > 1 año
|
|
@@ -60,3 +60,10 @@ const getOrden = (rubro) => {
|
|
|
60
60
|
return 9;
|
|
61
61
|
};
|
|
62
62
|
exports.getOrden = getOrden;
|
|
63
|
+
const getMap = (array, key) => {
|
|
64
|
+
return array.reduce((acc, item) => {
|
|
65
|
+
const id = item[key];
|
|
66
|
+
acc.set(id, item);
|
|
67
|
+
}, new Map());
|
|
68
|
+
};
|
|
69
|
+
exports.getMap = getMap;
|
|
@@ -22,7 +22,7 @@ const calcularTotal = (table, cantidad) => {
|
|
|
22
22
|
table.get('TOT01')[`C-${i}`] = tot01;
|
|
23
23
|
}
|
|
24
24
|
table.set('TOT02', { RubroId: 'TOT02', Descripcion: `Incremento del hato en ${cantidad}`,
|
|
25
|
-
[`C-${cantidad}`]: table.get('TOT01')[`C-${1}`] / table.get('TOT01')[`C-${cantidad}`] * 100 });
|
|
25
|
+
[`C-${cantidad}`]: 100 - table.get('TOT01')[`C-${1}`] / table.get('TOT01')[`C-${cantidad}`] * 100 });
|
|
26
26
|
return table;
|
|
27
27
|
};
|
|
28
28
|
exports.calcularTotal = calcularTotal;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getEstacionalidadCalc = exports.getEstacionalidadPorcentaje = exports.estacionalidadCalc = void 0;
|
|
4
|
+
const Constantes_1 = require("../Constantes");
|
|
5
|
+
const estacionalidadCalc = (ventasPrimitivo, ventasIngresos) => {
|
|
6
|
+
const ingresosMap = (0, Constantes_1.getMap)(ventasIngresos, 'RubroId');
|
|
7
|
+
const ventasCalc = ventasPrimitivo.Estacionalidad.map((item) => {
|
|
8
|
+
return Object.assign(Object.assign({}, item), { IngresoTotal: ingresosMap.get(item.RubroId).IngresoTotal, CalculoIngreso: ingresosMap.get(item.RubroId).IngresoTotal * item.Monto });
|
|
9
|
+
});
|
|
10
|
+
return ventasCalc;
|
|
11
|
+
};
|
|
12
|
+
exports.estacionalidadCalc = estacionalidadCalc;
|
|
13
|
+
const getEstacionalidadPorcentaje = (estacionalidad) => {
|
|
14
|
+
const result = estacionalidad.reduce((acc, item) => {
|
|
15
|
+
if (!acc.has('TOT01')) {
|
|
16
|
+
acc.set('TOT01', {
|
|
17
|
+
RubroId: 'TOT01',
|
|
18
|
+
Descripcion: 'TOTAL',
|
|
19
|
+
IngresoTotal: 0,
|
|
20
|
+
Total: 0
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
if (!acc.has(item.RubroId)) {
|
|
24
|
+
acc.set(item.RubroId, {
|
|
25
|
+
RubroId: estacionalidad.RubroId,
|
|
26
|
+
Descripcion: estacionalidad.Descripcion,
|
|
27
|
+
IngresoTotal: estacionalidad.IngresoTotal,
|
|
28
|
+
Total: 0
|
|
29
|
+
});
|
|
30
|
+
acc.get('TOT01').IngresoTotal += estacionalidad.IngresoTotal;
|
|
31
|
+
}
|
|
32
|
+
acc.get(item.RubroId)[`C-${item.Correlativo}`] = item.Monto;
|
|
33
|
+
acc.get(item.RubroId)[`label-${item.Correlativo}`] = item.CorrelativoDesc;
|
|
34
|
+
acc.get(item.RubroId).Total += item.Monto;
|
|
35
|
+
}, new Map());
|
|
36
|
+
return Array.from(result);
|
|
37
|
+
};
|
|
38
|
+
exports.getEstacionalidadPorcentaje = getEstacionalidadPorcentaje;
|
|
39
|
+
const getEstacionalidadCalc = (estacionalidad) => {
|
|
40
|
+
const result = estacionalidad.reduce((acc, item) => {
|
|
41
|
+
const TOT01 = 'TOT01';
|
|
42
|
+
if (!acc.has(TOT01)) {
|
|
43
|
+
acc.set(TOT01, {
|
|
44
|
+
RubroId: TOT01,
|
|
45
|
+
Descripcion: 'TOTAL',
|
|
46
|
+
Total: 0
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
if (!acc.has(item.RubroId)) {
|
|
50
|
+
acc.set(item.RubroId, {
|
|
51
|
+
RubroId: estacionalidad.RubroId,
|
|
52
|
+
Descripcion: estacionalidad.Descripcion,
|
|
53
|
+
IngresoTotal: estacionalidad.IngresoTotal,
|
|
54
|
+
Total: 0
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
acc.get(item.RubroId)[`C-${item.Correlativo}`] = item.CalculoIngreso;
|
|
58
|
+
acc.get(item.RubroId)[`label-${item.Correlativo}`] = item.CorrelativoDesc;
|
|
59
|
+
acc.get(TOT01)[`C-${item.Correlativo}`] += item.CalculoIngreso;
|
|
60
|
+
acc.get(item.RubroId).Total += item.CalculoIngreso;
|
|
61
|
+
}, new Map());
|
|
62
|
+
return Array.from(result);
|
|
63
|
+
};
|
|
64
|
+
exports.getEstacionalidadCalc = getEstacionalidadCalc;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const calcular: (ventasPrimitivo: any, auxiliarPrimitivo: any, desarrolloCalculado: any) => any;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.calcular = void 0;
|
|
4
|
+
const Constantes_1 = require("../Constantes");
|
|
5
|
+
const calcular = (ventasPrimitivo, auxiliarPrimitivo, desarrolloCalculado) => {
|
|
6
|
+
const gestionMaxima = Math.max(auxiliarPrimitivo.HistoricoHato.map((item) => item.Gestion));
|
|
7
|
+
const historicoHato = auxiliarPrimitivo.HistoricoHato.filter((item) => item.Gestion == gestionMaxima);
|
|
8
|
+
const hatoMap = (0, Constantes_1.getMap)(historicoHato, 'RubroId');
|
|
9
|
+
const avaluoMap = (0, Constantes_1.getMap)(desarrolloCalculado.Avaluo, 'RubroId');
|
|
10
|
+
return ventasPrimitivo.Ventas.map((item) => {
|
|
11
|
+
const cantidad = hatoMap.get(item.RubroId).CantidadCabezas;
|
|
12
|
+
const precio = avaluoMap.get(item.RubroId).PrecioVenta;
|
|
13
|
+
return Object.assign(Object.assign({}, item), { Animales: cantidad, Precio: precio, IngresoTotal: cantidad * precio });
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
exports.calcular = calcular;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
const ventasIngresosCalc = __importStar(require("./ventas.detail/ventasIngresosCalc"));
|
|
30
|
+
const desarrollo_strategy_1 = __importDefault(require("./desarrollo.strategy"));
|
|
31
|
+
class VentasPec {
|
|
32
|
+
execute(data) {
|
|
33
|
+
let result = {};
|
|
34
|
+
//const ventasIngresos = ventasIngresosCalc.calcular()
|
|
35
|
+
const dataDesarrollo = {
|
|
36
|
+
Desarrollo: data.Desarrollo,
|
|
37
|
+
Auxiliar: data.Auxiliar
|
|
38
|
+
};
|
|
39
|
+
const desarrolloCalc = new desarrollo_strategy_1.default().execute(dataDesarrollo);
|
|
40
|
+
result.VentasIngreso = ventasIngresosCalc.calcular(data.Ventas, data.Auxiliar, desarrolloCalc);
|
|
41
|
+
return result;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
exports.default = VentasPec;
|