sigesp 0.9.57-20230905 → 0.9.59-20230906

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.
@@ -2994,8 +2994,8 @@ class MServiceCharge extends MBasicModel {
2994
2994
  }
2995
2995
 
2996
2996
  class MEmpresa extends MBasicModel {
2997
- constructor() {
2998
- super(...arguments);
2997
+ constructor(e) {
2998
+ super();
2999
2999
  this.idEmpresa = 0;
3000
3000
  this.rif = '';
3001
3001
  this.nit = '';
@@ -3041,6 +3041,56 @@ class MEmpresa extends MBasicModel {
3041
3041
  this.codigoFuenteFinanciamintoMostrar = '';
3042
3042
  this.codigoCentroCosto = '';
3043
3043
  this.estructuraPresupuestaria = '';
3044
+ if (e) {
3045
+ this.idEmpresa = +e.id_empresa;
3046
+ this.rif = e.rifemp;
3047
+ this.nit = e.nitemp;
3048
+ this.nombre = e.nomemp;
3049
+ this.titulo = e.titemp;
3050
+ this.direccion = e.diremp;
3051
+ this.telefono = e.telemp;
3052
+ this.fax = e.faxemp;
3053
+ this.email = e.emaemp;
3054
+ this.paginaWeb = e.webemp;
3055
+ this.CIIU = e.ciiuemp;
3056
+ this.numeroLicencia = e.numlic;
3057
+ this.codigoPostal = e.codpos;
3058
+ this.codigoPais = e.codpai;
3059
+ this.codigoEstado = e.codest;
3060
+ this.codigoMunicipio = e.codmun;
3061
+ this.codigoParroquia = e.codpar;
3062
+ this.codigoComunidad = e.codmun;
3063
+ this.codigoMoneda = e.codmon;
3064
+ this.nombreRepresentanteLegal = e.nomrepleg;
3065
+ this.cedulaRepresentanteLegal = e.cedrepleg;
3066
+ this.telefonoRepresentanteLegal = e.telrepleg;
3067
+ this.carreraRepresentanteLegal = e.carrepleg;
3068
+ this.telefonoOficinaRepresentanteLegal = e.telrepleg;
3069
+ this.periodoFiscal = e.perfiscal;
3070
+ this.numeroSeguroSocial = e.nroivss;
3071
+ this.estatusPresupuesto = e.presupuesto == '1';
3072
+ this.descripcionPais = e.despai;
3073
+ this.descripcionEstado = e.desest;
3074
+ this.descripcionMunicipio = e.desmun;
3075
+ this.descripcionParroquia = e.despar;
3076
+ this.descripcionComunidad = e.descom;
3077
+ this.cuentaDiferencialCambiario = e.cuenta_diferencial;
3078
+ this.idEP1 = +e.id_ep1;
3079
+ this.idEP2 = +e.id_ep2;
3080
+ this.idEP3 = +e.id_ep3;
3081
+ this.idEP4 = +e.id_ep4;
3082
+ this.idEP5 = +e.id_ep5;
3083
+ this.codigoFuenteFinanciaminto = +e.codfuefin;
3084
+ this.idUnidadAdministrativa = +e.id_uniadm;
3085
+ this.denominacionUnidadAdministrativa = e.denuniadm;
3086
+ this.codigoUnidadAdministrativa = e.coduniadm;
3087
+ this.codigoFuenteFinanciamintoMostrar = e.codigoftefin;
3088
+ this.codigoCentroCosto = e.codcencos;
3089
+ this.estructuraPresupuestaria = e.estpre;
3090
+ }
3091
+ else {
3092
+ this.isNew = true;
3093
+ }
3044
3094
  }
3045
3095
  dataInterface() {
3046
3096
  return {
@@ -5557,18 +5607,24 @@ class MTipoDepositos extends MBasicModel {
5557
5607
  }
5558
5608
  }
5559
5609
 
5560
- class MComunidad {
5610
+ class MComunidad extends MBasicModel {
5561
5611
  constructor(comunidad) {
5562
- this.codestado = comunidad.codestado;
5563
- this.codigo = comunidad.codigo;
5564
- this.codmunicipio = comunidad.codmunicipio;
5565
- this.codparroquia = comunidad.codparroquia;
5566
- this.comunidad = comunidad.comunidad;
5567
- this.estado = comunidad.estado;
5568
- this.municipio = comunidad.municipio;
5569
- this.pais = comunidad.pais;
5570
- this.parroquia = comunidad.parroquia;
5571
- this.prefijo = comunidad.prefijo;
5612
+ super();
5613
+ if (comunidad) {
5614
+ this.codestado = comunidad.codestado;
5615
+ this.codigo = comunidad.codigo;
5616
+ this.codmunicipio = comunidad.codmunicipio;
5617
+ this.codparroquia = comunidad.codparroquia;
5618
+ this.comunidad = comunidad.comunidad;
5619
+ this.estado = comunidad.estado;
5620
+ this.municipio = comunidad.municipio;
5621
+ this.pais = comunidad.pais;
5622
+ this.parroquia = comunidad.parroquia;
5623
+ this.prefijo = comunidad.prefijo;
5624
+ }
5625
+ else {
5626
+ this.isNew = true;
5627
+ }
5572
5628
  }
5573
5629
  }
5574
5630
 
@@ -7016,9 +7072,9 @@ class SigespService {
7016
7072
  *
7017
7073
  */
7018
7074
  getCompany(tipo, id) {
7019
- return this.http.get(`${this.URL}/dao/cfg/empresas_dao.php?tipo=${tipo}&id=${id}`, { headers: this.getHttpHeaders() }).pipe(retry(3), catchError(this.handlerError), map((res) => {
7075
+ return this.http.get(`${this.URL}/dao/cfg/empresas_dao.php?tipo=${tipo}&id=${id}`, { headers: this.getHttpHeaders() }).pipe(map((res) => {
7020
7076
  if (res.success) {
7021
- res.data = res.data.map(e => new MEmpresa());
7077
+ res.data = res.data.map(e => new MEmpresa(e));
7022
7078
  }
7023
7079
  return res;
7024
7080
  }));