bdpformulas 1.0.69 → 1.0.70

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.
@@ -1,4 +1,4 @@
1
- import { Strategy } from "../../strategy.interface";
1
+ import { Strategy } from '../../strategy.interface';
2
2
  export default class SupuestosStrategy implements Strategy {
3
3
  cantidadGestiones: number;
4
4
  data: any;
@@ -13,12 +13,13 @@ class SupuestosStrategy {
13
13
  //@ts-ignore
14
14
  const origenRow = origen.find((item) => item.RubroId == rubroOrigen);
15
15
  //@ts-ignore
16
- let destinoRow = this.data.find((item) => item.RubroId == rubroDestino);
16
+ const destinoRow = this.data.find((item) => item.RubroId == rubroDestino);
17
17
  if (!percent)
18
18
  destinoRow.Gestion1 = this.cleanNumber(origenRow[`Gestion${this.cantidadGestiones}`]);
19
19
  else {
20
20
  destinoRow.Gestion1 = this.cleanNumber(origenRow[`Gestion${this.cantidadGestiones}%`] / 100);
21
- destinoRow.Gestion1 = Math.round(destinoRow.Gestion1 * 100) / 100;
21
+ destinoRow.Gestion1 =
22
+ Math.round(destinoRow.Gestion1 * 100) / 100;
22
23
  }
23
24
  }
24
25
  }
@@ -31,17 +32,21 @@ class SupuestosStrategy {
31
32
  execute(data) {
32
33
  this.data = data.Supuestos;
33
34
  this.cantidadGestiones = data.CantidadGestiones;
34
- let rowDeprecCoef = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10402');
35
- let rowDeprecValue = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10403');
36
- let rowDeprecCoefLeasing = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10404');
37
- let rowDeprecValueLeasing = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10405');
35
+ const rowDeprecCoef = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10402');
36
+ const rowDeprecValue = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10403');
37
+ const rowDeprecCoefLeasing = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10404');
38
+ const rowDeprecValueLeasing = data.Supuestos.find((item) => item.RubroId == 'ACT_SUP_10405');
38
39
  for (let i = 1; i <= data.CantidadProyeccion; i++) {
39
40
  const activosFijosNetos = data.BalanceProyectado.find((item) => item.Correlativo == i && item.RubroId == 'BP_ACT_EF_12003');
40
41
  const activosPorArrendamiento = data.BalanceProyectado.find((item) => item.Correlativo == i && item.RubroId == 'BP_ACT_EF_12004');
41
42
  if (rowDeprecValue != null)
42
- rowDeprecValue[`Gestion${i}`] = this.cleanNumber(rowDeprecCoef[`Gestion${i}`]) * this.cleanNumber(activosFijosNetos.Monto);
43
+ rowDeprecValue[`Gestion${i}`] =
44
+ this.cleanNumber(rowDeprecCoef[`Gestion${i}`]) *
45
+ this.cleanNumber(activosFijosNetos.Monto);
43
46
  if (rowDeprecValueLeasing != null)
44
- rowDeprecValueLeasing[`Gestion${i}`] = this.cleanNumber(rowDeprecCoefLeasing[`Gestion${i}`]) * this.cleanNumber(activosPorArrendamiento.Monto);
47
+ rowDeprecValueLeasing[`Gestion${i}`] =
48
+ this.cleanNumber(rowDeprecCoefLeasing[`Gestion${i}`]) *
49
+ this.cleanNumber(activosPorArrendamiento.Monto);
45
50
  }
46
51
  this.anadirPrecalculo(data.EEFF.eerr, 'ACT_EF_42000', 'ACT_SUP_10101');
47
52
  this.anadirPrecalculo(data.EEFF.eerr, 'ACT_EF_44003', 'ACT_SUP_10104');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bdpformulas",
3
- "version": "1.0.69",
3
+ "version": "1.0.70",
4
4
  "description": "",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",