File: /var/www/web.enelar.com.co/dist/browser/chunk-IZGP45IH.js
import{a as Ze,b as Ke}from"./chunk-HWZY4DAM.js";import{a as P}from"./chunk-DKSHFX33.js";import{a as C}from"./chunk-DNWRUWSY.js";import{a as He}from"./chunk-PVD42JTF.js";import{a as se}from"./chunk-VYJOTIQG.js";import{a as je,b as Oe,d as ze,e as We,f as le}from"./chunk-73QXNGVV.js";import{a as qe,b as Qe,c as Ue,d as Je}from"./chunk-2DV2IJZ3.js";import"./chunk-DNVSFO2Q.js";import"./chunk-Q6P2AG2Q.js";import{a as we,b as ie}from"./chunk-UGKVLYDY.js";import"./chunk-4T6JHK7T.js";import{b as Ce}from"./chunk-NOX4BB7Y.js";import{a as Le,b as Ne}from"./chunk-FN4BVT7F.js";import{a as ke,b as Be}from"./chunk-IZBGWZHV.js";import"./chunk-MEI5P7PY.js";import{a as _e,b as ve}from"./chunk-M2XGXZBH.js";import{a as be,d as ye,e as Te,f as Ae,j as Ge}from"./chunk-YZB5RIY6.js";import{a as I}from"./chunk-FWIIQLPA.js";import{a as M}from"./chunk-J5MNQ3LA.js";import{a as oe,b as re,h as ae,i as ne,k as Se,l as Ee,m as xe,n as De,o as Re,p as Fe,q as Me,r as Ie,s as Pe,t as Ve}from"./chunk-3PWCL6RG.js";import"./chunk-O3VRXXRR.js";import{a as ge,b as fe}from"./chunk-ZUNNDRPI.js";import"./chunk-KDH6VC4N.js";import{b as q,d as T,f as Q,g as U,i as J,j as H,k as Z,l as K,n as Y,o as ee,p as te}from"./chunk-FB5LCIVC.js";import"./chunk-RP3BBTTB.js";import{A as $,d as F,e as z,n as W,z as X}from"./chunk-VJI6KQJL.js";import{Ba as me,C as S,Ca as pe,D as E,Da as ce,Fa as f,Ga as x,Ha as ue,I as h,J as g,Ja as k,Ka as B,La as O,Nb as he,Oa as D,Q as b,Y as s,Ya as L,Z as v,Za as N,ha as y,ja as l,ma as V,na as de,pa as n,qa as a,ra as d,va as G,vb as R,wa as u,xa as _,y as w}from"./chunk-MDSVL5BJ.js";import"./chunk-ODN5LVDJ.js";var dt=["fileUpload"],ut=["appUploadOneFile"],ht=()=>({width:"60vw"}),gt=()=>({width:"25vw"});function ft(r,o){if(r&1&&d(0,"app-title-dialog",27),r&2){let m=_();l("title",m.isEdit?"Editar documento":"Crear documento")}}var $e=(()=>{let o=class o{set getGestorArchivo(t){t!=null&&(this.getCategorias(C[t.categoria.nombre=="Documentos"?"categoriasDocumentos":"categoriasTransparencia"].idTipoParamtro),this.idGestorArchivo=t._id,this.formulario.patchValue(t),this.getSubcategorias(t.categoria._id),this.display=!0,this.isEdit=!0)}set getSelectedGestorArchivos(t){this.selectedGestorArchivos=t}constructor(t,e,i,p,c){this.formBuilder=t,this.GestorArchivosRepository=e,this.confirmationService=i,this.manageResponse=p,this.parametroRepository=c,this.getGestorArchivos=new b,this.setIsEdit=new b,this.idGestorArchivo=null,this.display=!1,this.isLoading=!1,this.isLoadingDelete=!1,this.isEdit=!1}ngOnInit(){this.crearFormulario()}crearFormulario(){this.formulario=this.formBuilder.group({documento:["",T.required],categoria:["",T.required],subcategoria:["",T.required],nombre:["",[T.required,T.maxLength(120)]],vigencia:["",[T.required,T.maxLength(12)]]})}onFileChanged(t){t?(this.archivoSubido=t,this.formulario.patchValue({documento:t.name})):(this.archivoSubido=null,this.formulario.patchValue({documento:null}))}showDialog(t){this.display=!this.display,this.tipoGestion=t,this.getCategorias(C[t].idTipoParamtro),this.isEdit&&(this.setIsEdit.emit(),this.isEdit=!1,this.formulario.reset())}guardar(){let t=this.formulario.value;this.isLoading=!0,typeof t.vigencia!="string"&&(t.vigencia=t.vigencia.getFullYear());let e=new FormData;e.append("categoria",JSON.stringify(t.categoria)),e.append("subcategoria",JSON.stringify(t.subcategoria)),e.append("nombre",t.nombre),e.append("vigencia",t.vigencia),this.archivoSubido&&e.append("documento",this.archivoSubido,this.archivoSubido.name),this.isEdit?this.GestorArchivosRepository.updateGestorArchivo(e,this.idGestorArchivo).subscribe({next:i=>{this.isLoading=!1,this.getGestorArchivos.emit(),this.showDialog(this.tipoGestion),this.manageResponse.success(i)},error:i=>{this.manageResponse.error(i),this.isLoading=!1}}):this.GestorArchivosRepository.addGestorArchivos(e).subscribe({next:i=>{this.isLoading=!1,this.uploadOneFileComponent.quitarArchivo(),this.formulario.reset(),this.manageResponse.success(i),this.getGestorArchivos.emit()},error:i=>{this.manageResponse.error(i),this.isLoading=!1}})}eliminarVarios(){this.confirmationService.confirm({message:"\xBFEstas seguro de eliminar los elmentos?",accept:()=>{this.isLoadingDelete=!0;let t=this.selectedGestorArchivos.map(function(e){return{_id:e._id}});this.GestorArchivosRepository.deleteMultiGestorArchivos(t).subscribe({next:e=>{this.manageResponse.success(e),this.isLoadingDelete=!1,this.getGestorArchivos.emit()},error:e=>{this.manageResponse.error(e),this.isLoadingDelete=!1}})},reject:t=>{switch(t){case F.REJECT:this.manageResponse.eventReject;break;case F.CANCEL:this.manageResponse.eventCancel;break}}})}getCategorias(t){this.parametroRepository.getSelectParametrosByTipoParametro(t).subscribe({next:e=>{Array.isArray(e.data)?this.categorias=e.data.map(i=>({_id:i._id,nombre:i.nombre})):console.error("La respuesta no es un array:",e.data)},error:e=>{this.manageResponse.error(e)}})}getSubcategorias(t){let e="subcategoriasTransparencia";this.tipoGestion=="categoriasDocumentos"&&(e="subcategoriasDocumentos"),this.parametroRepository.getSelectParametrosByTipoParametroPadre(C[e].idTipoParamtro,t).subscribe({next:i=>{Array.isArray(i.data)?this.subcategorias=i.data.map(p=>({_id:p._id,nombre:p.nombre})):console.error("La respuesta no es un array:",i.data)},error:i=>{this.manageResponse.error(i)}})}};o.\u0275fac=function(e){return new(e||o)(v(K),v(P),v(z),v(I),v(se))},o.\u0275cmp=S({type:o,selectors:[["app-modal-form-documentos"]],viewQuery:function(e,i){if(e&1&&(me(dt,5),me(ut,5)),e&2){let p;pe(p=ce())&&(i.fileUpload=p.first),pe(p=ce())&&(i.uploadOneFileComponent=p.first)}},inputs:{getGestorArchivo:"getGestorArchivo",getSelectedGestorArchivos:"getSelectedGestorArchivos"},outputs:{getGestorArchivos:"getGestorArchivos",setIsEdit:"setIsEdit"},decls:40,vars:23,consts:[["appUploadOneFile",""],[1,"p-toolbar-group-left"],["label","Crear transparencia","icon","pi pi-plus","styleClass","p-button-success mr-2",3,"click"],["label","Crear documento","icon","pi pi-plus","styleClass","p-button-success mr-2",3,"click"],["icon","pi pi-trash","styleClass","p-button-danger",3,"click","loading","disabled"],[3,"visibleChange","visible"],["pTemplate","header"],[3,"submit","formGroup"],[1,"grid","p-fluid"],[1,"field","col-12","md:col-12"],["titulo","Seleccione el documento a subir","descripcion","El documento debe pesar menos de 200 MB","icon","pi-file","accept",".pdf, .doc, .docx, .xls, .xlsx","maxFileSize","200480000",3,"fileChanged"],[1,"grid","p-fluid","mt-4"],[1,"field","col-6","md:col-6"],["for","float-input-invalid"],["formControlName","categoria","placeholder","Selecione la categoria","optionLabel","nombre",3,"onChange","options","appendTo"],["campo","categoria",3,"formulario"],["formControlName","subcategoria","placeholder","Seleccione la subcategoria","optionLabel","nombre",3,"options","appendTo"],["campo","subcategoria",3,"formulario"],[1,"grid","p-fluid","mt-2"],["formControlName","nombre","placeholder","Digite el nombre del contrato","type","text","pInputText",""],["campo","nombre","length","120",3,"formulario"],["formControlName","vigencia","view","year","dateFormat","yy",3,"appendTo"],["campo","vigencia","length","12",3,"formulario"],[1,"flex","flex-row-reverse","flex-wrap"],["icon","pi pi-check","type","submit","styleClass","p-button-success",3,"loading","label","disabled"],["icon","pi pi-times","label","Cancelar","styleClass","p-button-danger mr-2",3,"click"],["rejectButtonStyleClass","p-button-text","acceptLabel","Si",3,"baseZIndex"],[3,"title"]],template:function(e,i){if(e&1){let p=G();n(0,"p-toolbar")(1,"div",1)(2,"p-button",2),u("click",function(){return h(p),g(i.showDialog("categoriasTransparencia"))}),a(),n(3,"p-button",3),u("click",function(){return h(p),g(i.showDialog("categoriasDocumentos"))}),a(),n(4,"p-button",4),u("click",function(){return h(p),g(i.eliminarVarios())}),a()()(),n(5,"p-dialog",5),O("visibleChange",function(A){return h(p),B(i.display,A)||(i.display=A),g(A)}),y(6,ft,1,1,"ng-template",6),n(7,"form",7),u("submit",function(){return h(p),g(i.guardar())}),n(8,"div",8)(9,"div",9)(10,"app-upload-one-file",10,0),u("fileChanged",function(A){return h(p),g(i.onFileChanged(A))}),a()()(),n(12,"div",11)(13,"div",12)(14,"label",13),f(15,"Categoria"),a(),n(16,"p-dropdown",14),u("onChange",function(A){return h(p),g(i.getSubcategorias(A.value._id))}),a(),d(17,"app-validations-input",15),a(),n(18,"div",12)(19,"label",13),f(20,"Subcategoria"),a(),d(21,"p-dropdown",16)(22,"app-validations-input",17),a()(),n(23,"div",18)(24,"div",9)(25,"label",13),f(26,"Nombre"),a(),d(27,"input",19)(28,"app-validations-input",20),a()(),n(29,"div",8)(30,"div",12)(31,"label",13),f(32,"Vigencia"),a(),d(33,"p-calendar",21)(34,"app-validations-input",22),a()(),d(35,"p-divider"),n(36,"div",23),d(37,"p-button",24),n(38,"p-button",25),u("click",function(){return h(p),g(i.display=!1)}),a()()()(),d(39,"p-confirmDialog",26)}e&2&&(s(4),l("loading",i.isLoadingDelete)("disabled",!i.selectedGestorArchivos||!i.selectedGestorArchivos.length),s(),V(D(21,ht)),k("visible",i.display),s(2),l("formGroup",i.formulario),s(9),l("options",i.categorias)("appendTo","body"),s(),l("formulario",i.formulario),s(4),l("options",i.subcategorias)("appendTo","body"),s(),l("formulario",i.formulario),s(6),l("formulario",i.formulario),s(5),l("appendTo","body"),s(),l("formulario",i.formulario),s(3),l("loading",i.isLoading)("label",i.isLoading?"Guardando...":"Guardar")("disabled",!i.formulario.valid),s(2),V(D(22,gt)),l("baseZIndex",1e4))},dependencies:[J,q,Q,U,H,Z,je,W,X,ke,ee,ae,oe,We,Le,_e,Ze,we]});let r=o;return r})();var vt=()=>({"min-width":"110rem"}),bt=()=>[5,10,20,30];function Ct(r,o){r&1&&(n(0,"div",6)(1,"h5",7),f(2,"Lista de documentos"),a()())}function yt(r,o){if(r&1){let m=G();n(0,"p-dropdown",25),u("onChange",function(e){h(m);let i=_(2);return g(i.getSubcategorias(e.value==null?null:e.value._id))}),a()}if(r&2){let m=_(2);l("options",m.categorias)("showClear",!0)("filter",!0)("appendTo","body")}}function Tt(r,o){if(r&1&&d(0,"p-dropdown",26),r&2){let m=_(2);l("options",m.subcategorias)("showClear",!0)("filter",!0)("appendTo","body")}}function At(r,o){r&1&&d(0,"input",27)}function Gt(r,o){r&1&&d(0,"p-calendar",28),r&2&&l("appendTo","body")}function wt(r,o){if(r&1){let m=G();n(0,"tr")(1,"th",8)(2,"p-tableHeaderCheckbox",9),u("click",function(){h(m);let e=_();return g(e.getSelectGestorArchivos())}),a()(),n(3,"th",10),f(4,"Categoria"),d(5,"p-sortIcon",11),a(),n(6,"th",12),f(7,"Subcategoria"),d(8,"p-sortIcon",13),a(),n(9,"th",14),f(10,"Nombre"),d(11,"p-sortIcon",15),a(),n(12,"th",16),f(13,"Vigencia"),d(14,"p-sortIcon",17),a(),n(15,"th",18),f(16,"Creado"),d(17,"p-sortIcon",19),a(),d(18,"th",20)(19,"th",20),a(),n(20,"tr")(21,"th")(22,"p-button",21),u("click",function(){h(m);let e=_();return g(e.onReloadTable())}),a()(),n(23,"th")(24,"p-columnFilter",22),y(25,yt,1,4,"ng-template",23),a()(),n(26,"th")(27,"p-columnFilter",22),y(28,Tt,1,4,"ng-template",23),a()(),n(29,"th")(30,"p-columnFilter",22),y(31,At,1,0,"ng-template",23),a()(),n(32,"th")(33,"p-columnFilter",22),y(34,Gt,1,1,"ng-template",23),a()(),n(35,"th")(36,"p-button",24),u("click",function(){h(m);let e=_();return g(e.onBuscador())}),a()(),d(37,"th")(38,"th"),a()}r&2&&(s(24),l("showMenu",!1),s(3),l("showMenu",!1),s(3),l("showMenu",!1),s(3),l("showMenu",!1))}function St(r,o){if(r&1){let m=G();n(0,"tr")(1,"td")(2,"p-tableCheckbox",29),u("click",function(){h(m);let e=_();return g(e.getSelectGestorArchivos())}),a()(),n(3,"td"),f(4),a(),n(5,"td"),f(6),a(),n(7,"td"),f(8),a(),n(9,"td"),f(10),a(),n(11,"td"),f(12),L(13,"dateFormat"),a(),n(14,"td")(15,"i",30),L(16,"fileColorFormat"),L(17,"fileFormat"),L(18,"fileDetalleFormat"),u("click",function(){let e=h(m).$implicit,i=_();return g(i.verArchivo(e.documento.path))}),a()(),n(19,"td")(20,"p-button",31),u("click",function(){let e=h(m).$implicit,i=_();return g(i.getIdGestorArchivo(e._id))}),a(),n(21,"p-button",32),u("click",function(){let e=h(m).$implicit,i=_();return g(i.eliminar(e._id))}),a()()()}if(r&2){let m=o.$implicit,t=_();s(2),l("value",m),s(2),x(m.categoria.nombre),s(2),x(m.subcategoria.nombre),s(2),x(m.nombre),s(2),x(m.vigencia),s(2),x(N(13,13,m.createdAt)),s(3),V(N(16,15,m.documento.filename)),de(N(17,17,m.documento.filename)),l("pTooltip",N(18,19,m.documento.filename)),s(5),l("loading",t.isLoading),s(),l("loading",t.isLoading)}}function Et(r,o){if(r&1){let m=G();n(0,"p-paginator",33),u("onPageChange",function(e){h(m);let i=_();return g(i.paginate(e))}),a(),n(1,"div",34),f(2),a()}if(r&2){let m=_();l("rows",m.rows)("totalRecords",m.totalRecords)("rowsPerPageOptions",D(4,bt)),s(2),ue(" En total son ",m.totalRecords," registros. ")}}var et=(()=>{let o=class o{set getLoadingTable(t){this.isLoadingTable=t}constructor(t,e,i,p,c){this.gestorArchivoRepository=t,this.confirmationService=e,this.parametroRepository=i,this.manageResponse=p,this.formBuilder=c,this.gestorArchivos=[],this.setIdGestorArchivo=new b,this.getGestorArchivos=new b,this.setPaginate=new b,this.setSelectedGestorArchivos=new b,this.getBuscadorGestorArchivos=new b,this.selectedGestorArchivos=[],this.globalFilterFields=["fechaGestorArchivo"],this.isLoading=!1,this.isLoadingTable=!1,this.first=0,this.rows=M.pageSize,this.categorias=[]}ngOnInit(){this.getCategorias(C.categoriasTransparencia.idTipoParamtro),this.getCategorias(C.categoriasDocumentos.idTipoParamtro),this.crearFormulario()}crearFormulario(){this.formulario=this.formBuilder.group({categoria:[""],subcategoria:[""],nombre:[""],vigencia:[""]})}paginate(t){this.setPaginate.emit(t)}getIdGestorArchivo(t){this.setIdGestorArchivo.emit(t)}getSelectGestorArchivos(){this.setSelectedGestorArchivos.emit(this.selectedGestorArchivos)}eliminar(t){this.confirmationService.confirm({message:"Estas seguro de eliminar el elemento?",accept:()=>{this.isLoading=!0,this.gestorArchivoRepository.deleteOneGestorArchivo(t).subscribe({next:e=>{this.manageResponse.success(e),this.isLoading=!1,this.getGestorArchivos.emit()},error:e=>{this.manageResponse.error(e),this.isLoading=!1}})},reject:e=>{switch(e){case F.REJECT:this.manageResponse.eventReject();break;case F.CANCEL:this.manageResponse.eventCancel();break}}})}verArchivo(t){window.open(`${M.apiDevWebStorage}${t}`,"_blank").focus()}getCategorias(t){this.parametroRepository.getSelectParametrosByTipoParametro(t).subscribe({next:e=>{this.categorias=this.categorias.concat(e.data),this.categorias=this.categorias.sort((i,p)=>i.nombre.localeCompare(p.nombre))},error:e=>{this.manageResponse.error(e)}})}getSubcategorias(t){t?this.parametroRepository.getSelectParametrosByTipoParametroPadre(C.subcategoriasTransparencia.idTipoParamtro,t).subscribe({next:e=>{this.subcategorias=e.data,this.subcategorias.length===0&&this.parametroRepository.getSelectParametrosByTipoParametroPadre(C.subcategoriasDocumentos.idTipoParamtro,t).subscribe({next:i=>{this.subcategorias=i.data},error:i=>{this.manageResponse.error(i)}})},error:e=>{this.manageResponse.error(e)}}):(this.subcategorias=[],this.formulario.patchValue({subcategoria:""}))}onBuscador(){this.selectedGestorArchivos=[],this.getBuscadorGestorArchivos.emit(this.formulario)}onReloadTable(){this.formulario.reset(),this.subcategorias=[],this.selectedGestorArchivos=[],this.getGestorArchivos.emit()}};o.\u0275fac=function(e){return new(e||o)(v(P),v(z),v(se),v(I),v(K))},o.\u0275cmp=S({type:o,selectors:[["app-table-documentos"]],inputs:{gestorArchivos:"gestorArchivos",totalRecords:"totalRecords",getLoadingTable:"getLoadingTable"},outputs:{setIdGestorArchivo:"setIdGestorArchivo",getGestorArchivos:"getGestorArchivos",setPaginate:"setPaginate",setSelectedGestorArchivos:"setSelectedGestorArchivos",getBuscadorGestorArchivos:"getBuscadorGestorArchivos"},decls:6,vars:10,consts:[[3,"formGroup"],["dataKey","_id",3,"firstChange","selectionChange","value","rows","first","globalFilterFields","showCurrentPageReport","tableStyle","loading","selection"],["pTemplate","caption"],["pTemplate","header"],["pTemplate","body"],["pTemplate","summary"],[1,"flex","align-items-center","justify-content-between"],[1,"m-0"],[2,"width","4rem"],[3,"click"],["pSortableColumn","categoria"],["field","categoria"],["pSortableColumn","subcategoria"],["field","subcategoria"],["pSortableColumn","nombre"],["field","nombre"],["width","230px","pSortableColumn","vigencia"],["field","vigencia"],["width","140px","pSortableColumn","creado"],["field","creado"],["width","126px"],["icon","pi pi-refresh","styleClass","p-button-info","pTooltip","Recargar","tooltipPosition","top",3,"click"],[3,"showMenu"],["pTemplate","filter"],["label","Buscar","icon","pi pi-search","iconPos","right","styleClass","p-button-info",3,"click"],["formControlName","categoria","placeholder","Selecione la categoria","filterPlaceholder","Buscar por subcategoria","emptyMessage","No se encontraton elementos","emptyFilterMessage","No se encontraton elementos","optionLabel","nombre","filterBy","nombre",3,"onChange","options","showClear","filter","appendTo"],["formControlName","subcategoria","placeholder","Selecione la subcategoria","filterPlaceholder","Buscar por subcategoria","emptyMessage","No se encontraton elementos","emptyFilterMessage","No se encontraton elementos","optionLabel","nombre","filterBy","nombre",3,"options","showClear","filter","appendTo"],["formControlName","nombre","placeholder","Buscar por nombre","type","text","pTooltip","Buscar","tooltipPosition","top","pInputText",""],["formControlName","vigencia","view","year","dateFormat","yy",3,"appendTo"],[3,"click","value"],[1,"icon-hover","mt-2",2,"font-size","2rem",3,"click","pTooltip"],["icon","pi pi-pencil","styleClass","p-button-info mr-2","pTooltip","Editar","tooltipPosition","top",3,"click","loading"],["icon","pi pi-trash","styleClass","p-button-danger mr-2 mt-2","pTooltip","Eliminar","tooltipPosition","top",3,"click","loading"],[3,"onPageChange","rows","totalRecords","rowsPerPageOptions"],[1,"flex","align-items-center","justify-content-between","mt-3"]],template:function(e,i){e&1&&(n(0,"form",0)(1,"p-table",1),O("firstChange",function(c){return B(i.first,c)||(i.first=c),c})("selectionChange",function(c){return B(i.selectedGestorArchivos,c)||(i.selectedGestorArchivos=c),c}),y(2,Ct,3,0,"ng-template",2)(3,wt,39,4,"ng-template",3)(4,St,22,21,"ng-template",4)(5,Et,3,5,"ng-template",5),a()()),e&2&&(l("formGroup",i.formulario),s(),l("value",i.gestorArchivos)("rows",i.rows),k("first",i.first),l("globalFilterFields",i.globalFilterFields)("showCurrentPageReport",!0)("tableStyle",D(9,vt))("loading",i.isLoadingTable),k("selection",i.selectedGestorArchivos))},dependencies:[De,W,Re,Fe,Me,Ie,Pe,ee,X,Ee,ae,J,q,Q,U,ge,oe,H,Z,be,ye,Te,Ae]});let r=o;return r})();var tt=(()=>{let o=class o{constructor(t,e){this.gestorArchivoRepository=t,this.manageResponse=e,this.isEdit=!1,this.page=M.page,this.pageSize=M.pageSize,this.loadingTable=!1}ngOnInit(){this.getGestorArchivos(),this.inizialize()}inizialize(){this.items=[{label:"Gesti\xF3n"},{label:"Transparencia"}],this.home={icon:"pi pi-home",routerLink:"/"}}getGestorArchivos(){this.loadingTable=!0,this.gestorArchivoRepository.getGestorArchivos(this.page,this.pageSize).subscribe({next:t=>{this.gestorArchivos=t.data,this.totalRecords=t.totalRecords,this.loadingTable=!1},error:t=>{this.manageResponse.error(t),this.loadingTable=!1}})}getIdGestorArchivo(t){this.isEdit=!0,this.getGestorArchivo(t)}getSelectedGestorArchivos(t){this.selectedGestorArchivos=t}getGestorArchivo(t){this.gestorArchivoRepository.getGestorArchivo(t).subscribe({next:e=>{this.gestorArchivo=e.data},error:e=>{this.manageResponse.error(e)}})}getBuscadorGestorArchivos(t){this.loadingTable=!0,this.gestorArchivoRepository.getGestorArchivos(this.page,this.pageSize,!1,t.value).subscribe({next:e=>{this.gestorArchivos=e.data,this.totalRecords=e.totalRecords,this.loadingTable=!1},error:e=>{this.manageResponse.error(e),this.loadingTable=!1}})}paginate(t){this.page=t.page+1,this.pageSize=t.rows,this.getGestorArchivos()}};o.\u0275fac=function(e){return new(e||o)(v(P),v(I))},o.\u0275cmp=S({type:o,selectors:[["app-gestor-archivos"]],decls:6,vars:7,consts:[[3,"model","home"],[1,"card","mt-5","p-3"],[3,"getGestorArchivos","setIsEdit","getGestorArchivo","getSelectedGestorArchivos"],[1,"mt-3"],[3,"setIdGestorArchivo","setSelectedGestorArchivos","getGestorArchivos","getBuscadorGestorArchivos","setPaginate","gestorArchivos","totalRecords","getLoadingTable"]],template:function(e,i){e&1&&(d(0,"p-toast")(1,"p-breadcrumb",0),n(2,"div",1)(3,"app-modal-form-documentos",2),u("getGestorArchivos",function(){return i.getGestorArchivos()})("setIsEdit",function(){return i.isEdit=!1}),a(),n(4,"div",3)(5,"app-table-documentos",4),u("setIdGestorArchivo",function(c){return i.getIdGestorArchivo(c)})("setSelectedGestorArchivos",function(c){return i.getSelectedGestorArchivos(c)})("getGestorArchivos",function(){return i.getGestorArchivos()})("getBuscadorGestorArchivos",function(c){return i.getBuscadorGestorArchivos(c)})("setPaginate",function(c){return i.paginate(c)}),a()()()),e&2&&(s(),l("model",i.items)("home",i.home),s(2),l("getGestorArchivo",i.gestorArchivo)("getSelectedGestorArchivos",i.selectedGestorArchivos),s(2),l("gestorArchivos",i.gestorArchivos)("totalRecords",i.totalRecords)("getLoadingTable",i.loadingTable))},dependencies:[qe,Ue,$e,et]});let r=o;return r})();var Dt=[{path:"",component:tt}],it=he.forChild(Dt);var ot=(()=>{let o=class o{};o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=E({type:o}),o.\u0275inj=w({imports:[R,Y,Oe,$,Be,te,ne,re,Se,ze,le,Ne,ve,Ke,ie]});let r=o;return r})();var rt=(()=>{let o=class o{};o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=E({type:o}),o.\u0275inj=w({imports:[R,Ve,te,$,le,xe,fe,Ge,ne,re,Y]});let r=o;return r})();var to=(()=>{let o=class o{};o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=E({type:o}),o.\u0275inj=w({imports:[R,it,Ce,Qe,He,Je,ot,rt,ie]});let r=o;return r})();export{to as GestorArchivosModule};