mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
1 line
252 KiB
JavaScript
1 line
252 KiB
JavaScript
(self.webpackChunkgabinete_digital=self.webpackChunkgabinete_digital||[]).push([[4528,1491,910],{40617:function(t,e,n){"use strict";n.d(e,{K:function(){return s}});var o=n(37716),i=n(28621),a=n(96529);let s=(()=>{class t{constructor(t,e){this.processes=t,this.p=e}arquivar(t,e,n){return this.processes.CompleteTask({serialNumber:n,action:"Arquivo",ActionTypeId:95,dataFields:{ReviewUserComment:t},AttachmentList:e})}executado(t,e,n){return this.processes.CompleteTask({serialNumber:n,action:"Conhecimento",ActionTypeId:104,dataFields:{ReviewUserComment:t},AttachmentList:e})}solicitarParecer({note:t="",documents:e=[],serialnumber:n}){return this.processes.CompleteTask({serialNumber:n,action:"Conhecimento",ActionTypeId:92,dataFields:{ReviewUserComment:t},AttachmentList:e})}EfectuarDespacho({note:t="",documents:e=[],serialnumber:n}){return this.processes.CompleteTask({serialNumber:n,action:"Conhecimento",ActionTypeId:94,dataFields:{ReviewUserComment:t},AttachmentList:e})}rexecucao({note:t,documents:e,serialnumber:n}){return this.processes.CompleteTask({serialNumber:n,action:"Reexecu\xe7\xe3o",ActionTypeId:100000010,dataFields:{ReviewUserComment:t},AttachmentList:e})}CompleteTask({serialNumber:t}){return this.processes.CompleteTask({serialNumber:t,action:"Despacho",ActionTypeId:94,dataFields:{ReviewUserComment:""},AttachmentList:null})}sendExpedienteToPending(t){return this.processes.SetTaskToPending(t)}createDespacho(t){return this.p.userRole(["PR"])?this.processes.postDespatchoPr(t):this.processes.postDespatcho(t)}createParecer(t){return this.p.userRole(["PR"])?this.processes.postParecerPr(t):this.processes.postParecer(t)}}return t.\u0275fac=function(e){return new(e||t)(o.LFG(i.$),o.LFG(a.$))},t.\u0275prov=o.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})()},320:function(t,e,n){"use strict";n.d(e,{C:function(){return g}});var o=n(64762),i=n(4528),a=n(37716),s=n(35957),c=n(3679),r=n(38583);function d(t,e){1&t&&(a.TgZ(0,"ion-label"),a._uU(1,"Documentos anexados"),a.qZA())}function l(t,e){if(1&t){const t=a.EpF();a.TgZ(0,"div",15),a.TgZ(1,"ion-label",16),a.NdJ("click",function(){return a.CHM(t),a.oxw().getDoc()}),a.TgZ(2,"button",17),a.TgZ(3,"div",18),a._UZ(4,"ion-icon",19),a.qZA(),a.TgZ(5,"div",20),a.TgZ(6,"ion-label"),a._uU(7,"Anexar Documentos"),a.qZA(),a.qZA(),a.qZA(),a.qZA(),a.YNc(8,d,2,0,"ion-label",21),a.qZA()}if(2&t){const t=a.oxw();a.xp6(8),a.Q6J("ngIf",t.documents.length>0)}}function p(t,e){if(1&t){const t=a.EpF();a.TgZ(0,"ion-list"),a.TgZ(1,"ion-item"),a.TgZ(2,"ion-label"),a.TgZ(3,"p",22),a.TgZ(4,"span",23),a._uU(5),a.qZA(),a.TgZ(6,"span",24),a._uU(7),a.qZA(),a.TgZ(8,"span",25),a.NdJ("click",function(){const e=a.CHM(t).index;return a.oxw().removeAttachment(e)}),a._UZ(9,"ion-icon",26),a.qZA(),a.qZA(),a.TgZ(10,"p"),a.TgZ(11,"span",27),a._uU(12),a.qZA(),a.TgZ(13,"span",28),a._uU(14),a.ALo(15,"date"),a.qZA(),a.qZA(),a.qZA(),a.qZA(),a.qZA()}if(2&t){const t=e.$implicit;a.xp6(5),a.Oqu(t.Assunto),a.xp6(2),a.Oqu(t.appName),a.xp6(5),a.Oqu(t.EntidadeOrganicaNome),a.xp6(2),a.hij(" ",a.xi3(15,4,t.Data,"dd-MM-yyyy HH:mm")," ")}}let g=(()=>{class t{constructor(t,e,n){this.modalController=t,this.animationController=e,this.navParams=n,this.note="",this.documents=[],this.hideThisFeature=!0,this.note="",this.hideThisFeature=this.navParams.get("showAttachmentBtn")}ngOnInit(){console.log(this.navParams),console.log(this.hideThisFeature)}close(){this.modalController.dismiss("")}save(){this.modalController.dismiss({note:this.note,documents:this.documents})}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:i.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>{t&&this.documents.push(t.data.selected)})})}removeAttachment(t){this.documents=this.documents.filter((e,n)=>t!=n)}}return t.\u0275fac=function(e){return new(e||t)(a.Y36(s.IN),a.Y36(s.vB),a.Y36(s.X1))},t.\u0275cmp=a.Xpm({type:t,selectors:[["app-add-note"]],decls:20,vars:4,consts:[[1,"ion-no-border","width-100"],[1,"header-content","pb-20","width-100"],[1,"header-title","width-100"],[1,"ion-input-class-no-height"],["placeholder","Detalhes","rows","6","cols","20",3,"ngModel","ngModelChange"],["class","ion-item-container-no-border",4,"ngIf"],[1,"content","width-100","overflow-y-auto","height-100"],[1,"list"],[4,"ngFor","ngForOf"],["hidden","","lines","none"],["rows","4","cols","20","placeholder","Adicionar um coment\xe1rio para execu\xe7\xe3o...",3,"ngModel","ngModelChange"],[1,"ion-no-border"],[1,"buttons","width-100"],["shape","round",1,"btn-cancel","cursor-pointer",3,"click"],["shape","round",1,"btn-ok","cursor-pointer",3,"click"],[1,"ion-item-container-no-border"],[1,"attach-wrapper","d-flex","align-center",3,"click"],[1,"btn-no-color"],[1,"attach-icon"],["src","assets/images/icons-attach-doc.svg"],[1,"attach-document","pl-10"],[4,"ngIf"],[1,"d-flex","ion-justify-content-between"],[1,"attach-title-item"],[1,"app-name"],[1,"close-button","text-black","cursor-pointer",3,"click"],["src","assets/images/icons-delete-25.svg",1,"font-20"],[1,"span-left"],[1,"span-right"]],template:function(t,e){1&t&&(a.TgZ(0,"ion-header",0),a.TgZ(1,"div",1),a.TgZ(2,"div",2),a.TgZ(3,"label"),a._uU(4,"Adicionar coment\xe1rio"),a.qZA(),a.qZA(),a.qZA(),a.TgZ(5,"div",3),a.TgZ(6,"ion-textarea",4),a.NdJ("ngModelChange",function(t){return e.note=t}),a.qZA(),a.qZA(),a.YNc(7,l,9,1,"div",5),a.qZA(),a.TgZ(8,"ion-content"),a.TgZ(9,"div",6),a.TgZ(10,"div",7),a.YNc(11,p,16,7,"ion-list",8),a.qZA(),a.TgZ(12,"ion-item",9),a.TgZ(13,"ion-textarea",10),a.NdJ("ngModelChange",function(t){return e.note=t}),a.qZA(),a.qZA(),a.qZA(),a.qZA(),a.TgZ(14,"ion-footer",11),a.TgZ(15,"div",12),a.TgZ(16,"button",13),a.NdJ("click",function(){return e.close()}),a._uU(17,"Cancelar"),a.qZA(),a.TgZ(18,"button",14),a.NdJ("click",function(){return e.save()}),a._uU(19,"Gravar"),a.qZA(),a.qZA(),a.qZA()),2&t&&(a.xp6(6),a.Q6J("ngModel",e.note),a.xp6(1),a.Q6J("ngIf",e.hideThisFeature),a.xp6(4),a.Q6J("ngForOf",e.documents),a.xp6(2),a.Q6J("ngModel",e.note))},directives:[s.Gu,s.g2,s.j9,c.JJ,c.On,r.O5,s.W2,r.sg,s.Ie,s.fr,s.Q$,s.gu,s.q_],pipes:[r.uU],styles:[".header-content[_ngcontent-%COMP%]{width:100%!important;padding:30px 20px 0!important;margin-bottom:20px!important;float:left}.header-title[_ngcontent-%COMP%]{font-family:Roboto;font-size:25px;padding:0;color:#000;float:left}.ion-item-container-no-border[_ngcontent-%COMP%]{margin:5px 20px 0!important;padding:0!important;overflow:auto}.list[_ngcontent-%COMP%]{overflow:auto!important;margin:5px 20px 0!important}.ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto}.ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}ion-select[_ngcontent-%COMP%]{padding-left:5px;margin-left:0}.ion-input-class[_ngcontent-%COMP%]{width:calc(100% - 45px);height:45px;border:1px solid #ebebeb;border-radius:5px;padding-left:5px;padding-right:10px;float:left}.list-people[_ngcontent-%COMP%]{width:256px;float:left}.add-people[_ngcontent-%COMP%]{width:45px;float:right;overflow:auto;font-size:25px;padding:10px}.list-people-title[_ngcontent-%COMP%]{color:#797979}.attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.container-footer[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.button-cancel[_ngcontent-%COMP%]{--background:#e0e9ee;--color:#061b52}.button-cancel[_ngcontent-%COMP%], .button-save[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;margin:10px}.button-save[_ngcontent-%COMP%]{--background:#42b9fe;--color:#fff}.text-input[_ngcontent-%COMP%]{width:100%;border:1px solid #ebebeb;margin:0 15px 15px 0;padding:0!important;border-radius:5px}.error[_ngcontent-%COMP%]{font-size:12px;font-weight:700;padding-bottom:20px}.error[_ngcontent-%COMP%], .span-color[_ngcontent-%COMP%]{color:red}.buttons[_ngcontent-%COMP%]{display:flex;width:100%!important;justify-content:space-between;padding:15px 0;overflow:auto}.ion-input-class-no-height[_ngcontent-%COMP%]{border:1px solid #ebebeb;border-radius:5px;overflow:auto;margin:5px 20px 0!important}"]}),t})()},33289:function(t,e,n){"use strict";n.d(e,{j:function(){return y}});var o=n(64762),i=n(32379),a=n(84943),s=n(18057),c=n(37716),r=n(35957),d=n(25970),l=n(28621),p=n(53760),g=n(96529),u=n(38583),h=n(23890);function m(t,e){if(1&t&&(c.TgZ(0,"span",24),c._uU(1),c.qZA()),2&t){const t=c.oxw(2);c.xp6(1),c.Oqu(t.LoadedDocument.Nature)}}function f(t,e){1&t&&(c.TgZ(0,"h5"),c._uU(1,"Intervenientes"),c.qZA())}function v(t,e){1&t&&(c.TgZ(0,"h5"),c._uU(1,"Remetente"),c.qZA())}function Z(t,e){1&t&&(c.TgZ(0,"h5"),c._uU(1,"Status"),c.qZA())}function x(t,e){if(1&t&&(c.TgZ(0,"ion-item",21),c.TgZ(1,"p"),c._uU(2),c.qZA(),c.qZA()),2&t){const t=c.oxw(2);c.xp6(2),c.Oqu(t.LoadedDocument.Status)}}function C(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"ion-label",27),c.NdJ("click",function(){return c.CHM(t),c.oxw(3).viewDocument()}),c.TgZ(1,"div",28),c._uU(2),c.qZA(),c.TgZ(3,"div",29),c.TgZ(4,"span",30),c._uU(5),c.qZA(),c.TgZ(6,"span",31),c._uU(7),c.ALo(8,"date"),c.qZA(),c.qZA(),c.qZA()}if(2&t){const t=c.oxw(3);c.xp6(2),c.hij(" ",t.LoadedDocument.Assunto," "),c.xp6(3),c.Oqu(t.LoadedDocument.Sender),c.xp6(2),c.Oqu(c.xi3(8,3,t.LoadedDocument.DocDate,"dd-MM-yyyy HH:mm"))}}function M(t,e){if(1&t&&(c.TgZ(0,"div",29),c.TgZ(1,"span",30),c._uU(2),c.qZA(),c.TgZ(3,"span",31),c._uU(4),c.ALo(5,"date"),c.qZA(),c.qZA()),2&t){const t=c.oxw().$implicit;c.xp6(2),c.Oqu(t.Sender),c.xp6(2),c.Oqu(c.xi3(5,2,t.DocDate,"dd-MM-yyyy HH:mm"))}}function b(t,e){if(1&t&&(c.TgZ(0,"div"),c.TgZ(1,"div",28),c._uU(2),c.qZA(),c.YNc(3,M,6,5,"div",33),c.qZA()),2&t){const t=e.$implicit;c.xp6(2),c.hij(" ",t.Assunto," "),c.xp6(1),c.Q6J("ngIf",t.Sender)}}function P(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"ion-label",27),c.NdJ("click",function(){return c.CHM(t),c.oxw(3).viewDocument()}),c.YNc(1,b,4,2,"div",32),c.qZA()}if(2&t){const t=c.oxw(3);c.xp6(1),c.Q6J("ngForOf",t.LoadedDocument.Documents)}}function A(t,e){if(1&t&&(c.TgZ(0,"div",25),c.TgZ(1,"ion-list"),c.TgZ(2,"h5"),c._uU(3,"Documentos Anexados"),c.qZA(),c.TgZ(4,"ion-item",21),c.YNc(5,C,9,6,"ion-label",26),c.YNc(6,P,2,1,"ion-label",26),c.qZA(),c.qZA(),c.qZA()),2&t){const t=c.oxw(2);c.xp6(5),c.Q6J("ngIf",8==t.LoadedDocument.ApplicationId||8==t.LoadedDocument.ApplicationID),c.xp6(1),c.Q6J("ngIf",361==t.LoadedDocument.ApplicationId||361==t.LoadedDocument.ApplicationID)}}function w(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"div",7),c.TgZ(1,"div",8),c.TgZ(2,"div",9),c._UZ(3,"app-btn-modal-dismiss"),c.TgZ(4,"div",10),c.TgZ(5,"ion-label",11),c._uU(6),c.qZA(),c.qZA(),c.TgZ(7,"div",12),c.NdJ("click",function(){return c.CHM(t),c.oxw().openOptions()}),c._UZ(8,"ion-icon",13),c.qZA(),c.qZA(),c.qZA(),c.TgZ(9,"div",14),c.TgZ(10,"div",15),c.TgZ(11,"ion-label"),c.TgZ(12,"p"),c.TgZ(13,"span",16),c._uU(14),c.qZA(),c.YNc(15,m,2,1,"span",17),c.qZA(),c.qZA(),c.qZA(),c.qZA(),c._UZ(16,"div",18),c.TgZ(17,"div",19),c.YNc(18,f,2,0,"h5",20),c.YNc(19,v,2,0,"h5",20),c.TgZ(20,"ion-item",21),c.TgZ(21,"ion-label"),c.TgZ(22,"div"),c.TgZ(23,"p"),c._uU(24),c.qZA(),c.qZA(),c.qZA(),c.qZA(),c.YNc(25,Z,2,0,"h5",20),c.YNc(26,x,3,1,"ion-item",22),c.qZA(),c.YNc(27,A,7,2,"div",23),c.qZA()}if(2&t){const t=c.oxw();c.xp6(6),c.Oqu(t.LoadedDocument.Assunto),c.xp6(8),c.Oqu(t.customDate),c.xp6(1),c.Q6J("ngIf",t.LoadedDocument.Nature),c.xp6(3),c.Q6J("ngIf",361==t.LoadedDocument.ApplicationId||361==t.LoadedDocument.ApplicationID),c.xp6(1),c.Q6J("ngIf",8==t.LoadedDocument.ApplicationId||8==t.LoadedDocument.ApplicationID),c.xp6(5),c.Oqu(t.LoadedDocument.Interveners||t.LoadedDocument.Sender),c.xp6(1),c.Q6J("ngIf",361==t.LoadedDocument.ApplicationId||361==t.LoadedDocument.ApplicationID),c.xp6(1),c.Q6J("ngIf",361==t.LoadedDocument.ApplicationId||361==t.LoadedDocument.ApplicationID),c.xp6(1),c.Q6J("ngIf",t.LoadedDocument)}}function T(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"button",40),c.NdJ("click",function(){return c.CHM(t),c.oxw(2).openExpedientActionsModal("0")}),c._uU(1,"Efetuar Despacho"),c.qZA()}}function _(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"button",40),c.NdJ("click",function(){return c.CHM(t),c.oxw(2).openExpedientActionsModal("0")}),c._uU(1,"Efetuar Despacho"),c.qZA()}}function O(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"button",38),c.NdJ("click",function(){return c.CHM(t),c.oxw(2).openExpedientActionsModal("2")}),c._uU(1,"Pedido de Deferimento"),c.qZA()}}const q=function(){return["PR"]};function k(t,e){if(1&t){const t=c.EpF();c.TgZ(0,"div",34),c.TgZ(1,"div",35),c.YNc(2,T,2,0,"button",36),c.YNc(3,_,2,0,"button",36),c._UZ(4,"div",37),c.TgZ(5,"button",38),c.NdJ("click",function(){return c.CHM(t),c.oxw().openExpedientActionsModal("1")}),c._uU(6,"Solicitar Parecer"),c.qZA(),c.YNc(7,O,2,0,"button",39),c.TgZ(8,"button",38),c.NdJ("click",function(){return c.CHM(t),c.oxw().openBookMeetingModal()}),c._uU(9,"Marcar Reuni\xe3o"),c.qZA(),c.qZA(),c.qZA()}if(2&t){const t=c.oxw();c.xp6(2),c.Q6J("ngIf",t.p.userRole(c.DdM(3,q))),c.xp6(1),c.Q6J("ngIf",!t.p.userRole(c.DdM(4,q))),c.xp6(4),c.Q6J("ngIf",!t.p.userRole(c.DdM(5,q)))}}let y=(()=>{class t{constructor(t,e,n,o,i,a,s,c){this.navParams=t,this.modalController=e,this.alertService=n,this.processes=o,this.menu=i,this.iab=a,this.p=s,this.popoverController=c,this.months=["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],this.days=["Domingo","Segunda-feira","Ter\xe7a-feira","Quarta-feira","Quinta-feira","Sexta-feira","S\xe1bado"],this.LoadedDocument=null,this.task={},this.docId=this.navParams.get("docId"),this.applicationId=this.navParams.get("applicationId")}ngOnInit(){this.LoadDocumentDetails()}LoadDocumentDetails(){return(0,o.mG)(this,void 0,void 0,function*(){this.processes.GetDocumentDetails(this.docId,this.applicationId).subscribe(t=>{this.LoadedDocument=t,this.LoadedDocument.Subject=this.LoadedDocument.Assunto;let e,n=new Date(this.LoadedDocument.DateDispatch||this.LoadedDocument.DocDate);console.log(t),this.customDate=this.days[n.getDay()]+", "+n.getDate()+" de "+this.months[n.getMonth()];let o=this.LoadedDocument,i=this.LoadedDocument;361==this.LoadedDocument.ApplicationID||361==this.LoadedDocument.ApplicationId?e={serialNumber:i.DispatchNumber,taskStartDate:i.DateDispatch,isEvent:!0,workflowInstanceDataFields:{FsId:i.ApplicationID||i.ApplicationId,FolderID:i.FolderId||i.FolderID||i.folderId,DocId:i.DispatchNumber,Subject:i.Assunto}}:8==o.ApplicationID||8==o.ApplicationId?e={serialNumber:o.DocId,taskStartDate:o.DocDate,isEvent:!0,workflowInstanceDataFields:{FsId:o.ApplicationID||o.ApplicationId,FolderID:null,DocId:o.DocId||o.DocID,Subject:o.Assunto}}:console.log("unexpected ApplicationID"),this.task=e,console.log("this.task = task",this.task)})})}viewDocument(){this.processes.GetDocumentUrl(this.docId,"8").subscribe(t=>{console.log(t);const e=t.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");this.iab.create(e,"_blank").show()})}openMenu(){this.menu.open(),this.modalController.dismiss()}close(){this.modalController.dismiss()}notImplemented(){this.alertService.presentAlert("Funcionalidade em desenvolvimento")}openExpedientActionsModal(t){return(0,o.mG)(this,void 0,void 0,function*(){let e;e=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const n=yield this.modalController.create({component:i.F,componentProps:{taskAction:t,task:this.task,seachDocuments:this.LoadedDocument,aplicationId:this.LoadedDocument.ApplicationId||this.LoadedDocument.ApplicationID},cssClass:e});yield n.present(),n.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){}))})}openBookMeetingModal(){return(0,o.mG)(this,void 0,void 0,function*(){let t;t=window.innerWidth<=800?"book-meeting-modal modal modal-desktop":"modal modal-desktop showAsideOptions";const e=yield this.modalController.create({component:a.l,componentProps:{task:this.task,document:this.LoadedDocument},cssClass:t,backdropDismiss:!1});yield e.present(),e.onDidDismiss()})}openOptions(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.popoverController.create({component:s.S,cssClass:"exp-options",componentProps:{task:this.task,LoadedDocument:this.LoadedDocument},translucent:!0});yield t.present(),t.onDidDismiss().then(t=>{"openBookMeetingModal"==t.data.component?this.openBookMeetingModal():"openExpedientActionsModal"==t.data.component?this.openExpedientActionsModal(t.data.taskAction):(console.log(t.data),console.log("component not found"))})})}}return t.\u0275fac=function(e){return new(e||t)(c.Y36(r.X1),c.Y36(r.IN),c.Y36(d.c),c.Y36(l.$),c.Y36(r._q),c.Y36(p.i),c.Y36(g.$),c.Y36(r.Dh))},t.\u0275cmp=c.Xpm({type:t,selectors:[["app-document-detail"]],decls:29,vars:2,consts:[[1,"main-content","d-flex","height-100"],["class","content d-flex flex-column",4,"ngIf"],["class","aside-right flex-column height-100",4,"ngIf"],["hidden",""],["animated","",2,"width","50%"],["animated","",2,"width","80%"],["color","medium","shape","round","expand","block"],[1,"content","d-flex","flex-column"],[1,"main-header"],[1,"title-content","width-100","d-flex","align-center"],[1,"middle","flex-grow-1"],[1,"title"],[1,"div-icon",3,"click"],["src","assets/images/icons-menu.svg",1,"font-25","cursor-pointer"],[1,"upper-content"],[1,"content-details"],[1,"date"],["class","label",4,"ngIf"],[1,"line"],[1,"middle-content"],[4,"ngIf"],[1,"ion-no-margin","ion-no-padding"],["class","ion-no-margin ion-no-padding",4,"ngIf"],["class","bottom-content width-100",4,"ngIf"],[1,"label"],[1,"bottom-content","width-100"],[3,"click",4,"ngIf"],[3,"click"],[1,"attach-title-item"],[1,"d-flex","justify-between",2,"justify-content","space-between"],[1,"span-left"],[1,"span-right"],[4,"ngFor","ngForOf"],["class","d-flex justify-between","style","justify-content: space-between",4,"ngIf"],[1,"aside-right","flex-column","height-100"],[1,"buttons"],["class","btn-ok","shape","round",3,"click",4,"ngIf"],[1,"solid"],["shape","round",1,"btn-cancel",3,"click"],["class","btn-cancel","shape","round",3,"click",4,"ngIf"],["shape","round",1,"btn-ok",3,"click"]],template:function(t,e){1&t&&(c.TgZ(0,"ion-content"),c.TgZ(1,"div",0),c.YNc(2,w,28,9,"div",1),c.YNc(3,k,10,6,"div",2),c.TgZ(4,"div",3),c.TgZ(5,"ion-list"),c.TgZ(6,"ion-list-header"),c.TgZ(7,"ion-label"),c._UZ(8,"ion-skeleton-text",4),c.qZA(),c.qZA(),c.TgZ(9,"ion-item"),c.TgZ(10,"ion-label"),c.TgZ(11,"h3"),c._UZ(12,"ion-skeleton-text",4),c.qZA(),c.TgZ(13,"p"),c._UZ(14,"ion-skeleton-text",5),c.qZA(),c.qZA(),c.qZA(),c.TgZ(15,"ion-item"),c.TgZ(16,"ion-label"),c.TgZ(17,"h3"),c._UZ(18,"ion-skeleton-text",4),c.qZA(),c.TgZ(19,"p"),c._UZ(20,"ion-skeleton-text",5),c.qZA(),c.qZA(),c.qZA(),c.TgZ(21,"ion-item"),c.TgZ(22,"ion-label"),c.TgZ(23,"h3"),c._UZ(24,"ion-skeleton-text",4),c.qZA(),c.TgZ(25,"p"),c._UZ(26,"ion-skeleton-text",5),c.qZA(),c.qZA(),c.qZA(),c.TgZ(27,"ion-button",6),c._UZ(28,"ion-skeleton-text",4),c.qZA(),c.qZA(),c.qZA(),c.qZA(),c.qZA()),2&t&&(c.xp6(2),c.Q6J("ngIf",e.LoadedDocument),c.xp6(1),c.Q6J("ngIf",e.LoadedDocument))},directives:[r.W2,u.O5,r.q_,r.yh,r.Q$,r.CK,r.Ie,r.YG,h.E,r.gu,u.sg],pipes:[u.uU],styles:[".content[_ngcontent-%COMP%]{padding:30px 20px 0!important;margin:0;float:left}.color-red[_ngcontent-%COMP%]{font-weight:500;color:#d30a0a!important}.btn-size[_ngcontent-%COMP%]{font-size:18px!important}.main-header[_ngcontent-%COMP%]{font-family:Roboto;border-top-left-radius:25px;border-top-right-radius:25px;background-color:#fff;overflow:auto;color:#000;transform:translate3d(0,1px,0)}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%]{width:360px;margin:0 auto;overflow:auto;padding:0!important;background:#fff}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%] .middle[_ngcontent-%COMP%]{padding:0!important;float:left;width:280px;margin:2.5px 0 0 5px;display:flex;align-items:center}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%] .right[_ngcontent-%COMP%]{padding:0!important;float:right;font-size:25px;color:#0782c9;margin:5px 0 0}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%]{width:310px;overflow:auto;margin:0 auto}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%] .header-bottom-icon[_ngcontent-%COMP%]{width:30px;font-size:25px;float:left;padding:2px}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%] .header-bottom-contacts[_ngcontent-%COMP%]{width:275px;font-size:15px;color:#797979;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;float:left;padding:5px;margin:1px}.main-header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:25px;overflow:auto;float:left;padding-top:4px;padding-left:5px}.main-header[_ngcontent-%COMP%] .div-icon[_ngcontent-%COMP%]{width:40px;float:right;font-size:35px;overflow:auto;padding:1px}ion-item-group[_ngcontent-%COMP%]{margin:15px}ion-button[_ngcontent-%COMP%]{display:block;width:80%;margin:20px auto}.upper-content[_ngcontent-%COMP%]{font-family:Roboto;margin-left:41px;overflow:auto;font-size:18px}.upper-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{border-radius:20px;background:#ffb703;float:right;padding:5px 13.5px;color:#fff}.upper-content[_ngcontent-%COMP%] .button-calendar-type[_ngcontent-%COMP%] ion-button[_ngcontent-%COMP%]{height:25px}.upper-content[_ngcontent-%COMP%] .content-details[_ngcontent-%COMP%]{font-size:17px}.upper-content[_ngcontent-%COMP%] .content-details[_ngcontent-%COMP%] .date[_ngcontent-%COMP%]{color:#797979}.middle-conten[_ngcontent-%COMP%] .middle-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:16px}.bottom-content[_ngcontent-%COMP%]{margin:0 auto}.bottom-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:16px;margin:0 0 0 10px}.bottom-content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.bottom-content[_ngcontent-%COMP%] .attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.bottom-content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{font-size:18px;width:100%;color:#0d89d1;padding-bottom:5px}.bottom-content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:14px;color:#666!important}.bottom-content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:14px;color:#666!important}.aside-right[_ngcontent-%COMP%]{padding:30px 20px 0!important}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;margin-bottom:20px}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%] .arrow-right-icon[_ngcontent-%COMP%]{width:37px;float:right;font-size:35px;overflow:hidden}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:space-between}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-cancel[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-delete[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-ok[_ngcontent-%COMP%]{height:auto!important;font-size:16px!important;font-weight:600!important;width:100%!important;margin-bottom:10px!important;padding:15px!important}.aside-right[_ngcontent-%COMP%] .solid[_ngcontent-%COMP%]{display:block;width:90%;border-top:1px solid #ebebeb;margin:0 auto 10px!important}@media only screen and (max-width: 800px){.content[_ngcontent-%COMP%]{width:100%!important}.aside-right[_ngcontent-%COMP%]{display:none}}@media only screen and (min-width: 801px){.div-icon[_ngcontent-%COMP%]{display:none}.content[_ngcontent-%COMP%]{width:65%;border-right:1px solid #d8d8d8}.aside-right[_ngcontent-%COMP%]{width:35%}}@media only screen and (min-width: 1024px){.content[_ngcontent-%COMP%]{width:70%}.aside-right[_ngcontent-%COMP%]{width:30%}}@media only screen and (min-width: 1140px){.content[_ngcontent-%COMP%]{width:75%}.aside-right[_ngcontent-%COMP%]{width:25%}}"]}),t})()},84943:function(t,e,n){"use strict";n.d(e,{l:function(){return H}});var o=n(64762),i=n(18119),a=n(4528),s=n(55199),c=n(3679),r=n(16738),d=n(25653),l=n(84393),p=n(37716),g=n(35957),u=n(39895),h=n(28621),m=n(37556),f=n(84465);let v=(()=>{class t{constructor(t){this.processes=t}setUpMeeting(t){return this.processes.documentSetUpMeeting(t)}}return t.\u0275fac=function(e){return new(e||t)(p.LFG(h.$))},t.\u0275prov=p.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();var Z=n(80106),x=n(38583),C=n(98295),M=n(67441),b=n(72458),P=n(49983),A=n(43220),w=n(1491),T=n(17352);const _=["picker"],O=["fim"],q=["inicio"],k=["picker1"];function y(t,e){1&t&&(p.TgZ(0,"div"),p._uU(1," Campo obrigat\xf3rio. "),p.qZA())}function D(t,e){1&t&&(p.TgZ(0,"div"),p._uU(1," O campo deve ter pelo menos 4 caracteres. "),p.qZA())}function I(t,e){if(1&t&&(p.TgZ(0,"div",70),p.YNc(1,y,2,0,"div",7),p.YNc(2,D,2,0,"div",7),p.qZA()),2&t){const t=p.oxw(2);p.xp6(1),p.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.required),p.xp6(1),p.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.minlength)}}function S(t,e){if(1&t&&(p.TgZ(0,"div"),p.YNc(1,I,3,2,"div",69),p.qZA()),2&t){const t=p.oxw();p.xp6(1),p.Q6J("ngIf",t.Form.get("Subject").invalid)}}function N(t,e){if(1&t&&(p.TgZ(0,"mat-option",71),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.s9C("value",t.Code),p.xp6(1),p.hij(" ",t.Description," ")}}function F(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"div",8),p.TgZ(1,"div",40),p.TgZ(2,"div",10),p._UZ(3,"ion-icon",16),p.qZA(),p.TgZ(4,"div",35),p.TgZ(5,"mat-form-field",72),p.TgZ(6,"input",73),p.NdJ("ngModelChange",function(e){return p.CHM(t),p.oxw().Occurrence=e}),p.qZA(),p._UZ(7,"mat-datepicker-toggle",74),p._UZ(8,"ngx-mat-datetime-picker",33,75),p.qZA(),p.qZA(),p.qZA(),p.qZA()}if(2&t){const t=p.MAs(9),e=p.oxw();p.xp6(6),p.Q6J("ngxMatDatetimePicker",t)("ngModel",e.Occurrence)("disabled",e.disabled),p.xp6(1),p.Q6J("for",t),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi)}}function U(t,e){1&t&&(p.TgZ(0,"ion-label",76),p._uU(1,"Adicionar intervenientes*"),p.qZA())}function E(t,e){if(1&t&&(p.TgZ(0,"ion-label"),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.xp6(1),p.Oqu(t.Name)}}function J(t,e){1&t&&(p.TgZ(0,"ion-label",76),p._uU(1,"Com conhecimento"),p.qZA())}function Y(t,e){if(1&t&&(p.TgZ(0,"ion-label"),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.xp6(1),p.Oqu(t.Name)}}function R(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"div",77),p.TgZ(1,"ion-list"),p.TgZ(2,"ion-item"),p.TgZ(3,"ion-label"),p.TgZ(4,"p",78),p.TgZ(5,"span",79),p._uU(6),p.qZA(),p.TgZ(7,"span",80),p._uU(8),p.qZA(),p.TgZ(9,"span",81),p.NdJ("click",function(){const e=p.CHM(t).index;return p.oxw().removeAttachment(e)}),p._UZ(10,"ion-icon",82),p.qZA(),p.qZA(),p.TgZ(11,"p"),p.TgZ(12,"span",83),p._uU(13),p.qZA(),p.TgZ(14,"span",84),p._uU(15),p.ALo(16,"date"),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA()}if(2&t){const t=e.$implicit;p.xp6(6),p.Oqu(t.Assunto),p.xp6(2),p.Oqu(t.appName),p.xp6(5),p.Oqu(t.EntidadeOrganicaNome),p.xp6(2),p.hij(" ",p.xi3(16,4,t.Data,"dd-MM-yyyy HH:mm")," ")}}function Q(t,e){if(1&t&&p._UZ(0,"app-empty-container",85),2&t){const t=p.oxw();p.Q6J("texto",t.emptyTextDescription)}}function L(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"app-attendee-modal",86),p.NdJ("dynamicSetIntervenient",function(e){return p.CHM(t),p.oxw().dynamicSetIntervenient(e)}),p.qZA()}if(2&t){const t=p.oxw();p.Q6J("footer",!1)("taskParticipants",t.taskParticipants)("taskParticipantsCc",t.taskParticipantsCc)("adding",t.adding)}}const z=r||r,j={parse:{dateInput:"YYYY-MMMM-DD HH:mm"},display:{dateInput:"DD MMM YYYY H:mm",monthYearLabel:"MMM YYYY",dateA11yLabel:"LL",monthYearA11yLabel:"MMMM YYYY"}};let H=(()=>{class t{constructor(t,e,n,o,a,s,r,d){this.modalController=t,this.router=e,this.navParams=n,this.processes=o,this.toastService=s,this.documentService=r,this.calendarService=d,this.disabled=!1,this.showSpinners=!0,this.showSeconds=!1,this.touchUi=!1,this.enableMeridian=!1,this.minDate=new Date,this.stepHour=1,this.stepMinute=5,this.stepSecond=5,this.dateControlStart=new c.NI(z("DD MM YYYY hh")),this.dateControlEnd=new c.NI(z("DD MM YYYY hh")),this.p={},this.validateFrom=!1,this.recurringTypes=[],this.Occurrence=new Date,this.EventRecurrenceType="-1",this.showLoader=!1,this.taskParticipants=[],this.taskParticipantsCc=[],this.documents=[],this.attachments=[],this.adding="intervenient",this.formLocationSatus=!1,this.showAttendees=!1,this.emptyTextDescription="Sem intervenientes selecionados",this.searchDocumentPipe=l.G,this.loggeduser=a.ValidatedUser,this.task=this.navParams.get("task"),this.document=this.navParams.get("document"),this.postData=new i.j,this.postData.Body={BodyType:"1",Text:""},this.postData.Subject=this.task.workflowInstanceDataFields.Subject,this.postData.CalendarName="Oficial",this.postData.Category="Reuni\xe3o"}get dateStart(){return window.innerWidth<801?this.postData.StartDate:this.dateControlStart.value}get dateEnd(){return window.innerWidth<801?this.postData.EndDate:this.dateControlEnd.value}ngOnInit(){this.adding="intervenient",console.log(this.task),this.setDefaultTime(),this.getRecurrenceTypes()}getRecurrenceTypes(){this.calendarService.getRecurrenceTypes().subscribe(t=>{this.recurringTypes=t})}setDefaultTime(){this.postData.StartDate=new Date,this.postData.EndDate=new Date((new Date).getTime()+9e5)}close(){this.modalController.dismiss(null)}goBack(){this.modalController.dismiss(null)}runValidation(){this.validateFrom=!0}get dateValid(){return window.innerWidth<=800?this.postData.StartDate<this.postData.EndDate?["ok"]:[]:["ok"]}injectValidation(){this.Form=new c.cw({Subject:new c.NI(this.postData.Subject,[]),Location:new c.NI(this.postData.Location,[]),CalendarName:new c.NI(this.postData.CalendarName,[]),Date:new c.NI(this.dateValid,[c.kI.required]),participantes:new c.NI(this.taskParticipants,[]),Categories:new c.NI(this.postData.Category,[])})}saveTask(){return(0,o.mG)(this,void 0,void 0,function*(){if("MDGPR"==this.loggeduser.Profile&&(this.injectValidation(),this.runValidation(),this.Form.invalid))return!1;let t=this.taskParticipants.concat(this.taskParticipantsCc),e={EventProcess:{Body:this.postData.Body.Text,Location:this.postData.Location,StartDate:this.dateStart,EndDate:this.dateEnd,EventType:"Reuni\xe3o",ParticipantsList:t,Subject:this.postData.Subject,IsRecurring:this.postData.IsRecurring,Message:this.postData.Subject,IsAllDayEvent:this.postData.IsRecurring,EventRecurrence:{Type:this.EventRecurrenceType,LastOccurrence:this.Occurrence}},Attachments:[]};this.document.Documents?this.document.Documents.forEach(t=>{console.log(t),e.Attachments.push({ApplicationId:361,Source:1,SourceId:t.docID||t.docId||t.DocId,SourceName:t.Assunto})}):e.Attachments.push({ApplicationId:8,Source:1,SourceId:this.document.docID||this.document.docId||this.document.DocId,SourceName:this.document.Assunto}),this.attachments.forEach(t=>{console.log("e",t),e.Attachments.push({ApplicationId:t.ApplicationType,Source:1,SourceId:t.Id,SourceName:t.Assunto})});const n=this.toastService.loading();try{yield this.documentService.setUpMeeting(e).toPromise(),this.toastService.successMessage("Processo criado"),this.close()}catch(o){this.toastService.badRequest("Processo n\xe3o criado")}finally{n.remove()}})}addParticipants(){return(0,o.mG)(this,void 0,void 0,function*(){if(this.adding="intervenient",window.innerWidth<=801){const t=yield this.modalController.create({component:s.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"modal modal-desktop",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}else this.showAttendees=!0})}addParticipantsCc(){return(0,o.mG)(this,void 0,void 0,function*(){if(this.adding="CC",window.innerWidth<=800){const t=yield this.modalController.create({component:s.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"modal modal-desktop",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}else this.showAttendees=!0})}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:a.Z,cssClass:"modal modal-desktop modal-width-100-width-background modal-background",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>{t&&this.attachments.push(t.data.selected)})})}removeAttachment(t){this.attachments=this.attachments.filter((e,n)=>t!=n)}validateFormInputs(){let t=this.postData.Location.trim();!this.postData.Location&&t.length<=0&&(this.formLocationSatus=!0)}dynamicSetIntervenient({taskParticipants:t,taskParticipantsCc:e}){this.taskParticipants=t,this.taskParticipantsCc=e}goToGabinete(){this.router.navigate(["/home/gabinete-digital"])}setIntervenient(t){this.taskParticipants=t}setIntervenientCC(t){this.taskParticipantsCc=t}}return t.\u0275fac=function(e){return new(e||t)(p.Y36(g.IN),p.Y36(u.F0),p.Y36(g.X1),p.Y36(h.$),p.Y36(m.e),p.Y36(f.k),p.Y36(v),p.Y36(Z.n))},t.\u0275cmp=p.Xpm({type:t,selectors:[["app-document-set-up-meeting"]],viewQuery:function(t,e){if(1&t&&(p.Gf(_,5),p.Gf(O,5),p.Gf(q,5),p.Gf(k,5)),2&t){let t;p.iGM(t=p.CRH())&&(e.picker=t.first),p.iGM(t=p.CRH())&&(e.fim=t.first),p.iGM(t=p.CRH())&&(e.inicio=t.first),p.iGM(t=p.CRH())&&(e.picker1=t.first)}},features:[p._Bn([{provide:d.ab,useValue:j}])],decls:135,vars:54,consts:[[1,"main-content","d-flex","height-100"],[1,"content","d-flex","flex-column","width-100","height-100"],[1,"header-content","header-default-padding"],[1,"header-title"],[1,"overflow-y-auto","content-default-padding"],[1,"ion-item-container","width-100"],["placeholder","Assunto*",3,"ngModel","ngModelChange"],[4,"ngIf"],[1,"container-div","width-100"],[1,"ion-item-class-2","width-100"],[1,"ion-icon-class"],["slot","start","src","assets/images/icons-location.svg"],[1,"ion-input-class"],["placeholder","Localiza\xe7\xe3o*",3,"ngModel","ngModelChange"],[1,"container-div"],[1,"ion-item-class-2"],["slot","start","src","assets/images/icons-calendar.svg"],["placeholder","Selecione repeti\xe7\xe3o","interface","action-sheet","Cancel-text","Cancelar","required","",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["value","Oficial"],["value","Pessoal"],["floatLabel","never","appearance","none",1,"d-none","d-md-block","width-100"],["placeholder","Selecione agenda",3,"ngModel","ngModelChange"],["placeholder","Selecione tipo de evento*","interface","action-sheet","Cancel-text","Cancelar","required","",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["value","Reuni\xe3o"],["value","Viagem"],["value","Confer\xeancia"],["value","Encontro"],["appearance","none","placeholder","Sample Type","required","",1,"width-100"],[3,"ngModel","ngModelChange"],["placeholder","In\xedcio*","displayFormat","D MMM YYYY H:mm","minuteValues","0,30","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","value","2020-11-19T11:06Z",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["appearance","none",1,"width-100","date-hour-picker","d-md-block"],["matInput","","placeholder","In\xedcio*",3,"ngxMatDatetimePicker","formControl","disabled"],["id","new-inicio","matSuffix","",3,"for"],[3,"showSpinners","showSeconds","stepHour","stepMinute","stepSecond","touchUi"],["picker1",""],[1,"ion-input-class","flex-grow-1"],["appearance","none",1,"date-hour-picker","width-100","d-none","d-md-block"],["matInput","","placeholder","Fim*",3,"ngxMatDatetimePicker","formControl","disabled"],["id","new-fim","matSuffix","",3,"for"],["fim",""],[1,"ion-item-class-2","d-flex"],["slot","start","src","assets/images/icons-refresh.svg"],["appearance","none","floatLabel","never","value","false","interface","action-sheet","required","",1,"width-100"],["placeholder","Selecione repeti\xe7\xe3o*",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","container-div width-100",4,"ngIf"],["slot","start","src","assets/images/icons-person.svg"],[1,"ion-input-class-no-height","cursor-pointer",3,"click"],[1,"list-people"],["lines","none"],["class","list-people-title",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"add-people"],["slot","start","src","assets/images/icons-arrow-forward.svg"],["slot","start","src","assets/images/icons-people-cc.svg"],["slot","start","src","assets/images/icons-description.svg"],[1,"ion-input-class-no-height","width-100"],["placeholder","Detalhes","rows","6","cols","20",3,"ngModel","ngModelChange"],[1,"ion-item-container-no-border","cursor-pointer",3,"click"],[1,"attach-icon"],["src","assets/images/icons-attach-doc.svg"],[1,"attach-document"],["class","list ",4,"ngFor","ngForOf"],[1,"aside-righ","flex-grow-1"],["class","d-flex height-100 flex-column",3,"texto",4,"ngIf"],["class"," d-flex flex-column height-100",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient",4,"ngIf"],[1,"buttons"],["shape","round",1,"btn-cancel",3,"click"],["shape","round",1,"btn-ok",3,"click"],["class","input-errror-message",4,"ngIf"],[1,"input-errror-message"],[3,"value"],[1,"date-hour-picker"],["matInput","","placeholder","\xdaltima ocurr\xeancia",3,"ngxMatDatetimePicker","ngModel","disabled","ngModelChange"],["id","last-occurrence","matSuffix","",3,"for"],["occurrrence",""],[1,"list-people-title"],[1,"list"],[1,"d-flex","ion-justify-content-between"],[1,"attach-title-item"],[1,"app-name"],[1,"close-button","text-black",3,"click"],["src","assets/images/icons-delete-25.svg",1,"font-20"],[1,"span-left"],[1,"span-right"],[1,"d-flex","height-100","flex-column",3,"texto"],[1,"d-flex","flex-column","height-100",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient"]],template:function(t,e){if(1&t&&(p.TgZ(0,"ion-content"),p.TgZ(1,"div",0),p.TgZ(2,"div",1),p.TgZ(3,"div",2),p.TgZ(4,"div",3),p.TgZ(5,"label"),p._uU(6,"Convocar Reuni\xe3o"),p.qZA(),p.qZA(),p.qZA(),p.TgZ(7,"div",4),p.TgZ(8,"div",5),p.TgZ(9,"ion-input",6),p.NdJ("ngModelChange",function(t){return e.postData.Subject=t}),p.qZA(),p.qZA(),p.YNc(10,S,2,1,"div",7),p.TgZ(11,"div",8),p.TgZ(12,"div",9),p.TgZ(13,"div",10),p._UZ(14,"ion-icon",11),p.qZA(),p.TgZ(15,"div",12),p.TgZ(16,"ion-input",13),p.NdJ("ngModelChange",function(t){return e.postData.Location=t}),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(17,"div",14),p.TgZ(18,"div",15),p.TgZ(19,"div",10),p._UZ(20,"ion-icon",16),p.qZA(),p.TgZ(21,"div",12),p.TgZ(22,"ion-select",17),p.NdJ("ngModelChange",function(t){return e.postData.CalendarName=t}),p.TgZ(23,"ion-select-option",18),p._uU(24,"Oficial"),p.qZA(),p.TgZ(25,"ion-select-option",19),p._uU(26,"Pessoal"),p.qZA(),p.qZA(),p.TgZ(27,"mat-form-field",20),p.TgZ(28,"mat-select",21),p.NdJ("ngModelChange",function(t){return e.postData.CalendarName=t}),p.TgZ(29,"mat-option",18),p._uU(30," Oficial "),p.qZA(),p.TgZ(31,"mat-option",19),p._uU(32," Pessoal "),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(33,"div",14),p.TgZ(34,"div",15),p.TgZ(35,"div",10),p._UZ(36,"ion-icon",16),p.qZA(),p.TgZ(37,"div",12),p.TgZ(38,"ion-select",22),p.NdJ("ngModelChange",function(t){return e.postData.Category=t}),p.TgZ(39,"ion-select-option",23),p._uU(40,"Reuni\xe3o"),p.qZA(),p.TgZ(41,"ion-select-option",24),p._uU(42,"Viagem"),p.qZA(),p.TgZ(43,"ion-select-option",25),p._uU(44,"Confer\xeancia"),p.qZA(),p.TgZ(45,"ion-select-option",26),p._uU(46,"Encontro"),p.qZA(),p.qZA(),p.TgZ(47,"mat-form-field",27),p.TgZ(48,"mat-select",28),p.NdJ("ngModelChange",function(t){return e.postData.Category=t}),p.TgZ(49,"mat-option",23),p._uU(50," Reuni\xe3o "),p.qZA(),p.TgZ(51,"mat-option",24),p._uU(52," Viagem "),p.qZA(),p.TgZ(53,"mat-option",25),p._uU(54," Confer\xeancia "),p.qZA(),p.TgZ(55,"mat-option",26),p._uU(56," Encontro "),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(57,"div",14),p.TgZ(58,"div",15),p.TgZ(59,"div",10),p._UZ(60,"ion-icon",16),p.qZA(),p.TgZ(61,"div",12),p.TgZ(62,"ion-datetime",29),p.NdJ("ngModelChange",function(t){return e.postData.StartDate=t}),p.qZA(),p.TgZ(63,"mat-form-field",30),p._UZ(64,"input",31),p._UZ(65,"mat-datepicker-toggle",32),p._UZ(66,"ngx-mat-datetime-picker",33,34),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(68,"div",14),p.TgZ(69,"div",15),p.TgZ(70,"div",10),p._UZ(71,"ion-icon",16),p.qZA(),p.TgZ(72,"div",35),p.TgZ(73,"ion-datetime",29),p.NdJ("ngModelChange",function(t){return e.postData.EndDate=t}),p.qZA(),p.TgZ(74,"mat-form-field",36),p._UZ(75,"input",37),p._UZ(76,"mat-datepicker-toggle",38),p._UZ(77,"ngx-mat-datetime-picker",33,39),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(79,"div",8),p.TgZ(80,"div",40),p.TgZ(81,"div",10),p._UZ(82,"ion-icon",41),p.qZA(),p.TgZ(83,"div",35),p.TgZ(84,"mat-form-field",42),p.TgZ(85,"mat-select",43),p.NdJ("ngModelChange",function(t){return e.EventRecurrenceType=t}),p.YNc(86,N,2,2,"mat-option",44),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.YNc(87,F,10,10,"div",45),p.TgZ(88,"div",14),p.TgZ(89,"div",15),p.TgZ(90,"div",10),p._UZ(91,"ion-icon",46),p.qZA(),p.TgZ(92,"div",47),p.NdJ("click",function(){return e.addParticipants()}),p.TgZ(93,"div",48),p.TgZ(94,"ion-item",49),p.TgZ(95,"ion-list"),p.YNc(96,U,2,0,"ion-label",50),p.YNc(97,E,2,1,"ion-label",51),p.qZA(),p.qZA(),p.qZA(),p.TgZ(98,"div",52),p._UZ(99,"ion-icon",53),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(100,"div",14),p.TgZ(101,"div",15),p.TgZ(102,"div",10),p._UZ(103,"ion-icon",54),p.qZA(),p.TgZ(104,"div",47),p.NdJ("click",function(){return e.addParticipantsCc()}),p.TgZ(105,"div",48),p.TgZ(106,"ion-item",49),p.TgZ(107,"ion-list"),p.YNc(108,J,2,0,"ion-label",50),p.YNc(109,Y,2,1,"ion-label",51),p.qZA(),p.qZA(),p.qZA(),p.TgZ(110,"div",52),p._UZ(111,"ion-icon",53),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(112,"div",14),p.TgZ(113,"div",40),p.TgZ(114,"div",10),p._UZ(115,"ion-icon",55),p.qZA(),p.TgZ(116,"div",56),p.TgZ(117,"ion-textarea",57),p.NdJ("ngModelChange",function(t){return e.postData.Body.Text=t}),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(118,"div",58),p.NdJ("click",function(){return e.getDoc()}),p.TgZ(119,"ion-label"),p.TgZ(120,"div",59),p._UZ(121,"ion-icon",60),p.qZA(),p.TgZ(122,"div",61),p.TgZ(123,"ion-label"),p._uU(124,"Anexar Documentos"),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.YNc(125,R,17,7,"div",62),p.qZA(),p.qZA(),p.TgZ(126,"div",63),p.YNc(127,Q,1,1,"app-empty-container",64),p.YNc(128,L,1,4,"app-attendee-modal",65),p.qZA(),p.qZA(),p.qZA(),p.TgZ(129,"ion-footer"),p.TgZ(130,"div",66),p.TgZ(131,"button",67),p.NdJ("click",function(){return e.close()}),p._uU(132,"Cancelar"),p.qZA(),p.TgZ(133,"button",68),p.NdJ("click",function(){return e.saveTask()}),p._uU(134,"Gravar"),p.qZA(),p.qZA(),p.qZA()),2&t){const t=p.MAs(67),n=p.MAs(78);let o,i,a,s,c,r,d;p.xp6(8),p.ekj("input-error",(null==e.Form||null==(o=e.Form.get("Subject"))?null:o.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Subject),p.xp6(1),p.Q6J("ngIf",e.Form&&e.validateFrom),p.xp6(5),p.ekj("input-error",(null==e.Form||null==(i=e.Form.get("Location"))?null:i.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Location),p.xp6(6),p.Q6J("ngModel",e.postData.CalendarName),p.xp6(6),p.Q6J("ngModel",e.postData.CalendarName),p.xp6(9),p.ekj("input-error",(null==e.Form||null==(a=e.Form.get("Categories"))?null:a.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Category),p.xp6(10),p.Q6J("ngModel",e.postData.Category),p.xp6(13),p.ekj("input-error",(null==e.Form||null==(s=e.Form.get("Date"))?null:s.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.StartDate),p.xp6(2),p.Q6J("ngxMatDatetimePicker",t)("formControl",e.dateControlStart)("disabled",e.disabled),p.xp6(1),p.Q6J("for",t),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi),p.xp6(6),p.ekj("input-error",(null==e.Form||null==(c=e.Form.get("Date"))?null:c.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.EndDate),p.xp6(2),p.Q6J("ngxMatDatetimePicker",n)("formControl",e.dateControlEnd)("disabled",e.disabled),p.xp6(1),p.Q6J("for",n),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi),p.xp6(6),p.ekj("input-error",(null==e.Form||null==(r=e.Form.get("dateOccurrence"))?null:r.invalid)&&e.validateFrom),p.xp6(2),p.Q6J("ngModel",e.EventRecurrenceType),p.xp6(1),p.Q6J("ngForOf",e.recurringTypes),p.xp6(1),p.Q6J("ngIf","-1"!=e.EventRecurrenceType),p.xp6(5),p.ekj("input-error",(null==e.Form||null==(d=e.Form.get("participantes"))?null:d.invalid)&&e.validateFrom),p.xp6(4),p.Q6J("ngIf",(null==e.taskParticipants?null:e.taskParticipants.length)<1),p.xp6(1),p.Q6J("ngForOf",e.taskParticipants),p.xp6(11),p.Q6J("ngIf",(null==e.taskParticipantsCc?null:e.taskParticipantsCc.length)<1),p.xp6(1),p.Q6J("ngForOf",e.taskParticipantsCc),p.xp6(8),p.Q6J("ngModel",e.postData.Body.Text),p.xp6(8),p.Q6J("ngForOf",e.attachments),p.xp6(2),p.Q6J("ngIf",!e.showAttendees),p.xp6(1),p.Q6J("ngIf",e.showAttendees)}},directives:[g.W2,g.pK,g.j9,c.JJ,c.On,x.O5,g.gu,g.t9,g.QI,c.Q7,g.n0,C.KE,M.gD,b.ey,g.x4,P.Nt,d.g2,c.Fj,c.oH,A.nW,C.R9,d.AB,x.sg,g.Ie,g.q_,g.g2,g.Q$,g.fr,w.M,T.Y],pipes:[x.uU],styles:[".content[_ngcontent-%COMP%]{margin:0;float:left}.content[_ngcontent-%COMP%] .header-title[_ngcontent-%COMP%]{font-family:Roboto;font-size:25px;padding:0;color:#000;float:left}.content[_ngcontent-%COMP%] .ion-item-container[_ngcontent-%COMP%]{margin:15px auto;border:1px solid #ebebeb;border-radius:5px;padding-left:10px}.content[_ngcontent-%COMP%] .ion-item-container-no-border[_ngcontent-%COMP%]{margin:0 auto;padding:0!important;overflow:auto}.content[_ngcontent-%COMP%] .container-div[_ngcontent-%COMP%]{margin-bottom:15px;overflow:hidden}.content[_ngcontent-%COMP%] .ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto}.content[_ngcontent-%COMP%] .ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}.content[_ngcontent-%COMP%] ion-select[_ngcontent-%COMP%]{padding-left:5px;margin-left:0}.content[_ngcontent-%COMP%] .ion-input-class[_ngcontent-%COMP%]{width:calc(100% - 45px);height:45px;border:1px solid #ebebeb;border-radius:5px;padding-left:5px;padding-right:10px;float:left}.content[_ngcontent-%COMP%] .ion-input-class-no-height[_ngcontent-%COMP%]{border:1px solid #ebebeb;border-radius:5px;overflow:auto}.content[_ngcontent-%COMP%] .list-people[_ngcontent-%COMP%]{width:256px;float:left}.content[_ngcontent-%COMP%] .add-people[_ngcontent-%COMP%]{width:45px;float:right;overflow:auto;font-size:25px;padding:10px}.content[_ngcontent-%COMP%] .list-people-title[_ngcontent-%COMP%]{color:#a3a3a3}.content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.content[_ngcontent-%COMP%] .attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.container-footer[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.button-cancel[_ngcontent-%COMP%]{--background:#e0e9ee;--color:#061b52}.button-cancel[_ngcontent-%COMP%], .button-save[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;margin:10px}.button-save[_ngcontent-%COMP%]{--background:#42b9fe;--color:#fff}.text-input[_ngcontent-%COMP%]{width:100%;border:1px solid #ebebeb;margin:0 15px 15px 0;padding:0!important;border-radius:5px}.error[_ngcontent-%COMP%]{font-size:12px;font-weight:700;padding-bottom:20px}.error[_ngcontent-%COMP%], .span-color[_ngcontent-%COMP%]{color:red}.buttons[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:20px;overflow:auto}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.app-name[_ngcontent-%COMP%]{background:#42b9f2;border-radius:18px;text-align:center;display:flex;align-items:center;padding:0 5px;color:#fff;font-size:9pt;font-weight:500;height:19px;-webkit-border-radius:18px;-moz-border-radius:18px;-ms-border-radius:18px;-o-border-radius:18px}.close-button[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .app-name[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .close-button[_ngcontent-%COMP%]{display:block!important}"]}),t})()},97047:function(t,e,n){"use strict";n.d(e,{L:function(){return a}});var o=n(37716),i=n(35957);let a=(()=>{class t{constructor(t){this.modalController=t}ngOnInit(){}close(){this.modalController.dismiss("No")}save(){this.modalController.dismiss("Yes")}}return t.\u0275fac=function(e){return new(e||t)(o.Y36(i.IN))},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-eliminate-event"]],decls:15,vars:0,consts:[[1,"ion-no-border"],[1,"header-content","width-100"],[1,"header-title","d-flex","width-100"],[1,"header-body","width-100"],[1,"buttons","width-100"],["shape","round",1,"btn-ok-medium",3,"click"],["shape","round",1,"btn-delete-medium",3,"click"]],template:function(t,e){1&t&&(o._UZ(0,"ion-header",0),o.TgZ(1,"ion-content"),o.TgZ(2,"div",1),o.TgZ(3,"div",2),o.TgZ(4,"h3"),o._uU(5,"Deseja retirar este expediente da sua caixa de correspond\xeancia?"),o.qZA(),o.qZA(),o.qZA(),o.TgZ(6,"div",3),o.TgZ(7,"p"),o._uU(8,"Nota: Ao Efetuar esta opera\xe7\xe3o, o tratamento deste expediente n\xe3o poder\xe1 ser realizado a partir da caixa de correspond\xeancia"),o.qZA(),o.qZA(),o.qZA(),o.TgZ(9,"ion-footer"),o.TgZ(10,"div",4),o.TgZ(11,"button",5),o.NdJ("click",function(){return e.close()}),o._uU(12,"N\xe3o"),o.qZA(),o.TgZ(13,"button",6),o.NdJ("click",function(){return e.save()}),o._uU(14,"Sim"),o.qZA(),o.qZA(),o.qZA())},directives:[i.Gu,i.W2,i.fr],styles:["ion-content[_ngcontent-%COMP%]{--padding-top:15px;--padding-start:15px;--padding-end:15px}.header-content[_ngcontent-%COMP%]{overflow:hidden;margin:0 auto;align-items:center;justify-content:center}.header-title[_ngcontent-%COMP%]{font-family:Roboto;font-size:20px;color:#000;margin:0 5px}.header-body[_ngcontent-%COMP%]{margin:0 5px}.buttons[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:15px 0}"]}),t})()},95336:function(t,e,n){"use strict";n.d(e,{Q:function(){return o}});class o{}},82316:function(t,e,n){"use strict";n.d(e,{E:function(){return o}});class o{}},45470:function(t,e,n){"use strict";n.d(e,{S:function(){return o}});class o{}},97049:function(t,e,n){"use strict";n.d(e,{f:function(){return Q}});var o=n(64762),i=n(3679),a=n(18119),s=n(55199),c=n(4528),r=n(37716),d=n(35957),l=n(80106),p=n(20985),g=n(84465),u=n(39895),h=n(38583),m=n(17352);function f(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," Campo obrigat\xf3rio. "),r.qZA())}function v(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," O campo deve ter pelo menos 4 caracteres. "),r.qZA())}function Z(t,e){if(1&t&&(r.TgZ(0,"div",60),r.YNc(1,f,2,0,"div",10),r.YNc(2,v,2,0,"div",10),r.qZA()),2&t){const t=r.oxw(2);r.xp6(1),r.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.required),r.xp6(1),r.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.minlength)}}function x(t,e){if(1&t&&(r.TgZ(0,"div"),r.YNc(1,Z,3,2,"div",59),r.qZA()),2&t){const t=r.oxw();r.xp6(1),r.Q6J("ngIf",t.Form.get("Subject").invalid)}}function C(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," Campo obrigat\xf3rio. "),r.qZA())}function M(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," O campo deve ter pelo menos 4 caracteres. "),r.qZA())}function b(t,e){if(1&t&&(r.TgZ(0,"div",60),r.YNc(1,C,2,0,"div",10),r.YNc(2,M,2,0,"div",10),r.qZA()),2&t){const t=r.oxw(2);r.xp6(1),r.Q6J("ngIf",null==t.Form.get("Location").errors?null:t.Form.get("Location").errors.required),r.xp6(1),r.Q6J("ngIf",null==t.Form.get("Location").errors?null:t.Form.get("Location").errors.minlength)}}function P(t,e){if(1&t&&(r.TgZ(0,"div"),r.YNc(1,b,3,2,"div",59),r.qZA()),2&t){const t=r.oxw();r.xp6(1),r.Q6J("ngIf",t.Form.get("Location").invalid)}}function A(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," Campo obrigat\xf3rio. "),r.qZA())}function w(t,e){if(1&t&&(r.TgZ(0,"div",60),r._uU(1),r.YNc(2,A,2,0,"div",10),r.qZA()),2&t){const t=r.oxw(2);r.xp6(1),r.hij(" ",t.postEvent.Category," "),r.xp6(1),r.Q6J("ngIf",null==t.Form.get("CalendarName").errors?null:t.Form.get("CalendarName").errors.required)}}function T(t,e){if(1&t&&(r.TgZ(0,"div"),r.YNc(1,w,3,2,"div",59),r.qZA()),2&t){const t=r.oxw();r.xp6(1),r.Q6J("ngIf",t.Form.get("CalendarName").invalid)}}function _(t,e){1&t&&(r.TgZ(0,"div"),r._uU(1," Campo obrigat\xf3rio. "),r.qZA())}function O(t,e){if(1&t&&(r.TgZ(0,"div",60),r._uU(1),r.YNc(2,_,2,0,"div",10),r.qZA()),2&t){const t=r.oxw(2);r.xp6(1),r.hij(" ",t.postEvent.Category," "),r.xp6(1),r.Q6J("ngIf",null==t.Form.get("Categories").errors?null:t.Form.get("Categories").errors.required)}}function q(t,e){if(1&t&&(r.TgZ(0,"div"),r.YNc(1,O,3,2,"div",59),r.qZA()),2&t){const t=r.oxw();r.xp6(1),r.Q6J("ngIf",t.Form.get("Categories").invalid)}}function k(t,e){if(1&t&&(r.TgZ(0,"ion-select-option",61),r._uU(1),r.qZA()),2&t){const t=e.$implicit;r.s9C("value",t.Code),r.xp6(1),r.Oqu(t.Description)}}function y(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"div",11),r.TgZ(1,"div",12),r.TgZ(2,"div",13),r._UZ(3,"ion-icon",17),r.qZA(),r.TgZ(4,"div",15),r.TgZ(5,"ion-datetime",62),r.NdJ("ngModelChange",function(e){return r.CHM(t),r.oxw().postEvent.EventRecurrence.LastOccurrence=e}),r.qZA(),r.qZA(),r.qZA(),r.qZA()}if(2&t){const t=r.oxw();r.xp6(5),r.Q6J("ngModel",t.postEvent.EventRecurrence.LastOccurrence)}}function D(t,e){1&t&&(r.TgZ(0,"ion-label",63),r._uU(1,"Adicionar intervenientes"),r.qZA())}function I(t,e){if(1&t&&(r.TgZ(0,"ion-label"),r._uU(1),r.qZA()),2&t){const t=e.$implicit;r.xp6(1),r.Oqu(t.Name)}}function S(t,e){1&t&&(r.TgZ(0,"ion-label",63),r._uU(1,"Adicionar intervenientes"),r.qZA())}function N(t,e){if(1&t&&(r.TgZ(0,"ion-label"),r._uU(1),r.qZA()),2&t){const t=e.$implicit;r.xp6(1),r.Oqu(t.Name)}}function F(t,e){1&t&&(r.TgZ(0,"span",74),r._uU(1," Correspond\xeancia "),r.qZA())}function U(t,e){1&t&&(r.TgZ(0,"span",74),r._uU(1," Ac\xe7\xf5es Presidenciais "),r.qZA())}function E(t,e){1&t&&(r.TgZ(0,"span",74),r._uU(1," Arquivo Despacho Electr\xf3nico "),r.qZA())}function J(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"ion-list",66),r.TgZ(1,"ion-item",67),r.TgZ(2,"ion-label",68),r.TgZ(3,"p",69),r.TgZ(4,"span",70),r._uU(5),r.qZA(),r.TgZ(6,"span",71),r.NdJ("click",function(){r.CHM(t);const e=r.oxw(),n=e.$implicit,o=e.index;return r.oxw().deleteAttachment(n.Id,o)}),r._UZ(7,"ion-icon",72),r.qZA(),r.qZA(),r.TgZ(8,"p"),r.YNc(9,F,2,0,"span",73),r.YNc(10,U,2,0,"span",73),r.YNc(11,E,2,0,"span",73),r.qZA(),r.qZA(),r.qZA(),r.qZA()}if(2&t){const t=r.oxw().$implicit;r.xp6(5),r.Oqu(t.SourceName),r.xp6(4),r.Q6J("ngIf",8==t.ApplicationId),r.xp6(1),r.Q6J("ngIf",386==t.ApplicationId),r.xp6(1),r.Q6J("ngIf",361==t.ApplicationId)}}function Y(t,e){if(1&t&&(r.TgZ(0,"div",64),r.YNc(1,J,12,4,"ion-list",65),r.qZA()),2&t){const t=e.$implicit;r.xp6(1),r.Q6J("ngIf",!t.remove)}}function R(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"app-attendee-modal",75),r.NdJ("dynamicSetIntervenient",function(e){return r.CHM(t),r.oxw().dynamicSetIntervenient(e)}),r.qZA()}if(2&t){const t=r.oxw();r.Q6J("footer",!1)("taskParticipants",t.taskParticipants)("taskParticipantsCc",t.taskParticipantsCc)("adding",t.adding)("footer",!1)}}let Q=(()=>{class t{constructor(t,e,n,o,i,s,c){this.modalController=t,this.navParams=e,this.eventsService=n,this.alertController=o,this.attachmentsService=i,this.toastService=s,this.router=c,this.validateFrom=!1,this.endMinDate=new Date((new Date).getTime()+9e5),this.minDate=(new Date).toISOString().slice(0,10),this.segment="true",this.loadedEventAttachments=[],this.taskParticipants=[],this.taskParticipantsCc=[],this.adding="intervenient",this.showAttendees=!1,this.postEvent=new a.j,this.isEventEdited=!1,this.postEvent.EventRecurrence={Type:"-1"},this.postEvent=this.navParams.get("event"),this.caller=this.navParams.get("caller"),this.initCalendarName=this.postEvent.CalendarName,this.postEvent&&this.postEvent.Body&&"string"==typeof this.postEvent.Body.Text&&(this.postEvent.Body.Text=this.postEvent.Body.Text.replace(/<[^>]+>/g,"")),null==this.postEvent.Attendees?this.taskParticipants=[]:this.postEvent.Attendees.forEach(t=>{t.IsRequired?this.taskParticipants.push(t):this.taskParticipantsCc.push(t)}),this.isRecurring=0==this.postEvent.IsRecurring?"N\xe3o se repete":"Repete",this.getAttachments(this.postEvent.EventId)}ngOnInit(){window.onresize=t=>{window.innerWidth>=1024&&this.modalController.dismiss()},window.innerWidth>800&&(this.showAttendees=!0),this.getRecurrenceTypes(),setTimeout(()=>{this.selectedRecurringType=this.postEvent.EventRecurrence.Type.toString()},500)}close(){this.modalController.dismiss()}goBack(){console.log(this.caller),this.router.navigate(["/home",this.caller])}getRecurrenceTypes(){this.eventsService.getRecurrenceTypes().subscribe(t=>{console.log(t),this.recurringTypes=t})}onSelectedRecurringChanged(t){console.log(t),t.length>1&&(console.log(t.filter(t=>"-1"!=t)),this.selectedRecurringType=t.filter(t=>"-1"!=t)),0==t.length&&(this.selectedRecurringType="-1")}runValidation(){this.validateFrom=!0}injectValidation(){this.Form=new i.cw({Subject:new i.NI(this.postEvent.Subject,[i.kI.required]),Location:new i.NI(this.postEvent.Location,[i.kI.required]),CalendarName:new i.NI(this.postEvent.CalendarName,[i.kI.required]),Categories:new i.NI(this.postEvent.Category,[i.kI.required]),IsRecurring:new i.NI(this.postEvent.IsRecurring,[i.kI.required]),Date:new i.NI(new Date(this.postEvent.StartDate).getTime()<new Date(this.postEvent.EndDate).getTime()?"ok":null,[i.kI.required]),participantes:new i.NI(this.taskParticipants,[i.kI.required])})}save(){if(this.injectValidation(),this.runValidation(),this.Form.invalid)return!1;"-1"!=this.selectedRecurringType&&(this.postEvent.EventRecurrence.Type=this.selectedRecurringType),this.postEvent.Attendees=this.taskParticipants.concat(this.taskParticipantsCc),this.postEvent.EventRecurrence.Type=this.selectedRecurringType,this.eventsService.editEvent(this.postEvent,2,3).subscribe(()=>(0,o.mG)(this,void 0,void 0,function*(){if(this.initCalendarName!=this.postEvent.CalendarName){let e={EventId:this.postEvent.EventId,CalendarDestinationName:this.postEvent.CalendarName};try{yield this.eventsService.changeAgenda(e).toPromise()}catch(t){}finally{this.goBack()}}this.toastService.successMessage()}),t=>{this.toastService.badRequest()}),this.isEventEdited=!0,this.modalController.dismiss(this.isEventEdited),this.saveDocument()}saveDocument(){this.loadedEventAttachments.forEach(t=>{const e=t.remove;if("add"==t.Id){const e={SourceTitle:t.SourceName,ParentId:this.postEvent.EventId,Source:"1",SourceId:t.SourceId,ApplicationId:t.ApplicationId.toString(),Id:"0",Link:"",SerialNumber:""};this.attachmentsService.setEventAttachmentById(e).subscribe(()=>{this.getAttachments(this.postEvent.EventId)})}else e&&this.attachmentsService.deleteEventAttachmentById(t.Id).subscribe(t=>{})})}openAttendees(){return(0,o.mG)(this,void 0,void 0,function*(){if(window.innerWidth>801)this.showAttendees=!0;else{const t=yield this.modalController.create({component:s.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"attendee",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}})}setIntervenient(t){this.taskParticipants=t,this.postEvent.Attendees=t}setIntervenientCC(t){this.taskParticipantsCc=t}addParticipants(){this.adding="intervenient",this.openAttendees()}addParticipantsCC(){this.adding="CC",this.openAttendees()}dynamicSetIntervenient({taskParticipants:t,taskParticipantsCc:e}){this.taskParticipants=t,this.taskParticipantsCc=e}getAttachments(t){this.attachmentsService.getAttachmentsById(t).subscribe(t=>{this.loadedEventAttachments=t,console.log("res",t)})}deleteAttachment(t,e){"add"==this.loadedEventAttachments[e].Id?this.loadedEventAttachments=this.loadedEventAttachments.filter((t,n)=>n!=e):this.loadedEventAttachments[e].remove=!0}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:c.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){if(t){const e=t.data,n={SourceName:e.selected.Assunto,ParentId:this.postEvent.EventId,SourceId:e.selected.Id,Stakeholders:!1,ApplicationId:e.selected.ApplicationType.toString(),CreateDate:!1,Id:"add",SourceTitle:e.selected.Assunto,Source:"1",Link:"",SerialNumber:""};console.log(this.loadedEventAttachments),this.loadedEventAttachments.push(n)}}))})}}return t.\u0275fac=function(e){return new(e||t)(r.Y36(d.IN),r.Y36(d.X1),r.Y36(l.n),r.Y36(d.Br),r.Y36(p.o),r.Y36(g.k),r.Y36(u.F0))},t.\u0275cmp=r.Xpm({type:t,selectors:[["app-edit-event"]],decls:112,vars:34,consts:[[1,"main-content","height-100"],[1,"content","d-flex","flex-column","width-md-100","height-100"],[1,"main-header","pt-30","px-20","background-white","pb-15"],[1,"title-content"],[1,"middle"],[1,"title"],[1,"overflow-y-auto"],[1,"px-20"],[1,"ion-item-container","width-100"],["placeholder","Assunto*",3,"ngModel","ngModelChange"],[4,"ngIf"],[1,"container-div","width-100"],[1,"ion-item-class-2"],[1,"ion-icon-class"],["slot","start","src","assets/images/icons-location.svg"],[1,"ion-input-class"],["placeholder","Localiza\xe7\xe3o*",3,"ngModel","ngModelChange"],["slot","start","src","assets/images/icons-calendar.svg"],["placeholder","Selecione agenda*","interface","action-sheet","Cancel-text","Cancelar","required","",3,"selectedText","ngModel","ngModelChange"],["value","Oficial"],["value","Pessoal"],["placeholder","Selecione tipo de evento*","interface","action-sheet","Cancel-text","Cancelar","required","",3,"ngModel","selectedText","ngModelChange"],["value","Reuni\xe3o"],["value","Viagem"],["value","Confer\xeancia"],["value","Encontro"],[1,"ion-item-class-2","width-100"],[1,"ion-input-class","width-100"],["placeholder","In\xedcio","displayFormat","D MMM YYYY H:mm","minuteValues","0,15,30,45","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","max","2025",3,"ngModel","min","ngModelChange"],["placeholder","Fim","displayFormat","D MMM YYYY H:mm","minuteValues","0,15,30,45","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","max","2025",3,"ngModel","min","ngModelChange"],["slot","start","src","assets/images/icons-refresh.svg"],["placeholder","Selecione a repeti\xe7\xe3o*","interface","action-sheet","Cancel-text","Cancelar","required","",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","container-div width-100",4,"ngIf"],[1,"ion-item-class-2","cursor-pointer",3,"click"],["slot","start","src","assets/images/icons-person.svg"],[1,"ion-input-class-no-height","d-flex"],[1,"list-people","flex-grow-1"],["lines","none"],["class","list-people-title",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"add-people"],["slot","start","src","assets/images/icons-arrow-forward.svg"],[1,"ion-item-class-2","d-flex","width-100"],[1,"ion-icon-class","d-flex"],["slot","start","src","assets/images/icons-description.svg"],[1,"ion-input-class-no-height","width-100","flex-grow-1"],["placeholder","Detalhes",3,"ngModel","ngModelChange"],[1,"d-flex","container-div","width-100","ion-item-container-no-border"],[1,"cursor-pointer",3,"click"],[1,"attach-icon"],["src","assets/images/icons-attach-doc.svg"],[1,"attach-document"],["class","d-flex container-div width-100",4,"ngFor","ngForOf"],["class","aside-right flex-column height-100 d-none d-md-flex pt-10",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient",4,"ngIf"],[1,"background-whit"],[1,"buttons"],["shape","round",1,"btn-cancel","cursor-pointer",3,"click"],["shape","round",1,"btn-ok","cursor-pointer",3,"click"],["class","input-errror-message",4,"ngIf"],[1,"input-errror-message"],[3,"value"],["placeholder","\xdaltima ocorr\xeancia","displayFormat","D MMM YYYY H:mm","minuteValues","0,15,30,45","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","min","2021","max","2025",3,"ngModel","ngModelChange"],[1,"list-people-title"],[1,"d-flex","container-div","width-100"],["class","width-100 list",4,"ngIf"],[1,"width-100","list"],[1,"width-100","ion-no-border","ion-no-padding"],[1,"width-100"],[1,"p-item-title","d-flex","ion-justify-content-between"],[1,"attach-title-item"],[1,"close-button","text-black",3,"click"],["src","assets/images/icons-delete-25.svg",1,"font-20"],["class","app-name span-left",4,"ngIf"],[1,"app-name","span-left"],[1,"aside-right","flex-column","height-100","d-none","d-md-flex","pt-10",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient"]],template:function(t,e){if(1&t&&(r.TgZ(0,"ion-content"),r.TgZ(1,"div",0),r.TgZ(2,"div",1),r.TgZ(3,"div",2),r.TgZ(4,"ion-header"),r.TgZ(5,"div",3),r.TgZ(6,"div",4),r.TgZ(7,"ion-label",5),r._uU(8,"Editar Evento"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(9,"ion-item-sliding",6),r.TgZ(10,"div",7),r.TgZ(11,"div",8),r.TgZ(12,"ion-input",9),r.NdJ("ngModelChange",function(t){return e.postEvent.Subject=t}),r.qZA(),r.qZA(),r.YNc(13,x,2,1,"div",10),r.TgZ(14,"div",11),r.TgZ(15,"div",12),r.TgZ(16,"div",13),r._UZ(17,"ion-icon",14),r.qZA(),r.TgZ(18,"div",15),r.TgZ(19,"ion-input",16),r.NdJ("ngModelChange",function(t){return e.postEvent.Location=t}),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.YNc(20,P,2,1,"div",10),r.TgZ(21,"div",11),r.TgZ(22,"div",12),r.TgZ(23,"div",13),r._UZ(24,"ion-icon",17),r.qZA(),r.TgZ(25,"div",15),r.TgZ(26,"ion-select",18),r.NdJ("ngModelChange",function(t){return e.postEvent.CalendarName=t}),r.TgZ(27,"ion-select-option",19),r._uU(28,"Oficial"),r.qZA(),r.TgZ(29,"ion-select-option",20),r._uU(30,"Pessoal"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.YNc(31,T,2,1,"div",10),r.TgZ(32,"div",11),r.TgZ(33,"div",12),r.TgZ(34,"div",13),r._UZ(35,"ion-icon",17),r.qZA(),r.TgZ(36,"div",15),r.TgZ(37,"ion-select",21),r.NdJ("ngModelChange",function(t){return e.postEvent.Category=t}),r.TgZ(38,"ion-select-option",22),r._uU(39,"Reuni\xe3o"),r.qZA(),r.TgZ(40,"ion-select-option",23),r._uU(41,"Viagem"),r.qZA(),r.TgZ(42,"ion-select-option",24),r._uU(43,"Confer\xeancia"),r.qZA(),r.TgZ(44,"ion-select-option",25),r._uU(45,"Encontro"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.YNc(46,q,2,1,"div",10),r.TgZ(47,"div",11),r.TgZ(48,"div",26),r.TgZ(49,"div",13),r._UZ(50,"ion-icon",17),r.qZA(),r.TgZ(51,"div",27),r.TgZ(52,"ion-datetime",28),r.NdJ("ngModelChange",function(t){return e.postEvent.StartDate=t}),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(53,"div",11),r.TgZ(54,"div",12),r.TgZ(55,"div",13),r._UZ(56,"ion-icon",17),r.qZA(),r.TgZ(57,"div",15),r.TgZ(58,"ion-datetime",29),r.NdJ("ngModelChange",function(t){return e.postEvent.EndDate=t}),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(59,"div",11),r.TgZ(60,"div",12),r.TgZ(61,"div",13),r._UZ(62,"ion-icon",30),r.qZA(),r.TgZ(63,"div",15),r.TgZ(64,"ion-select",31),r.NdJ("ngModelChange",function(t){return e.selectedRecurringType=t})("ngModelChange",function(t){return e.onSelectedRecurringChanged(t)}),r.YNc(65,k,2,2,"ion-select-option",32),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.YNc(66,y,6,1,"div",33),r.TgZ(67,"div",11),r.TgZ(68,"div",34),r.NdJ("click",function(){return e.addParticipants()}),r.TgZ(69,"div",13),r._UZ(70,"ion-icon",35),r.qZA(),r.TgZ(71,"div",36),r.TgZ(72,"div",37),r.TgZ(73,"ion-item",38),r.TgZ(74,"ion-list"),r.YNc(75,D,2,0,"ion-label",39),r.YNc(76,I,2,1,"ion-label",40),r.qZA(),r.qZA(),r.qZA(),r.TgZ(77,"div",41),r._UZ(78,"ion-icon",42),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(79,"div",11),r.TgZ(80,"div",34),r.NdJ("click",function(){return e.addParticipantsCC()}),r.TgZ(81,"div",13),r._UZ(82,"ion-icon",35),r.qZA(),r.TgZ(83,"div",36),r.TgZ(84,"div",37),r.TgZ(85,"ion-item",38),r.TgZ(86,"ion-list"),r.YNc(87,S,2,0,"ion-label",39),r.YNc(88,N,2,1,"ion-label",40),r.qZA(),r.qZA(),r.qZA(),r.TgZ(89,"div",41),r._UZ(90,"ion-icon",42),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(91,"div",11),r.TgZ(92,"div",43),r.TgZ(93,"div",44),r._UZ(94,"ion-icon",45),r.qZA(),r.TgZ(95,"div",46),r.TgZ(96,"ion-textarea",47),r.NdJ("ngModelChange",function(t){return e.postEvent.Body.Text=t}),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(97,"div",48),r.TgZ(98,"ion-label",49),r.NdJ("click",function(){return e.getDoc()}),r.TgZ(99,"div",50),r._UZ(100,"ion-icon",51),r.qZA(),r.TgZ(101,"div",52),r.TgZ(102,"ion-label"),r._uU(103,"Adicionar documentos"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.YNc(104,Y,2,1,"div",53),r.qZA(),r.qZA(),r.qZA(),r.YNc(105,R,1,5,"app-attendee-modal",54),r.qZA(),r.qZA(),r.TgZ(106,"ion-footer",55),r.TgZ(107,"div",56),r.TgZ(108,"button",57),r.NdJ("click",function(){return e.close()}),r._uU(109,"Cancelar"),r.qZA(),r.TgZ(110,"button",58),r.NdJ("click",function(){return e.save()}),r._uU(111,"Gravar"),r.qZA(),r.qZA(),r.qZA()),2&t){let t,n,o,i,a;r.xp6(11),r.ekj("input-error",(null==e.Form||null==(t=e.Form.get("Subject"))?null:t.invalid)&&e.validateFrom),r.xp6(1),r.Q6J("ngModel",e.postEvent.Subject),r.xp6(1),r.Q6J("ngIf",e.Form&&e.validateFrom),r.xp6(5),r.ekj("input-error",(null==e.Form||null==(n=e.Form.get("Location"))?null:n.invalid)&&e.validateFrom),r.xp6(1),r.Q6J("ngModel",e.postEvent.Location),r.xp6(1),r.Q6J("ngIf",e.Form&&e.validateFrom),r.xp6(6),r.s9C("selectedText",e.postEvent.CalendarName),r.Q6J("ngModel",e.postEvent.CalendarName),r.xp6(5),r.Q6J("ngIf",e.Form&&e.validateFrom),r.xp6(5),r.ekj("input-error",(null==e.Form||null==(o=e.Form.get("Categories"))?null:o.invalid)&&e.validateFrom),r.xp6(1),r.s9C("selectedText",e.postEvent.Category),r.Q6J("ngModel",e.postEvent.Category),r.xp6(9),r.Q6J("ngIf",e.Form&&e.validateFrom),r.xp6(5),r.ekj("input-error",(null==e.Form||null==(i=e.Form.get("Date"))?null:i.invalid)&&e.validateFrom),r.xp6(1),r.s9C("min",e.minDate),r.Q6J("ngModel",e.postEvent.StartDate),r.xp6(5),r.ekj("input-error",(null==e.Form||null==(a=e.Form.get("Date"))?null:a.invalid)&&e.validateFrom),r.xp6(1),r.s9C("min",e.minDate),r.Q6J("ngModel",e.postEvent.EndDate),r.xp6(6),r.Q6J("ngModel",e.selectedRecurringType),r.xp6(1),r.Q6J("ngForOf",e.recurringTypes),r.xp6(1),r.Q6J("ngIf","-1"!=e.selectedRecurringType),r.xp6(9),r.Q6J("ngIf",(null==e.taskParticipants?null:e.taskParticipants.length)<1),r.xp6(1),r.Q6J("ngForOf",e.taskParticipants),r.xp6(11),r.Q6J("ngIf",(null==e.taskParticipantsCc?null:e.taskParticipantsCc.length)<1),r.xp6(1),r.Q6J("ngForOf",e.taskParticipantsCc),r.xp6(8),r.Q6J("ngModel",e.postEvent.Body.Text),r.xp6(8),r.Q6J("ngForOf",e.loadedEventAttachments),r.xp6(1),r.Q6J("ngIf",e.showAttendees)}},directives:[d.W2,d.Gu,d.Q$,d.td,d.pK,d.j9,i.JJ,i.On,h.O5,d.gu,d.t9,d.QI,i.Q7,d.n0,d.x4,h.sg,d.Ie,d.q_,d.g2,d.fr,m.Y],styles:[".header-md[_ngcontent-%COMP%]:after, .title-content[_ngcontent-%COMP%]:after{display:none}.content[_ngcontent-%COMP%]{margin:0;float:left;border-left:1px solid #d8d8d8!important}.main-header[_ngcontent-%COMP%]{font-family:Roboto;background-color:#fff;overflow:hidden;transform:translate3d(0,1px,0)}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%]{margin:0 auto;padding:0!important;background:#fff}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .middle[_ngcontent-%COMP%]{padding:0!important;float:left}.main-header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:25px}.ion-item-container[_ngcontent-%COMP%]{margin:15px auto;border:1px solid #ebebeb;border-radius:5px;padding-left:10px}.ion-item-container-no-border[_ngcontent-%COMP%]{width:100%;margin:0 auto;padding:0!important}.container-div[_ngcontent-%COMP%]{margin-bottom:15px;float:left}.ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto}.ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}ion-select[_ngcontent-%COMP%]{padding-left:5px;margin-left:0}.ion-input-class[_ngcontent-%COMP%]{height:45px;padding-left:5px;padding-right:10px;float:left}.ion-input-class[_ngcontent-%COMP%], .ion-input-class-no-height[_ngcontent-%COMP%]{width:calc(100% - 45px);border:1px solid #ebebeb;border-radius:5px}.list-people[_ngcontent-%COMP%]{float:left}.add-people[_ngcontent-%COMP%]{width:45px;float:right;overflow:auto;font-size:25px;padding:10px}.list-people-title[_ngcontent-%COMP%]{color:#a3a3a3}.attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.container-footer[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.button-cancel[_ngcontent-%COMP%]{--background:#e0e9ee;--color:#061b52}.button-cancel[_ngcontent-%COMP%], .button-save[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;margin:10px}.button-save[_ngcontent-%COMP%]{--background:#42b9fe;--color:#fff}.text-input[_ngcontent-%COMP%]{width:100%;border:1px solid #ebebeb;margin:0 15px 15px 0;padding:0!important;border-radius:5px}.error[_ngcontent-%COMP%]{font-size:12px;font-weight:700;padding-bottom:20px}.error[_ngcontent-%COMP%], .span-color[_ngcontent-%COMP%]{color:red}.buttons[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:20px;overflow:auto}.app-name[_ngcontent-%COMP%]{background:#42b9f2;border-radius:18px;text-align:center;display:flex;align-items:center;padding:0 5px;color:#fff;font-size:9pt;font-weight:500;height:19px;-webkit-border-radius:18px;-moz-border-radius:18px;-ms-border-radius:18px;-o-border-radius:18px}.close-button[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .app-name[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .close-button[_ngcontent-%COMP%]{display:block!important}"]}),t})()},75008:function(t,e,n){"use strict";n.d(e,{u:function(){return A}});var o=n(64762),i=n(18119),a=n(97049),s=n(23066),c=n(97047),r=n(37716),d=n(35957),l=n(80106),p=n(20985),g=n(53760),u=n(28621),h=n(39895),m=n(84465),f=n(38583);function v(t,e){1&t&&(r.TgZ(0,"p"),r._uU(1,"(N\xe3o se repete)"),r.qZA())}function Z(t,e){1&t&&(r.TgZ(0,"p"),r._uU(1,"Repete"),r.qZA())}function x(t,e){if(1&t&&(r.TgZ(0,"div"),r.TgZ(1,"p"),r._uU(2),r.qZA(),r.qZA()),2&t){const t=e.$implicit;r.xp6(2),r.Oqu(t.Name)}}function C(t,e){if(1&t&&(r.TgZ(0,"div"),r.TgZ(1,"h5"),r._uU(2,"Intervenientes"),r.qZA(),r.TgZ(3,"ion-item",30),r.TgZ(4,"ion-label"),r.YNc(5,x,3,1,"div",31),r.qZA(),r.qZA(),r.qZA()),2&t){const t=r.oxw();r.xp6(5),r.Q6J("ngForOf",t.loadedEvent.Attendees)}}function M(t,e){if(1&t&&(r.TgZ(0,"div"),r.TgZ(1,"h5"),r._uU(2,"Detalhes"),r.qZA(),r.TgZ(3,"ion-item",32),r._UZ(4,"div",33),r.qZA(),r._UZ(5,"div",22),r.qZA()),2&t){const t=r.oxw();r.xp6(4),r.Q6J("innerHTML",t.loadedEvent.Body.Text,r.oJD)}}function b(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"ion-item",30),r.TgZ(1,"ion-label",37),r.TgZ(2,"p",38),r.NdJ("click",function(){const e=r.CHM(t).$implicit;return r.oxw(2).viewDocument(e.SourceId)}),r.TgZ(3,"span",39),r._uU(4),r.qZA(),r.TgZ(5,"span",40),r._uU(6),r.qZA(),r.qZA(),r.TgZ(7,"div",41),r.TgZ(8,"span",42),r._uU(9),r.ALo(10,"date"),r.qZA(),r.qZA(),r.TgZ(11,"div",43),r.NdJ("click",function(){const e=r.CHM(t).index,n=r.oxw(2);return n.docIndex(e),n.openTaskOptions()}),r._UZ(12,"ion-icon",44),r.qZA(),r.qZA(),r.qZA()}if(2&t){const t=e.$implicit;r.xp6(4),r.Oqu(t.SourceName),r.xp6(2),r.Oqu(t.Stakeholders),r.xp6(3),r.Oqu(r.xi3(10,3,t.CreateDate,"dd-MM-yyyy HH:mm"))}}function P(t,e){if(1&t&&(r.TgZ(0,"div",34),r.TgZ(1,"h5"),r._uU(2,"Documentos Anexados"),r.qZA(),r.TgZ(3,"ion-list",35),r.YNc(4,b,13,6,"ion-item",36),r.qZA(),r.qZA()),2&t){const t=r.oxw();r.xp6(4),r.Q6J("ngForOf",t.loadedAttachments)}}let A=(()=>{class t{constructor(t,e,n,o,a,s,c,r,d,l,p){this.modalController=t,this.eventsService=e,this.attachmentsService=n,this.alertController=o,this.iab=a,this.processes=s,this.popoverController=c,this.activatedRoute=r,this.router=d,this.toastService=l,this.location=p,this.months=["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],this.days=["Domingo","Segunda-feira","Ter\xe7a-feira","Quarta-feira","Quinta-feira","Sexta-feira","S\xe1bado"],this.dicIndex=0,this.isModal=!1,this.isEventEdited=!1,this.loadedEvent=new i.j,this.eventBody={BodyType:"1",Text:""},this.loadedEvent.Body=this.eventBody,this.activatedRoute.paramMap.subscribe(t=>{this.eventId=t.params.eventId,t.params.caller&&(this.caller=t.params.caller),t.params.isModal&&(this.isModal=t.params.isModal)})}ngOnInit(){this.loadEvent(),this.getAttachments(),window.onresize=t=>{window.innerWidth>=1024&&this.modalController.dismiss(this.isEventEdited)}}close(){this.modalController.dismiss(this.isEventEdited)}goBack(){this.isModal?this.close():this.activatedRoute.paramMap.subscribe(t=>{"expediente"==t.params.caller?window.history.back():this.router.navigate(["/home",t.params.caller])})}loadEvent(){const t=this.toastService.loading();this.eventsService.getEvent(this.eventId).subscribe(e=>{this.loadedEvent=e,t.remove()},e=>{this.toastService.badRequest(0==e.status?"n\xe3o \xe9 poss\xedvel vizualizar este event no modo offline":"Este evento j\xe1 n\xe3o existe na sua agenda"),t.remove(),this.modalController.dismiss("Eevent not Foud"),this.location.back()})}deleteEvent(){this.eventsService.deleteEvent(this.loadedEvent.EventId,0).subscribe(()=>(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.alertController.create({cssClass:"my-custom-class",header:"Evento removido",buttons:["OK"]});setTimeout(()=>{t.dismiss()},1500),this.goBack(),this.toastService.successMessage("Evento apagado")}))}OpenDeleteEventModal(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:c.L,componentProps:{eventId:this.loadedEvent.EventId,caller:this.caller},cssClass:"discart-expedient-modal"});yield t.present(),t.onDidDismiss().then(t=>{console.log(t),t&&(setTimeout(()=>{this.loadEvent(),this.getAttachments()},250),this.isEventEdited=!0)})})}getAttachments(){const t=this.toastService.loading();try{this.attachmentsService.getAttachmentsById(this.eventId).subscribe(t=>{this.loadedAttachments=t,console.log(t)})}catch(e){}finally{t.remove()}}editEventDetail(){return(0,o.mG)(this,void 0,void 0,function*(){console.log(this.caller);const t=yield this.modalController.create({component:a.f,componentProps:{eventId:this.loadedEvent.EventId,caller:this.caller},cssClass:"modal modal-desktop"});yield t.present(),t.onDidDismiss().then(t=>{console.log(t),t&&(setTimeout(()=>{this.loadEvent(),this.getAttachments()},250),this.isEventEdited=!0)})})}editEvent(){return(0,o.mG)(this,void 0,void 0,function*(){let t;console.log(this.loadedEvent),t=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const e=yield this.modalController.create({component:a.f,componentProps:{event:this.loadedEvent,caller:this.caller},cssClass:t});yield e.present(),e.onDidDismiss().then(t=>{console.log(t),t&&(setTimeout(()=>{this.loadEvent(),this.getAttachments()},250),this.isEventEdited=!0)})})}viewDocument(t){this.processes.GetDocumentUrl(t,"8").subscribe(t=>{const e=t.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");this.iab.create(e,"_blank").show()})}openTaskOptions(){return(0,o.mG)(this,void 0,void 0,function*(){const t=this.loadedAttachments[this.dicIndex];let e={serialNumber:t.SourceId,taskStartDate:t.CreateDate,isEvent:!0,workflowInstanceDataFields:{FsId:t.ApplicationId,FolderID:null,DocId:t.SourceId,Subject:t.SourceName}};const n=yield this.popoverController.create({component:s.M,cssClass:"exp-options",componentProps:{fulltask:e,task:e},translucent:!0});return yield n.present()})}docIndex(t){this.dicIndex=t}}return t.\u0275fac=function(e){return new(e||t)(r.Y36(d.IN),r.Y36(l.n),r.Y36(p.o),r.Y36(d.Br),r.Y36(g.i),r.Y36(u.$),r.Y36(d.Dh),r.Y36(h.gz),r.Y36(h.F0),r.Y36(m.k),r.Y36(f.Ye))},t.\u0275cmp=r.Xpm({type:t,selectors:[["app-view-event"]],decls:49,vars:20,consts:[[1,"ion-no-border"],[1,"main-content-l","height-100","white"],[1,"main-content","d-flex","height-100",3,"className"],[1,"content","d-flex","flex-column","width-100"],[1,"main-header","d-flex"],[1,"title-content","d-flex","justify-between","width-100"],[1,"left"],[1,"btn-no-color","d-flex","align-center",3,"click"],["slot","end","src","assets/images/icons-arrow-arrow-left.svg"],[1,"middle"],[1,"title"],[1,"menu-options","d-flex"],[1,"btn-no-color",3,"click"],["slot","end","src","assets/images/icons-edit.svg",1,"edit"],["name","trash-sharp",1,"delete"],[1,"overflow-y-auto"],[1,"upper-content","ml-45"],[1,"content-location"],[1,"date"],[1,"label"],[1,"content-details"],[4,"ngIf"],[1,"line"],[1,"middle-content"],["class","bottom-content width-100",4,"ngIf"],[1,"aside-right","flex-column","height-100"],[1,"buttons"],["full","","shape","round",1,"btn-ok",3,"click"],[1,"solid"],["full","","shape","round",1,"btn-delete",3,"click"],[1,"ion-no-margin","ion-no-padding"],[4,"ngFor","ngForOf"],["lines","none",1,"ion-no-margin","ion-no-padding"],["disabled","","rows","6",1,"width-100",3,"innerHTML"],[1,"bottom-content","width-100"],[1,"width-100"],["class","width-100","class","ion-no-margin ion-no-padding",4,"ngFor","ngForOf"],[1,"width-100","d-flex"],[1,"flex-grow-1",3,"click"],[1,"attach-title-item","d-block"],[1,"span-left","d-block"],[1,"d-flex","pr-10"],[1,"span-right"],["autoHide","false",1,"cursor-pointer",2,"width","35px","height","41px",3,"click"],["src","assets/images/icons-menu.svg"]],template:function(t,e){1&t&&(r.TgZ(0,"ion-header",0),r._UZ(1,"app-header"),r.qZA(),r.TgZ(2,"ion-content",1),r.TgZ(3,"div",2),r.TgZ(4,"div",3),r.TgZ(5,"div",4),r.TgZ(6,"div",5),r.TgZ(7,"div",6),r.TgZ(8,"button",7),r.NdJ("click",function(){return e.goBack()}),r._UZ(9,"ion-icon",8),r.qZA(),r.qZA(),r.TgZ(10,"div",9),r.TgZ(11,"p",10),r.TgZ(12,"span"),r._uU(13),r.qZA(),r.qZA(),r.qZA(),r.TgZ(14,"div",11),r.TgZ(15,"button",12),r.NdJ("click",function(){return e.editEvent()}),r._UZ(16,"ion-icon",13),r.qZA(),r.TgZ(17,"button",12),r.NdJ("click",function(){return e.deleteEvent()}),r._UZ(18,"ion-icon",14),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(19,"div",15),r.TgZ(20,"div",16),r.TgZ(21,"div",17),r.TgZ(22,"p"),r.TgZ(23,"span",18),r._uU(24),r.qZA(),r.TgZ(25,"span",19),r._uU(26),r.qZA(),r.qZA(),r.qZA(),r.TgZ(27,"div",20),r.TgZ(28,"ion-label"),r.TgZ(29,"p"),r._uU(30),r.qZA(),r.TgZ(31,"p"),r._uU(32),r.ALo(33,"date"),r.ALo(34,"date"),r.qZA(),r.YNc(35,v,2,0,"p",21),r.YNc(36,Z,2,0,"p",21),r.qZA(),r.qZA(),r.qZA(),r._UZ(37,"div",22),r.TgZ(38,"div",23),r.YNc(39,C,6,1,"div",21),r.YNc(40,M,6,1,"div",21),r.qZA(),r.YNc(41,P,5,1,"div",24),r.qZA(),r.qZA(),r.TgZ(42,"div",25),r.TgZ(43,"div",26),r.TgZ(44,"button",27),r.NdJ("click",function(){return e.editEvent()}),r._uU(45,"Editar"),r.qZA(),r._UZ(46,"div",28),r.TgZ(47,"button",29),r.NdJ("click",function(){return e.deleteEvent()}),r._uU(48,"Eliminar"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA()),2&t&&(r.ekj("d-md-none",e.isModal),r.xp6(3),r.Q6J("className",e.isModal?"_main-content d-flex height-100 ma-0 px-20 pt-30 pb-20 background-white":"main-content d-flex height-100"),r.xp6(10),r.Oqu(e.loadedEvent.Subject),r.xp6(11),r.Oqu(e.loadedEvent.Location),r.xp6(2),r.Oqu(e.loadedEvent.CalendarName),r.xp6(4),r.Oqu(e.customDate),r.xp6(2),r.AsE("das ",r.xi3(33,14,e.loadedEvent.StartDate,"HH:mm")," \xe0s ",r.xi3(34,17,e.loadedEvent.EndDate,"HH:mm"),""),r.xp6(3),r.Q6J("ngIf",!e.loadedEvent.IsRecurring),r.xp6(1),r.Q6J("ngIf",e.loadedEvent.IsRecurring),r.xp6(3),r.Q6J("ngIf",e.loadedEvent.Attendees),r.xp6(1),r.Q6J("ngIf",e.loadedEvent.Body.Text),r.xp6(1),r.Q6J("ngIf",e.loadedAttachments))},styles:["ion-content[_ngcontent-%COMP%]{--background:transparent;overflow:auto}ion-menu[_ngcontent-%COMP%]{--height:225px}.header-toolbar[_ngcontent-%COMP%]{--background:transparent;--opacity:1}.main-header[_ngcontent-%COMP%]{width:100%;font-family:Roboto;background-color:#fff;color:#000;transform:translate3d(0,1px,0)}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%]{width:100%!important;margin:0 auto;padding:0!important;background:#fff;overflow:auto}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{width:37px;float:left;font-size:35px}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .middle[_ngcontent-%COMP%]{width:calc(100% - 138.5px)!important;padding:0!important;float:left;margin:0!important;overflow:auto}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .middle[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0!important}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .header-icon-right[_ngcontent-%COMP%]{width:45px;font-size:45px;float:right}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .menu-options[_ngcontent-%COMP%]{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;align-items:flex-start;justify-content:flex-start;float:right;padding:1px;margin-left:15px}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .menu-options[_ngcontent-%COMP%] .edit[_ngcontent-%COMP%]{font-size:35px;float:left}.main-header[_ngcontent-%COMP%] .title-content[_ngcontent-%COMP%] .menu-options[_ngcontent-%COMP%] .delete[_ngcontent-%COMP%]{padding:7px;font-size:21px;color:#fff;background:#d30606;border-radius:20px;margin-left:10px}.main-header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:25px}.main-content[_ngcontent-%COMP%]{width:100%;font-family:Roboto;background-color:#fff!important;border-top-left-radius:25px;border-top-right-radius:25px;overflow:auto}.main-content[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:30px 20px 0!important;margin:0;float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%]{width:calc(100%-50px);margin-left:50px;overflow:auto;font-size:18px}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .content-location[_ngcontent-%COMP%]{width:100%;margin:0 auto;padding:0;overflow:auto}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .content-location[_ngcontent-%COMP%] .date[_ngcontent-%COMP%]{width:calc(100% - 105px);float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .content-location[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{border-radius:20px;background:#ffb703;float:right;padding:5px 13.5px;color:#fff}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .location-detail[_ngcontent-%COMP%]{width:210px;font-weight:700;font-size:18px;float:left;margin:5px 5px 5px 0}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-mdgpr-Oficial[_ngcontent-%COMP%]{width:91px;--border-radius:20px;--background:#ffb703;margin-left:5px;float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-mdgpr-Pessoal[_ngcontent-%COMP%]{width:91px;--border-radius:20px;--background:#f05d5e;margin-left:5px;float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-pr-Oficial[_ngcontent-%COMP%]{width:91px;--border-radius:20px;--background:#cbeecb;margin-left:5px;float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-pr-Pessoal[_ngcontent-%COMP%]{width:91px;--border-radius:20px;--background:#cab0dc;margin-left:5px;float:left}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-calendar-type[_ngcontent-%COMP%] ion-button[_ngcontent-%COMP%]{height:25px}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .button-edit-event[_ngcontent-%COMP%]{width:140px;height:44px;border-radius:22.5px;--background:#e0e9ee;--color:#061b52}.main-content[_ngcontent-%COMP%] .upper-content[_ngcontent-%COMP%] .content-details[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:16px}.main-content[_ngcontent-%COMP%] .line[_ngcontent-%COMP%]{width:100%!important;margin-top:15px;border-top:1px solid #d8d8d8}.main-content[_ngcontent-%COMP%] .middle-conten[_ngcontent-%COMP%]{width:100%!important;overflow:auto}.main-content[_ngcontent-%COMP%] .middle-conten[_ngcontent-%COMP%] .middle-content[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .main-content[_ngcontent-%COMP%] .middle-conten[_ngcontent-%COMP%] .middle-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:16px}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%]{margin:0 auto}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:16px;margin:0 0 0 10px}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.main-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.aside-right[_ngcontent-%COMP%]{padding:30px 20px 0!important}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;margin-bottom:20px}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%] .arrow-right-icon[_ngcontent-%COMP%]{width:37px;float:right;font-size:35px}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:space-between}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-cancel[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-delete[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-ok[_ngcontent-%COMP%]{height:auto!important;font-size:16px!important;font-weight:600!important;width:100%!important;margin-bottom:10px!important;padding:15px!important}.aside-right[_ngcontent-%COMP%] .solid[_ngcontent-%COMP%]{display:block;width:90%;border-top:1px solid #ebebeb;margin:0 auto 10px!important}textarea[_ngcontent-%COMP%]{border:none;--background:#fff!important}@media only screen and (max-width: 800px){.content[_ngcontent-%COMP%]{width:100%!important}.aside-right[_ngcontent-%COMP%]{display:none}}@media only screen and (min-width: 801px){.menu-options[_ngcontent-%COMP%]{display:none!important}.content[_ngcontent-%COMP%]{width:65%;border-right:1px solid #d8d8d8}.aside-right[_ngcontent-%COMP%]{width:35%}}@media only screen and (min-width: 1024px){.content[_ngcontent-%COMP%]{width:70%}.aside-right[_ngcontent-%COMP%]{width:30%}}@media only screen and (min-width: 1140px){.content[_ngcontent-%COMP%]{width:75%}.aside-right[_ngcontent-%COMP%]{width:25%}}"]}),t})()},83189:function(t,e,n){"use strict";n.d(e,{k:function(){return H}});var o=n(64762),i=n(18119),a=n(45896),s=n(4528),c=n(55199),r=n(3679),d=n(16738),l=n(25653),p=n(37716),g=n(35957),u=n(39895),h=n(28621),m=n(20985),f=n(80106),v=n(37556),Z=n(84465),x=n(38583),C=n(98295),M=n(67441),b=n(72458),P=n(49983),A=n(43220),w=n(1491),T=n(17352);const _=["picker"],O=["fim"],q=["inicio"],k=["picker1"];function y(t,e){1&t&&(p.TgZ(0,"div"),p._uU(1," Campo obrigat\xf3rio. "),p.qZA())}function D(t,e){1&t&&(p.TgZ(0,"div"),p._uU(1," O campo deve ter pelo menos 4 caracteres. "),p.qZA())}function I(t,e){if(1&t&&(p.TgZ(0,"div",71),p.YNc(1,y,2,0,"div",7),p.YNc(2,D,2,0,"div",7),p.qZA()),2&t){const t=p.oxw(2);p.xp6(1),p.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.required),p.xp6(1),p.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.minlength)}}function S(t,e){if(1&t&&(p.TgZ(0,"div"),p.YNc(1,I,3,2,"div",70),p.qZA()),2&t){const t=p.oxw();p.xp6(1),p.Q6J("ngIf",t.Form.get("Subject").invalid)}}function N(t,e){if(1&t&&(p.TgZ(0,"mat-option",72),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.s9C("value",t.Code),p.xp6(1),p.hij(" ",t.Description," ")}}function F(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"div",8),p.TgZ(1,"div",41),p.TgZ(2,"div",10),p._UZ(3,"ion-icon",16),p.qZA(),p.TgZ(4,"div",73),p.NdJ("click",function(){return p.CHM(t),p.oxw().openLastOccurrence()}),p.TgZ(5,"mat-form-field",74),p.TgZ(6,"input",75),p.NdJ("ngModelChange",function(e){return p.CHM(t),p.oxw().Occurrence=e}),p.qZA(),p._UZ(7,"mat-datepicker-toggle",76),p._UZ(8,"ngx-mat-datetime-picker",33,77),p.qZA(),p.qZA(),p.qZA(),p.qZA()}if(2&t){const t=p.MAs(9),e=p.oxw();p.xp6(6),p.Q6J("ngxMatDatetimePicker",t)("ngModel",e.Occurrence)("disabled",e.disabled),p.xp6(1),p.Q6J("for",t),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi)}}function U(t,e){1&t&&(p.TgZ(0,"ion-label",78),p._uU(1,"Adicionar intervenientes*"),p.qZA())}function E(t,e){if(1&t&&(p.TgZ(0,"ion-label"),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.xp6(1),p.Oqu(t.Name)}}function J(t,e){1&t&&(p.TgZ(0,"ion-label",78),p._uU(1,"Com conhecimento"),p.qZA())}function Y(t,e){if(1&t&&(p.TgZ(0,"ion-label"),p._uU(1),p.qZA()),2&t){const t=e.$implicit;p.xp6(1),p.Oqu(t.Name)}}function R(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"div",79),p.TgZ(1,"ion-list"),p.TgZ(2,"ion-item"),p.TgZ(3,"ion-label"),p.TgZ(4,"p",80),p.TgZ(5,"span",81),p._uU(6),p.qZA(),p.TgZ(7,"span",82),p._uU(8),p.qZA(),p.TgZ(9,"span",83),p.NdJ("click",function(){const e=p.CHM(t).index;return p.oxw().removeAttachment(e)}),p._UZ(10,"ion-icon",84),p.qZA(),p.qZA(),p.TgZ(11,"p"),p.TgZ(12,"span",85),p._uU(13),p.qZA(),p.TgZ(14,"span",86),p._uU(15),p.ALo(16,"date"),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA()}if(2&t){const t=e.$implicit;p.xp6(6),p.Oqu(t.Assunto),p.xp6(2),p.Oqu(t.appName),p.xp6(5),p.Oqu(t.EntidadeOrganicaNome),p.xp6(2),p.hij(" ",p.xi3(16,4,t.Data,"dd-MM-yyyy HH:mm")," ")}}function Q(t,e){if(1&t&&p._UZ(0,"app-empty-container",87),2&t){const t=p.oxw();p.Q6J("texto",t.emptyTextDescription)}}function L(t,e){if(1&t){const t=p.EpF();p.TgZ(0,"app-attendee-modal",88),p.NdJ("dynamicSetIntervenient",function(e){return p.CHM(t),p.oxw().dynamicSetIntervenient(e)}),p.qZA()}if(2&t){const t=p.oxw();p.Q6J("footer",!1)("taskParticipants",t.taskParticipants)("taskParticipantsCc",t.taskParticipantsCc)("adding",t.adding)}}const z=d||d,j={parse:{dateInput:"YYYY-MMMM-DD HH:mm"},display:{dateInput:"DD MMM YYYY H:mm",monthYearLabel:"MMM YYYY",dateA11yLabel:"LL",monthYearA11yLabel:"MMMM YYYY"}};let H=(()=>{class t{constructor(t,e,n,o,a,s,c,d,l,p){this.modalController=t,this.router=e,this.navParams=n,this.processes=o,this.attachmentsService=a,this.calendarService=s,this.animationController=d,this.toastService=l,this.activatedRoute=p,this.disabled=!1,this.showSpinners=!0,this.showSeconds=!1,this.touchUi=!1,this.enableMeridian=!1,this.minDate=new Date,this.ionicMinDate=(new Date).toISOString().slice(0,10),this.endMinDate=new Date((new Date).getTime()+9e5),this.stepHour=1,this.stepMinute=5,this.stepSecond=5,this.dateControlStart=new r.NI(z("DD MM YYYY hh")),this.dateControlEnd=new r.NI(z("DD MM YYYY hh")),this.validateFrom=!1,this.recurringTypes=[],this.Occurrence=new Date,this.EventRecurrenceType="-1",this.showLoader=!1,this.taskParticipantsCc=[],this.documents=[],this.adding="intervenient",this.formLocationSatus=!1,this.showAttendees=!1,this.emptyTextDescription="Sem intervenientes selecionados",this.taskParticipants=[],this.loggeduser=c.ValidatedUser,this.task=this.navParams.get("task"),console.log(this.task),this.postData=new i.j,this.eventBody={BodyType:"1",Text:""},this.postData.Body=this.eventBody,this.postData.Subject=this.task.Folio,this.postData.CalendarName="Oficial",this.dateControlStart=new r.NI(z(new Date)),this.dateControlEnd=new r.NI(z(new Date((new Date).getTime()+9e5))),this.postData.Category="Reuni\xe3o"}get dateStart(){return window.innerWidth<801?this.postData.StartDate:this.dateControlStart.value}get dateEnd(){return window.innerWidth<801?this.postData.EndDate:this.dateControlEnd.value}ngOnInit(){this.adding="intervenient",console.log(this.task),this.getAttachments(),this.setDefaultTime(),this.getRecurrenceTypes()}getRecurrenceTypes(){this.calendarService.getRecurrenceTypes().subscribe(t=>{this.recurringTypes=t})}setDefaultTime(){this.postData.StartDate=new Date,this.postData.EndDate=new Date((new Date).getTime()+9e5)}getAttachments(){this.attachmentsService.getAttachmentsBySerial(this.task.SerialNumber).subscribe(t=>{this.loadedAttachments=t})}close(){this.modalController.dismiss(null)}goBack(){this.modalController.dismiss(null),window.history.back()}runValidation(){this.validateFrom=!0}get dateValid(){return window.innerWidth<=800?this.postData.StartDate<this.postData.EndDate?["ok"]:[]:["ok"]}injectValidation(){this.Form=new r.cw({Subject:new r.NI(this.postData.Subject,[r.kI.required]),Location:new r.NI(this.postData.Location,[r.kI.required]),CalendarName:new r.NI(this.postData.CalendarName,[r.kI.required]),Date:new r.NI(this.dateValid,[r.kI.required]),participantes:new r.NI(this.taskParticipants,[r.kI.required]),Categories:new r.NI(this.postData.Category,[r.kI.required])})}saveTask(){return(0,o.mG)(this,void 0,void 0,function*(){if("MDGPR"==this.loggeduser.Profile&&(this.injectValidation(),this.runValidation(),this.Form.invalid))return!1;let t=this.taskParticipants.concat(this.taskParticipantsCc);if(this.eventBody={BodyType:"1",Text:this.postData.Body.Text},this.postData={EventId:"",Subject:this.postData.Subject,Body:this.eventBody,Location:this.postData.Location,CalendarId:"",CalendarName:this.postData.CalendarName,StartDate:this.dateStart,EndDate:this.dateEnd,EventType:"Reuni\xe3o",Attendees:t,IsMeeting:!1,IsRecurring:!1,AppointmentState:0,TimeZone:"UTC",Organizer:null,Category:"Reuni\xe3o",HasAttachments:!0,EventRecurrence:{Type:this.EventRecurrenceType,LastOccurrence:this.Occurrence}},console.log(this.postData),"8"==this.task.FsId){const t=this.toastService.loading();try{switch(this.loggeduser.Profile){case"MDGPR":yield this.calendarService.postExpedientEvent(this.task.DocId,this.postData,"md",this.task.SerialNumber,this.task.FsId).toPromise();break;case"PR":yield this.calendarService.postExpedientEvent(this.task.DocId,this.postData,"pr",this.task.SerialNumber,this.task.FsId).toPromise()}this.modalController.dismiss(),this.toastService.successMessage("Reuni\xe3o criada")}catch(e){this.toastService.badRequest("Reuni\xe3o n\xe3o criada")}finally{t.remove()}}else if("361"==this.task.FsId){const t=this.toastService.loading();try{switch(this.loggeduser.Profile){case"MDGPR":yield this.calendarService.createTaskEvent(this.task.FolderId,this.postData,"md",this.task.SerialNumber,this.task.FsId).toPromise();break;case"PR":yield this.calendarService.createTaskEvent(this.task.FolderId,this.postData,"pr",this.task.SerialNumber,this.task.FsId).toPromise()}this.close(),this.toastService.successMessage("Reuni\xe3o criada")}catch(e){this.toastService.badRequest()}finally{t.remove()}}})}addParticipants(){return(0,o.mG)(this,void 0,void 0,function*(){if(this.adding="intervenient",window.innerWidth<=801){const t=yield this.modalController.create({component:c.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"modal modal-desktop",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}else this.showAttendees=!0})}openLastOccurrence(){let t=document.querySelector("#last-occurrence");t&&t.click()}addParticipantsCc(){return(0,o.mG)(this,void 0,void 0,function*(){if(this.adding="CC",window.innerWidth<=800){const t=yield this.modalController.create({component:c.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"modal modal-desktop",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}else this.showAttendees=!0})}distartExpedientModal(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:a.Q,componentProps:{serialNumber:this.task.SerialNumber},cssClass:"discart-expedient-modal",backdropDismiss:!1});yield t.present(),t.onDidDismiss()})}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:s.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>{t&&this.documents.push(t.data.selected)})})}removeAttachment(t){this.documents=this.documents.filter((e,n)=>t!=n)}validateFormInputs(){let t=this.postData.Location.trim();!this.postData.Location&&t.length<=0&&(this.formLocationSatus=!0)}dynamicSetIntervenient({taskParticipants:t,taskParticipantsCc:e}){this.taskParticipants=t,this.taskParticipantsCc=e}goToGabinete(){this.router.navigate(["/home/gabinete-digital"])}setIntervenient(t){this.taskParticipants=t}setIntervenientCC(t){this.taskParticipantsCc=t}}return t.\u0275fac=function(e){return new(e||t)(p.Y36(g.IN),p.Y36(u.F0),p.Y36(g.X1),p.Y36(h.$),p.Y36(m.o),p.Y36(f.n),p.Y36(v.e),p.Y36(g.vB),p.Y36(Z.k),p.Y36(u.gz))},t.\u0275cmp=p.Xpm({type:t,selectors:[["app-book-meeting-modal"]],viewQuery:function(t,e){if(1&t&&(p.Gf(_,5),p.Gf(O,5),p.Gf(q,5),p.Gf(k,5)),2&t){let t;p.iGM(t=p.CRH())&&(e.picker=t.first),p.iGM(t=p.CRH())&&(e.fim=t.first),p.iGM(t=p.CRH())&&(e.inicio=t.first),p.iGM(t=p.CRH())&&(e.picker1=t.first)}},features:[p._Bn([{provide:l.ab,useValue:j}])],decls:135,vars:58,consts:[[1,"main-content","d-flex","height-100"],[1,"content","d-flex","flex-column","width-100","height-100"],[1,"header-content","header-default-padding"],[1,"header-title"],[1,"overflow-y-auto","content-default-padding"],[1,"ion-item-container","width-100"],["placeholder","Assunto*",3,"ngModel","ngModelChange"],[4,"ngIf"],[1,"container-div","width-100"],[1,"ion-item-class-2","width-100"],[1,"ion-icon-class"],["slot","start","src","assets/images/icons-location.svg"],[1,"ion-input-class"],["placeholder","Localiza\xe7\xe3o*",3,"ngModel","ngModelChange"],[1,"container-div"],[1,"ion-item-class-2"],["slot","start","src","assets/images/icons-calendar.svg"],["placeholder","Selecione repeti\xe7\xe3o","interface","action-sheet","Cancel-text","Cancelar","required","",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["value","Oficial"],["value","Pessoal"],["floatLabel","never","appearance","none",1,"d-none","d-md-block","width-100"],["placeholder","Selecione agenda",3,"ngModel","ngModelChange"],["placeholder","Selecione tipo de evento*","interface","action-sheet","Cancel-text","Cancelar","required","",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["value","Reuni\xe3o"],["value","Viagem"],["value","Confer\xeancia"],["value","Encontro"],["appearance","none","placeholder","Sample Type","required","",1,"width-100"],[3,"ngModel","ngModelChange"],["placeholder","In\xedcio*","displayFormat","D MMM YYYY H:mm","minuteValues","0,15,30,45","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","max","2025","value","2020-11-19T11:06Z",1,"d-block","d-md-none",3,"ngModel","min","ngModelChange"],["appearance","none",1,"width-100","date-hour-picker","d-md-block"],["matInput","","placeholder","Choose a date*",3,"ngxMatDatetimePicker","formControl","min","disabled"],["id","new-inicio","matSuffix","",3,"for"],[3,"showSpinners","showSeconds","stepHour","stepMinute","stepSecond","touchUi"],["picker1",""],[1,"ion-input-class","flex-grow-1"],["placeholder","Fim*","displayFormat","D MMM YYYY H:mm","minuteValues","0,15,30,45","monthShortNames","Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez","max","2025","value","2020-11-19T11:06Z",1,"d-block","d-md-none",3,"ngModel","min","ngModelChange"],["appearance","none",1,"date-hour-picker","width-100","d-none","d-md-block"],["matInput","","placeholder","Fim*",3,"ngxMatDatetimePicker","formControl","min","disabled"],["id","new-fim","matSuffix","",3,"for"],["fim",""],[1,"ion-item-class-2","d-flex"],["slot","start","src","assets/images/icons-refresh.svg"],["appearance","none","floatLabel","never","value","false","interface","action-sheet","required","",1,"width-100"],["placeholder","Selecione repeti\xe7\xe3o*",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["class","container-div width-100",4,"ngIf"],["slot","start","src","assets/images/icons-person.svg"],[1,"ion-input-class-no-height"],[1,"list-people"],["lines","none"],["class","list-people-title",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"add-people",3,"click"],["slot","start","src","assets/images/icons-arrow-forward.svg"],["slot","start","src","assets/images/icons-people-cc.svg"],["slot","start","src","assets/images/icons-description.svg"],[1,"ion-input-class-no-height","width-100"],["placeholder","Detalhes","rows","6","cols","20",3,"ngModel","ngModelChange"],[1,"ion-item-container-no-border","cursor-pointer",3,"click"],[1,"attach-icon"],["src","assets/images/icons-attach-doc.svg"],[1,"attach-document"],["class","list ",4,"ngFor","ngForOf"],[1,"aside-righ","flex-grow-1"],["class","d-flex height-100 flex-column",3,"texto",4,"ngIf"],["class"," d-flex flex-column height-100",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient",4,"ngIf"],[1,"buttons"],["shape","round",1,"btn-cancel",3,"click"],["shape","round",1,"btn-ok",3,"click"],["class","input-errror-message",4,"ngIf"],[1,"input-errror-message"],[3,"value"],[1,"ion-input-class","flex-grow-1",3,"click"],[1,"date-hour-picker"],["matInput","","placeholder","Choose a date",3,"ngxMatDatetimePicker","ngModel","disabled","ngModelChange"],["id","last-occurrence","matSuffix","",3,"for"],["occurrrence",""],[1,"list-people-title"],[1,"list"],[1,"d-flex","ion-justify-content-between"],[1,"attach-title-item"],[1,"app-name"],[1,"close-button","text-black",3,"click"],["src","assets/images/icons-delete-25.svg",1,"font-20"],[1,"span-left"],[1,"span-right"],[1,"d-flex","height-100","flex-column",3,"texto"],[1,"d-flex","flex-column","height-100",3,"footer","taskParticipants","taskParticipantsCc","adding","dynamicSetIntervenient"]],template:function(t,e){if(1&t&&(p.TgZ(0,"ion-content"),p.TgZ(1,"div",0),p.TgZ(2,"div",1),p.TgZ(3,"div",2),p.TgZ(4,"div",3),p.TgZ(5,"label"),p._uU(6,"Convocar Reuni\xe3o"),p.qZA(),p.qZA(),p.qZA(),p.TgZ(7,"div",4),p.TgZ(8,"div",5),p.TgZ(9,"ion-input",6),p.NdJ("ngModelChange",function(t){return e.postData.Subject=t}),p.qZA(),p.qZA(),p.YNc(10,S,2,1,"div",7),p.TgZ(11,"div",8),p.TgZ(12,"div",9),p.TgZ(13,"div",10),p._UZ(14,"ion-icon",11),p.qZA(),p.TgZ(15,"div",12),p.TgZ(16,"ion-input",13),p.NdJ("ngModelChange",function(t){return e.postData.Location=t}),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(17,"div",14),p.TgZ(18,"div",15),p.TgZ(19,"div",10),p._UZ(20,"ion-icon",16),p.qZA(),p.TgZ(21,"div",12),p.TgZ(22,"ion-select",17),p.NdJ("ngModelChange",function(t){return e.postData.CalendarName=t}),p.TgZ(23,"ion-select-option",18),p._uU(24,"Oficial"),p.qZA(),p.TgZ(25,"ion-select-option",19),p._uU(26,"Pessoal"),p.qZA(),p.qZA(),p.TgZ(27,"mat-form-field",20),p.TgZ(28,"mat-select",21),p.NdJ("ngModelChange",function(t){return e.postData.CalendarName=t}),p.TgZ(29,"mat-option",18),p._uU(30," Oficial "),p.qZA(),p.TgZ(31,"mat-option",19),p._uU(32," Pessoal "),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(33,"div",14),p.TgZ(34,"div",15),p.TgZ(35,"div",10),p._UZ(36,"ion-icon",16),p.qZA(),p.TgZ(37,"div",12),p.TgZ(38,"ion-select",22),p.NdJ("ngModelChange",function(t){return e.postData.Category=t}),p.TgZ(39,"ion-select-option",23),p._uU(40,"Reuni\xe3o"),p.qZA(),p.TgZ(41,"ion-select-option",24),p._uU(42,"Viagem"),p.qZA(),p.TgZ(43,"ion-select-option",25),p._uU(44,"Confer\xeancia"),p.qZA(),p.TgZ(45,"ion-select-option",26),p._uU(46,"Encontro"),p.qZA(),p.qZA(),p.TgZ(47,"mat-form-field",27),p.TgZ(48,"mat-select",28),p.NdJ("ngModelChange",function(t){return e.postData.Category=t}),p.TgZ(49,"mat-option",23),p._uU(50," Reuni\xe3o "),p.qZA(),p.TgZ(51,"mat-option",24),p._uU(52," Viagem "),p.qZA(),p.TgZ(53,"mat-option",25),p._uU(54," Confer\xeancia "),p.qZA(),p.TgZ(55,"mat-option",26),p._uU(56," Encontro "),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(57,"div",14),p.TgZ(58,"div",15),p.TgZ(59,"div",10),p._UZ(60,"ion-icon",16),p.qZA(),p.TgZ(61,"div",12),p.TgZ(62,"ion-datetime",29),p.NdJ("ngModelChange",function(t){return e.postData.StartDate=t}),p.qZA(),p.TgZ(63,"mat-form-field",30),p._UZ(64,"input",31),p._UZ(65,"mat-datepicker-toggle",32),p._UZ(66,"ngx-mat-datetime-picker",33,34),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(68,"div",14),p.TgZ(69,"div",15),p.TgZ(70,"div",10),p._UZ(71,"ion-icon",16),p.qZA(),p.TgZ(72,"div",35),p.TgZ(73,"ion-datetime",36),p.NdJ("ngModelChange",function(t){return e.postData.EndDate=t}),p.qZA(),p.TgZ(74,"mat-form-field",37),p._UZ(75,"input",38),p._UZ(76,"mat-datepicker-toggle",39),p._UZ(77,"ngx-mat-datetime-picker",33,40),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(79,"div",8),p.TgZ(80,"div",41),p.TgZ(81,"div",10),p._UZ(82,"ion-icon",42),p.qZA(),p.TgZ(83,"div",35),p.TgZ(84,"mat-form-field",43),p.TgZ(85,"mat-select",44),p.NdJ("ngModelChange",function(t){return e.EventRecurrenceType=t}),p.YNc(86,N,2,2,"mat-option",45),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.YNc(87,F,10,10,"div",46),p.TgZ(88,"div",14),p.TgZ(89,"div",15),p.TgZ(90,"div",10),p._UZ(91,"ion-icon",47),p.qZA(),p.TgZ(92,"div",48),p.TgZ(93,"div",49),p.TgZ(94,"ion-item",50),p.TgZ(95,"ion-list"),p.YNc(96,U,2,0,"ion-label",51),p.YNc(97,E,2,1,"ion-label",52),p.qZA(),p.qZA(),p.qZA(),p.TgZ(98,"div",53),p.NdJ("click",function(){return e.addParticipants()}),p._UZ(99,"ion-icon",54),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(100,"div",14),p.TgZ(101,"div",15),p.TgZ(102,"div",10),p._UZ(103,"ion-icon",55),p.qZA(),p.TgZ(104,"div",48),p.TgZ(105,"div",49),p.TgZ(106,"ion-item",50),p.TgZ(107,"ion-list"),p.YNc(108,J,2,0,"ion-label",51),p.YNc(109,Y,2,1,"ion-label",52),p.qZA(),p.qZA(),p.qZA(),p.TgZ(110,"div",53),p.NdJ("click",function(){return e.addParticipantsCc()}),p._UZ(111,"ion-icon",54),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(112,"div",14),p.TgZ(113,"div",41),p.TgZ(114,"div",10),p._UZ(115,"ion-icon",56),p.qZA(),p.TgZ(116,"div",57),p.TgZ(117,"ion-textarea",58),p.NdJ("ngModelChange",function(t){return e.postData.Body.Text=t}),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(118,"div",59),p.NdJ("click",function(){return e.getDoc()}),p.TgZ(119,"ion-label"),p.TgZ(120,"div",60),p._UZ(121,"ion-icon",61),p.qZA(),p.TgZ(122,"div",62),p.TgZ(123,"ion-label"),p._uU(124,"Anexar Documentos"),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.YNc(125,R,17,7,"div",63),p.qZA(),p.qZA(),p.TgZ(126,"div",64),p.YNc(127,Q,1,1,"app-empty-container",65),p.YNc(128,L,1,4,"app-attendee-modal",66),p.qZA(),p.qZA(),p.qZA(),p.TgZ(129,"ion-footer"),p.TgZ(130,"div",67),p.TgZ(131,"button",68),p.NdJ("click",function(){return e.close()}),p._uU(132,"Cancelar"),p.qZA(),p.TgZ(133,"button",69),p.NdJ("click",function(){return e.saveTask()}),p._uU(134,"Gravar"),p.qZA(),p.qZA(),p.qZA()),2&t){const t=p.MAs(67),n=p.MAs(78);let o,i,a,s,c,r,d;p.xp6(8),p.ekj("input-error",(null==e.Form||null==(o=e.Form.get("Subject"))?null:o.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Subject),p.xp6(1),p.Q6J("ngIf",e.Form&&e.validateFrom),p.xp6(5),p.ekj("input-error",(null==e.Form||null==(i=e.Form.get("Location"))?null:i.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Location),p.xp6(6),p.Q6J("ngModel",e.postData.CalendarName),p.xp6(6),p.Q6J("ngModel",e.postData.CalendarName),p.xp6(9),p.ekj("input-error",(null==e.Form||null==(a=e.Form.get("Categories"))?null:a.invalid)&&e.validateFrom),p.xp6(1),p.Q6J("ngModel",e.postData.Category),p.xp6(10),p.Q6J("ngModel",e.postData.Category),p.xp6(13),p.ekj("input-error",(null==e.Form||null==(s=e.Form.get("Date"))?null:s.invalid)&&e.validateFrom),p.xp6(1),p.s9C("min",e.ionicMinDate),p.Q6J("ngModel",e.postData.StartDate),p.xp6(2),p.Q6J("ngxMatDatetimePicker",t)("formControl",e.dateControlStart)("min",e.minDate)("disabled",e.disabled),p.xp6(1),p.Q6J("for",t),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi),p.xp6(6),p.ekj("input-error",(null==e.Form||null==(c=e.Form.get("Date"))?null:c.invalid)&&e.validateFrom),p.xp6(1),p.s9C("min",e.ionicMinDate),p.Q6J("ngModel",e.postData.EndDate),p.xp6(2),p.Q6J("ngxMatDatetimePicker",n)("formControl",e.dateControlEnd)("min",e.endMinDate)("disabled",e.disabled),p.xp6(1),p.Q6J("for",n),p.xp6(1),p.Q6J("showSpinners",e.showSpinners)("showSeconds",e.showSeconds)("stepHour",e.stepHour)("stepMinute",e.stepMinute)("stepSecond",e.stepSecond)("touchUi",e.touchUi),p.xp6(6),p.ekj("input-error",(null==e.Form||null==(r=e.Form.get("dateOccurrence"))?null:r.invalid)&&e.validateFrom),p.xp6(2),p.Q6J("ngModel",e.EventRecurrenceType),p.xp6(1),p.Q6J("ngForOf",e.recurringTypes),p.xp6(1),p.Q6J("ngIf","-1"!=e.EventRecurrenceType),p.xp6(5),p.ekj("input-error",(null==e.Form||null==(d=e.Form.get("participantes"))?null:d.invalid)&&e.validateFrom),p.xp6(4),p.Q6J("ngIf",(null==e.taskParticipants?null:e.taskParticipants.length)<1),p.xp6(1),p.Q6J("ngForOf",e.taskParticipants),p.xp6(11),p.Q6J("ngIf",(null==e.taskParticipantsCc?null:e.taskParticipantsCc.length)<1),p.xp6(1),p.Q6J("ngForOf",e.taskParticipantsCc),p.xp6(8),p.Q6J("ngModel",e.postData.Body.Text),p.xp6(8),p.Q6J("ngForOf",e.documents),p.xp6(2),p.Q6J("ngIf",!e.showAttendees),p.xp6(1),p.Q6J("ngIf",e.showAttendees)}},directives:[g.W2,g.pK,g.j9,r.JJ,r.On,x.O5,g.gu,g.t9,g.QI,r.Q7,g.n0,C.KE,M.gD,b.ey,g.x4,P.Nt,l.g2,r.Fj,r.oH,A.nW,C.R9,l.AB,x.sg,g.Ie,g.q_,g.g2,g.Q$,g.fr,w.M,T.Y],pipes:[x.uU],styles:[".content[_ngcontent-%COMP%]{margin:0;float:left}.content[_ngcontent-%COMP%] .header-title[_ngcontent-%COMP%]{font-family:Roboto;font-size:25px;padding:0;color:#000;float:left}.content[_ngcontent-%COMP%] .ion-item-container[_ngcontent-%COMP%]{margin:15px auto;border:1px solid #ebebeb;border-radius:5px;padding-left:10px}.content[_ngcontent-%COMP%] .ion-item-container-no-border[_ngcontent-%COMP%]{margin:0 auto;padding:0!important;overflow:auto}.content[_ngcontent-%COMP%] .container-div[_ngcontent-%COMP%]{margin-bottom:15px;overflow:hidden}.content[_ngcontent-%COMP%] .ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto}.content[_ngcontent-%COMP%] .ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}.content[_ngcontent-%COMP%] ion-select[_ngcontent-%COMP%]{padding-left:5px;margin-left:0}.content[_ngcontent-%COMP%] .ion-input-class[_ngcontent-%COMP%]{width:calc(100% - 45px);height:45px;border:1px solid #ebebeb;border-radius:5px;padding-left:5px;padding-right:10px;float:left}.content[_ngcontent-%COMP%] .ion-input-class-no-height[_ngcontent-%COMP%]{border:1px solid #ebebeb;border-radius:5px;overflow:auto}.content[_ngcontent-%COMP%] .list-people[_ngcontent-%COMP%]{width:256px;float:left}.content[_ngcontent-%COMP%] .add-people[_ngcontent-%COMP%]{width:45px;float:right;overflow:auto;font-size:25px;padding:10px}.content[_ngcontent-%COMP%] .list-people-title[_ngcontent-%COMP%]{color:#a3a3a3}.content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.content[_ngcontent-%COMP%] .attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.container-footer[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.button-cancel[_ngcontent-%COMP%]{--background:#e0e9ee;--color:#061b52}.button-cancel[_ngcontent-%COMP%], .button-save[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;margin:10px}.button-save[_ngcontent-%COMP%]{--background:#42b9fe;--color:#fff}.text-input[_ngcontent-%COMP%]{width:100%;border:1px solid #ebebeb;margin:0 15px 15px 0;padding:0!important;border-radius:5px}.error[_ngcontent-%COMP%]{font-size:12px;font-weight:700;padding-bottom:20px}.error[_ngcontent-%COMP%], .span-color[_ngcontent-%COMP%]{color:red}.buttons[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:20px;overflow:auto}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.app-name[_ngcontent-%COMP%]{background:#42b9f2;border-radius:18px;text-align:center;display:flex;align-items:center;padding:0 5px;color:#fff;font-size:9pt;font-weight:500;height:19px;-webkit-border-radius:18px;-moz-border-radius:18px;-ms-border-radius:18px;-o-border-radius:18px}.close-button[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .app-name[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .close-button[_ngcontent-%COMP%]{display:block!important}"]}),t})()},32379:function(t,e,n){"use strict";n.d(e,{F:function(){return W}});var o=n(64762),i=n(95336),a=n(45896),s=n(11055),c=n(4528),r=n(55199),d=n(3679),l=n(25653),p=n(84393),g=n(37716),u=n(35957),h=n(39895),m=n(28621),f=n(20985),v=n(25970),Z=n(37556),x=n(84465),C=n(40617),M=n(38583),b=n(98295),P=n(67441),A=n(72458),w=n(1491),T=n(17352);function _(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," Campo obrigat\xf3rio. "),g.qZA())}function O(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," O campo deve ter pelo menos 4 caracteres. "),g.qZA())}function q(t,e){if(1&t&&(g.TgZ(0,"div",48),g.YNc(1,_,2,0,"div",7),g.YNc(2,O,2,0,"div",7),g.qZA()),2&t){const t=g.oxw(2);g.xp6(1),g.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.required),g.xp6(1),g.Q6J("ngIf",null==t.Form.get("Subject").errors?null:t.Form.get("Subject").errors.minlength)}}function k(t,e){if(1&t&&(g.TgZ(0,"div"),g.YNc(1,q,3,2,"div",47),g.qZA()),2&t){const t=g.oxw();g.xp6(1),g.Q6J("ngIf",t.Form.get("Subject").invalid)}}function y(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," Campo obrigat\xf3rio. "),g.qZA())}function D(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," O campo deve ter pelo menos 4 caracteres. "),g.qZA())}function I(t,e){if(1&t&&(g.TgZ(0,"div",48),g.YNc(1,y,2,0,"div",7),g.YNc(2,D,2,0,"div",7),g.qZA()),2&t){const t=g.oxw(2);g.xp6(1),g.Q6J("ngIf",null==t.Form.get("Priority").errors?null:t.Form.get("Priority").errors.required),g.xp6(1),g.Q6J("ngIf",null==t.Form.get("Priority").errors?null:t.Form.get("Priority").errors.minlength)}}function S(t,e){if(1&t&&(g.TgZ(0,"div"),g.YNc(1,I,3,2,"div",47),g.qZA()),2&t){const t=g.oxw();g.xp6(1),g.Q6J("ngIf",t.Form.get("Priority").invalid)}}function N(t,e){if(1&t&&(g.TgZ(0,"mat-option",49),g._uU(1),g.qZA()),2&t){const t=e.$implicit;g.s9C("value",t.Code),g.xp6(1),g.Oqu(t.Description)}}function F(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," Campo obrigat\xf3rio. "),g.qZA())}function U(t,e){1&t&&(g.TgZ(0,"div"),g._uU(1," O campo deve ter pelo menos 4 caracteres. "),g.qZA())}function E(t,e){if(1&t&&(g.TgZ(0,"div",48),g.YNc(1,F,2,0,"div",7),g.YNc(2,U,2,0,"div",7),g.qZA()),2&t){const t=g.oxw(2);g.xp6(1),g.Q6J("ngIf",null==t.Form.get("selectedTypes").errors?null:t.Form.get("selectedTypes").errors.required),g.xp6(1),g.Q6J("ngIf",null==t.Form.get("selectedTypes").errors?null:t.Form.get("selectedTypes").errors.minlength)}}function J(t,e){if(1&t&&(g.TgZ(0,"div"),g.YNc(1,E,3,2,"div",47),g.qZA()),2&t){const t=g.oxw();g.xp6(1),g.Q6J("ngIf",t.Form.get("selectedTypes").invalid)}}function Y(t,e){1&t&&(g.TgZ(0,"ion-label",50),g._uU(1,"Adicionar intervenientes*"),g.qZA())}function R(t,e){if(1&t&&(g.TgZ(0,"ion-label"),g._uU(1),g.qZA()),2&t){const t=e.$implicit;g.xp6(1),g.Oqu(t.Name)}}function Q(t,e){1&t&&(g.TgZ(0,"ion-label",50),g._uU(1,"Com conhecimento"),g.qZA())}function L(t,e){if(1&t&&(g.TgZ(0,"ion-label"),g._uU(1),g.qZA()),2&t){const t=e.$implicit;g.xp6(1),g.Oqu(t.Name)}}function z(t,e){if(1&t){const t=g.EpF();g.TgZ(0,"div",51),g.TgZ(1,"ion-list"),g.TgZ(2,"ion-item"),g.TgZ(3,"ion-label"),g.TgZ(4,"p",52),g.TgZ(5,"span",53),g._uU(6),g.qZA(),g.TgZ(7,"span",54),g._uU(8),g.qZA(),g.TgZ(9,"span",55),g.NdJ("click",function(){const e=g.CHM(t).index;return g.oxw().removeAttachment(e)}),g._UZ(10,"ion-icon",56),g.qZA(),g.qZA(),g.TgZ(11,"p"),g.TgZ(12,"span",57),g._uU(13),g.qZA(),g.TgZ(14,"span",58),g._uU(15),g.ALo(16,"date"),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.qZA()}if(2&t){const t=e.$implicit;g.xp6(6),g.Oqu(t.Assunto),g.xp6(2),g.Oqu(t.appName),g.xp6(5),g.Oqu(t.EntidadeOrganicaNome),g.xp6(2),g.hij(" ",g.xi3(16,4,t.Data,"dd-MM-yyyy HH:mm")," ")}}function j(t,e){if(1&t&&g._UZ(0,"app-empty-container",62),2&t){const t=g.oxw(2);g.Q6J("texto",t.emptyTextDescription)}}function H(t,e){if(1&t){const t=g.EpF();g.TgZ(0,"app-attendee-modal",63),g.NdJ("closeComponent",function(){return g.CHM(t),g.oxw(2).closeComponent()})("setIntervenient",function(e){return g.CHM(t),g.oxw(2).setIntervenient(e)})("setIntervenientCC",function(e){return g.CHM(t),g.oxw(2).setIntervenientCC(e)})("setContact",function(e){return g.CHM(t),g.oxw(2).setContact(e)})("dynamicSetIntervenient",function(e){return g.CHM(t),g.oxw(2).dynamicSetIntervenient(e)}),g.qZA()}if(2&t){const t=g.oxw(2);g.Q6J("adding",t.adding)("footer",!1)("taskParticipants",t.taskParticipants)("taskParticipantsCc",t.taskParticipantsCc)}}function G(t,e){if(1&t&&(g.TgZ(0,"div",59),g.YNc(1,j,1,1,"app-empty-container",60),g.YNc(2,H,1,4,"app-attendee-modal",61),g.qZA()),2&t){const t=g.oxw();g.xp6(1),g.Q6J("ngIf",!t.showAttendees),g.xp6(1),g.Q6J("ngIf",t.showAttendees)}}const B={parse:{dateInput:"YYYY-MMMM-DD HH:mm"},display:{dateInput:"DD MMM YYYY H:mm",monthYearLabel:"MMM YYYY",dateA11yLabel:"LL",monthYearA11yLabel:"MMMM YYYY"}};let W=(()=>{class t{constructor(t,e,n,o,a,s,c,r,l,g,u){this.modalController=t,this.router=e,this.processes=n,this.attachmentsService=o,this.navParams=a,this.alertController=s,this.authService=c,this.userAuth=r,this.animationController=l,this.toastService=g,this.despachoService=u,this.modalTitle=["Efectuar Despacho","Solicitar Parecer","Solicitar Deferimento"],this.aplicationId=null,this.taskParticipants=[],this.taskParticipantsCc=[],this.documents=[],this.subjectTypes=[],this.selectedTypes=[],this.SearchFolder=[],this.contacts=[],this.showAttendees=!1,this.adding="intervenient",this.emptyTextDescription="Sem intervenientes selecionados",this.showEmptyContainer=!0,this.taskResult={},this.toppings=new d.NI,this.validateFrom=!1,this.searchDocumentPipe=p.G,this.loggeduser=r.ValidatedUser,this.task=this.navParams.get("task"),this.SearchFolder=this.navParams.get("SearchFolder"),this.aplicationId=this.navParams.get("aplicationId"),this.taskType=this.navParams.get("taskAction"),this.selectedTypes=["99999850"],this.postData=new i.Q,this.participants=this.participants=new Array,this.dispatchFolder={Nad:30,Subject:"",Message:"",SourceSecFsId:this.task.workflowInstanceDataFields.FsId,SourceType:"DOC",SourceId:this.task.workflowInstanceDataFields.DocID,DeadlineType:"",SubjectTypes:this.selectedTypes,NumberPDPP:this.task.workflowInstanceDataFields.DispatchNumber},361==this.aplicationId?(this.dispatchFolder.SourceType="FOLDER",this.dispatchFolder.SourceId=this.task.workflowInstanceDataFields.FolderID):8==this.aplicationId&&(this.dispatchFolder.SourceType="DOC",this.dispatchFolder.SourceId=this.task.workflowInstanceDataFields.DocId),this.postData.DispatchFolder=this.dispatchFolder,this.postData.UsersSelected=this.participants,this.postData.Priority="99999861",this.postData.DispatchFolder.Subject=this.task.workflowInstanceDataFields.Subject,this.profile=this.navParams.get("profile")}get toppingsValues(){return this.toppings.value}setAdding(t){return(0,o.mG)(this,void 0,void 0,function*(){this.adding=t})}ngOnInit(){console.log(this.postData),this.taskDate=new Date(this.task.taskStartDate),this.task.hasOwnProperty("isEvent")||this.getAttachments(),this.getSubjectType()}onSelectedTypesChanged(t){console.log(t),t.length>1&&(console.log(t.filter(t=>"99999850"!=t)),this.selectedTypes=t.filter(t=>"99999850"!=t)),0==t.length&&(this.selectedTypes=["99999850"])}close(){this.router.navigate(["/home/gabinete-digital/expediente"]),this.modalController.dismiss(null)}getSubjectType(){this.processes.GetSubjectType().subscribe(t=>{console.log(t),this.subjectTypes=t})}cancelTask(){this.modalController.dismiss(null)}runValidation(){this.validateFrom=!0}injectValidation(){this.Form=new d.cw({Subject:new d.NI(this.postData.DispatchFolder.Subject,[d.kI.required]),Location:new d.NI(this.postData.DispatchFolder.Message,[d.kI.required]),selectedTypes:new d.NI(this.selectedTypes,[d.kI.required]),Priority:new d.NI(this.postData.Priority,[d.kI.required]),participantes:new d.NI(this.taskParticipants,[d.kI.required])})}saveTask(){return(0,o.mG)(this,void 0,void 0,function*(){if("MDGPR"==this.loggeduser.Profile&&(this.injectValidation(),this.runValidation(),this.Form.invalid))return!1;"99999861"==this.postData.Priority?this.dispatchFolder.DeadlineType="Normal":"99999862"==this.postData.Priority?this.dispatchFolder.DeadlineType="Urgente":"99999863"==this.postData.Priority?this.dispatchFolder.DeadlineType="Muito Urgente":"99999864"==this.postData.Priority&&(this.dispatchFolder.DeadlineType="Urgent\xedssimo");let t=this.taskParticipants.concat(this.taskParticipantsCc);t=t.map(function(t){return{UserEmail:t.EmailAddress,UserType:t.IsRequired?"I":"CC"}});let e={ProcessInstanceID:"",Attachments:[]};const n=this.documents.map(t=>({ApplicationId:t.ApplicationType,SourceId:t.Id}));e.Attachments=n,this.SearchFolder&&(this.SearchFolder.Documents?this.SearchFolder.Documents.forEach(t=>{e.Attachments.push({ApplicationId:361,Source:1,SourceId:t.docID||t.docId||t.DocId,SourceName:t.Assunto})}):e.Attachments.push({ApplicationId:8,Source:1,SourceId:this.SearchFolder.docID||this.SearchFolder.docId||this.SearchFolder.DocId,SourceName:this.SearchFolder.Assunto})),this.dispatchFolder.SubjectTypes=this.selectedTypes;const o=this.toastService.loading();switch(this.loggeduser.Profile){case"MDGPR":if(this.taskParticipants.length>0)switch(this.taskType){case"0":this.postData={DistributionType:"Paralelo",CountryCode:"AO",Priority:this.postData.Priority,UserEmail:this.loggeduser.Email,UsersSelected:t,DispatchFolder:this.dispatchFolder,AttachmentList:e};let n={serialNumber:this.task.serialNumber,action:"Tratado",ActionTypeId:94,dataFields:{Note:""}};console.log(this.postData);try{this.taskResult=yield this.processes.postDespatcho(this.postData).toPromise(),yield this.toastService.successMessage("Processo efetuado"),this.modalController.dismiss(n)}catch(i){yield this.toastService.badRequest("Processo n\xe3o efetuado")}finally{o.remove()}console.log("this.taskResult",this.taskResult);break;case"1":this.postData={DistributionType:"Paralelo",CountryCode:"AO",Priority:this.postData.Priority,UserEmail:this.loggeduser.Email,UsersSelected:t,DispatchFolder:this.dispatchFolder,AttachmentList:e};let a={serialNumber:this.task.serialNumber,action:"Tratado",ActionTypeId:92,dataFields:{Note:""}};try{this.taskResult=yield this.processes.postParecer(this.postData).toPromise(),yield this.toastService.successMessage("Pedido enviado"),this.modalController.dismiss(a)}catch(i){yield this.toastService.badRequest("Processo n\xe3o efetuado")}finally{o.remove()}break;case"2":this.postData={DistributionType:"Paralelo",CountryCode:"AO",Priority:this.postData.Priority,UserEmail:this.loggeduser.Email,UsersSelected:t,DispatchFolder:this.dispatchFolder,AttachmentList:e};let s={serialNumber:this.task.serialNumber,action:"Tratado",ActionTypeId:93,dataFields:{Note:""}};try{this.taskResult=yield this.processes.postDeferimento(this.postData).toPromise(),this.toastService.successMessage("Processo efetuado"),this.modalController.dismiss(s)}catch(i){yield this.toastService.badRequest("Processo n\xe3o efetuado")}finally{o.remove()}console.log("this.taskResult",this.taskResult)}else this.alertController.presentAlert("Lista de i-ntervenientes vazia. Por favor, adicione 1 ou mais intervenientes.");break;case"PR":switch(this.taskType){case"0":this.postData={DistributionType:"Paralelo",CountryCode:"AO",Priority:this.postData.Priority,UserEmail:this.loggeduser.Email,UsersSelected:t,DispatchFolder:this.dispatchFolder,AttachmentList:e},console.log(this.postData);let n={serialNumber:this.task.serialNumber,action:"Tratado",ActionTypeId:99999881,dataFields:{Note:""}};try{this.taskResult=yield this.despachoService.createDespacho(this.postData).toPromise(),yield this.toastService.successMessage("Processo efetuado"),this.modalController.dismiss(n)}catch(i){yield this.toastService.badRequest("Processo n\xe3o efetuado")}finally{o.remove()}console.log("this.taskResult",this.taskResult);break;case"1":this.postData={DistributionType:"Paralelo",CountryCode:"AO",Priority:this.postData.Priority,UserEmail:this.loggeduser.Email,UsersSelected:t,DispatchFolder:this.dispatchFolder,AttachmentList:e};let a={serialNumber:this.task.serialNumber,action:"Tratado",ActionTypeId:99999881,dataFields:{Note:""}};try{this.taskResult=yield this.processes.postParecerPr(this.postData).toPromise(),yield this.toastService.successMessage("Pedido enviado"),this.modalController.dismiss(a)}catch(i){yield this.toastService.badRequest("Processo n\xe3o efetuado")}finally{o.remove()}}}})}getAttachments(){this.attachmentsService.getAttachmentsBySerial(this.task.serialNumber).subscribe(t=>{this.loadedAttachments=t,console.log(t)})}openAttendees(){return(0,o.mG)(this,void 0,void 0,function*(){if(window.innerWidth<=1024){const t=yield this.modalController.create({component:r.V,componentProps:{adding:this.adding,taskParticipants:this.taskParticipants,taskParticipantsCc:this.taskParticipantsCc},cssClass:"attendee modal modal-desktop",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{if(t){const e=(t=t.data).taskParticipantsCc;this.setIntervenient(t.taskParticipants),this.setIntervenientCC(e)}})}else this.showAttendees=!0})}setIntervenient(t){return(0,o.mG)(this,void 0,void 0,function*(){this.taskParticipants=t})}setIntervenientCC(t){return(0,o.mG)(this,void 0,void 0,function*(){this.taskParticipantsCc=t})}addParticipants(){return(0,o.mG)(this,void 0,void 0,function*(){this.adding="intervenient",this.openAttendees()})}addParticipantsCc(){return(0,o.mG)(this,void 0,void 0,function*(){this.adding="CC",this.openAttendees()})}dynamicSetIntervenient({taskParticipants:t,taskParticipantsCc:e}){this.taskParticipants=t,this.taskParticipantsCc=e}distartExpedientModal(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:a.Q,componentProps:{serialNumber:this.task.serialNumber,folderId:this.task.workflowInstanceDataFields.FolderID,action:"complete"},cssClass:"discart-expedient-modal",backdropDismiss:!1});yield t.present(),t.onDidDismiss().then(t=>{"close"==t.data&&(console.log("Expedient Discard closed"),this.modalController.dismiss(t.data))})})}setContact(t){return(0,o.mG)(this,void 0,void 0,function*(){"intervenient"==this.adding?this.taskParticipants=t:"CC"==this.adding&&(this.taskParticipantsCc=t)})}closeComponent(){return(0,o.mG)(this,void 0,void 0,function*(){this.showAttendees=!1})}viewExpedientDetail(){return(0,o.mG)(this,void 0,void 0,function*(){let t;console.log(this.profile),t=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const e=yield this.modalController.create({component:s.C,componentProps:{serialNumber:this.task.serialNumber,profile:this.profile},cssClass:t,backdropDismiss:!1});yield e.present(),e.onDidDismiss().then(t=>{})})}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:c.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>{t&&this.documents.push(t.data.selected)})})}removeAttachment(t){this.documents=this.documents.filter((e,n)=>t!=n)}}return t.\u0275fac=function(e){return new(e||t)(g.Y36(u.IN),g.Y36(h.F0),g.Y36(m.$),g.Y36(f.o),g.Y36(u.X1),g.Y36(v.c),g.Y36(Z.e),g.Y36(Z.e),g.Y36(u.vB),g.Y36(x.k),g.Y36(C.K))},t.\u0275cmp=g.Xpm({type:t,selectors:[["app-expedient-task-modal"]],features:[g._Bn([{provide:l.ab,useValue:B}])],decls:105,vars:26,consts:[[1,"height-100"],[1,"main-content","d-flex","height-100"],[1,"content","d-flex","flex-column","width-100"],["lines","none"],[1,"title"],[1,"ion-item-container","width-100"],["placeholder","Assunto*",3,"ngModel","ngModelChange"],[4,"ngIf"],[1,"d-flex","flex-column","height-100","overflow-y-auto"],[1,"container-div","width-100"],[1,"ion-item-class-2"],[1,"ion-icon-class"],["slot","start","src","assets/images/icons-description.svg"],[1,"ion-input-class","flex-grow-1"],["placeholder","Descri\xe7\xe3o",1,"add-border",3,"ngModel","ngModelChange"],[1,"ion-item-class-2","width-100"],["slot","start","name","time-outline",1,"icon-time"],[1,"ion-input-class"],["placeholder","Prazo*","interface","action-sheet","Cancel-text","Cancelar","required","",1,"d-block","d-md-none",3,"ngModel","ngModelChange"],["value","99999861"],["value","99999862"],["value","99999863"],["value","99999864"],["appearance","fill","floatLabel","never","appearance","none",1,"width-100","d-none","d-md-block"],["placeholder","Prazo*",3,"ngModel","ngModelChange"],[1,"container-div"],["floatLabel","never","appearance","fill","appearance","none",1,"width-100","d-block"],["multiple","","placeholder","Selecione o tipo de evento*",3,"ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],["slot","start","src","assets/images/icons-person.svg"],[1,"ion-input-class-no-height"],[1,"list-people"],["class","list-people-title",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"add-people",3,"click"],["slot","start","src","assets/images/icons-arrow-forward.svg"],["slot","start","src","assets/images/icons-people-cc.svg"],[1,"ion-item-container-no-border",3,"click"],[1,"d-flex","align-center"],[1,"attach-icon","d-flex","align-center"],["src","assets/images/icons-attach-doc.svg"],[1,"attach-document","pl-10"],["class","list ",4,"ngFor","ngForOf"],["class","aside-right flex-column height-100",4,"ngIf"],[1,"buttons"],["shape","round",1,"btn-cancel",3,"click"],["shape","round",1,"btn-ok",3,"click"],["class","input-errror-message",4,"ngIf"],[1,"input-errror-message"],[3,"value"],[1,"list-people-title"],[1,"list"],[1,"d-flex","ion-justify-content-between"],[1,"attach-title-item"],[1,"app-name"],[1,"close-button","text-black",3,"click"],["src","assets/images/icons-delete-25.svg",1,"font-20"],[1,"span-left"],[1,"span-right"],[1,"aside-right","flex-column","height-100"],["class","d-flex height-100 flex-column",3,"texto",4,"ngIf"],["class","d-flex flex-column height-100 hide-footer",3,"adding","footer","taskParticipants","taskParticipantsCc","closeComponent","setIntervenient","setIntervenientCC","setContact","dynamicSetIntervenient",4,"ngIf"],[1,"d-flex","height-100","flex-column",3,"texto"],[1,"d-flex","flex-column","height-100","hide-footer",3,"adding","footer","taskParticipants","taskParticipantsCc","closeComponent","setIntervenient","setIntervenientCC","setContact","dynamicSetIntervenient"]],template:function(t,e){if(1&t&&(g.TgZ(0,"ion-content",0),g.TgZ(1,"div",1),g.TgZ(2,"div",2),g.TgZ(3,"ion-item",3),g.TgZ(4,"ion-label",4),g._uU(5),g.qZA(),g.qZA(),g.TgZ(6,"div",5),g.TgZ(7,"ion-input",6),g.NdJ("ngModelChange",function(t){return e.postData.DispatchFolder.Subject=t}),g.qZA(),g.qZA(),g.YNc(8,k,2,1,"div",7),g.TgZ(9,"div",8),g.TgZ(10,"div",9),g.TgZ(11,"div",10),g.TgZ(12,"div",11),g._UZ(13,"ion-icon",12),g.qZA(),g.TgZ(14,"div",13),g.TgZ(15,"ion-textarea",14),g.NdJ("ngModelChange",function(t){return e.postData.DispatchFolder.Message=t}),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.TgZ(16,"div",9),g.TgZ(17,"div",15),g.TgZ(18,"div",11),g._UZ(19,"ion-icon",16),g.qZA(),g.TgZ(20,"div",17),g.TgZ(21,"ion-select",18),g.NdJ("ngModelChange",function(t){return e.postData.Priority=t}),g.TgZ(22,"ion-select-option",19),g.TgZ(23,"b"),g._uU(24,"Normal"),g.qZA(),g._uU(25," (4 dias para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(26,"ion-select-option",20),g.TgZ(27,"b"),g._uU(28,"Urgente"),g.qZA(),g._uU(29," (2 dias para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(30,"ion-select-option",21),g.TgZ(31,"b"),g._uU(32,"Muito Urgente"),g.qZA(),g._uU(33," (1 dia para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(34,"ion-select-option",22),g.TgZ(35,"b"),g._uU(36,"Urgent\xedssimo"),g.qZA(),g._uU(37," (8 horas para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.qZA(),g.TgZ(38,"mat-form-field",23),g.TgZ(39,"mat-select",24),g.NdJ("ngModelChange",function(t){return e.postData.Priority=t}),g.TgZ(40,"mat-option",19),g.TgZ(41,"b"),g._uU(42,"Normal"),g.qZA(),g._uU(43," (4 dias para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(44,"mat-option",20),g.TgZ(45,"b"),g._uU(46,"Urgente"),g.qZA(),g._uU(47," (2 dias para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(48,"mat-option",21),g.TgZ(49,"b"),g._uU(50,"Muito Urgente"),g.qZA(),g._uU(51," (1 dia para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.TgZ(52,"mat-option",22),g.TgZ(53,"b"),g._uU(54,"Urgent\xedssimo"),g.qZA(),g._uU(55," (8 horas para a execu\xe7\xe3o da tarefa)"),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.YNc(56,S,2,1,"div",7),g.TgZ(57,"div",25),g.TgZ(58,"div",10),g.TgZ(59,"div",11),g._UZ(60,"ion-icon",12),g.qZA(),g.TgZ(61,"div",17),g.TgZ(62,"mat-form-field",26),g.TgZ(63,"mat-select",27),g.NdJ("ngModelChange",function(t){return e.selectedTypes=t}),g.YNc(64,N,2,2,"mat-option",28),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.YNc(65,J,2,1,"div",7),g.TgZ(66,"div",25),g.TgZ(67,"div",10),g.TgZ(68,"div",11),g._UZ(69,"ion-icon",29),g.qZA(),g.TgZ(70,"div",30),g.TgZ(71,"div",31),g.TgZ(72,"ion-item",3),g.TgZ(73,"ion-list"),g.YNc(74,Y,2,0,"ion-label",32),g.YNc(75,R,2,1,"ion-label",33),g.qZA(),g.qZA(),g.qZA(),g.TgZ(76,"div",34),g.NdJ("click",function(){return e.addParticipants()}),g._UZ(77,"ion-icon",35),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.TgZ(78,"div",25),g.TgZ(79,"div",10),g.TgZ(80,"div",11),g._UZ(81,"ion-icon",36),g.qZA(),g.TgZ(82,"div",30),g.TgZ(83,"div",31),g.TgZ(84,"ion-item",3),g.TgZ(85,"ion-list"),g.YNc(86,Q,2,0,"ion-label",32),g.YNc(87,L,2,1,"ion-label",33),g.qZA(),g.qZA(),g.qZA(),g.TgZ(88,"div",34),g.NdJ("click",function(){return e.addParticipantsCc()}),g._UZ(89,"ion-icon",35),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.TgZ(90,"div",37),g.NdJ("click",function(){return e.getDoc()}),g.TgZ(91,"ion-label",38),g.TgZ(92,"div",39),g._UZ(93,"ion-icon",40),g.qZA(),g.TgZ(94,"div",41),g.TgZ(95,"ion-label"),g._uU(96,"Anexar Documentos"),g.qZA(),g.qZA(),g.qZA(),g.qZA(),g.YNc(97,z,17,7,"div",42),g.qZA(),g.qZA(),g.YNc(98,G,3,2,"div",43),g.qZA(),g.qZA(),g.TgZ(99,"ion-footer"),g.TgZ(100,"div",44),g.TgZ(101,"button",45),g.NdJ("click",function(){return e.cancelTask()}),g._uU(102,"Cancelar"),g.qZA(),g.TgZ(103,"button",46),g.NdJ("click",function(){return e.saveTask()}),g._uU(104,"Gravar"),g.qZA(),g.qZA(),g.qZA()),2&t){let t,n,o,i,a;g.xp6(5),g.Oqu(e.modalTitle[e.taskType]),g.xp6(1),g.ekj("input-error",(null==e.Form||null==(t=e.Form.get("Subject"))?null:t.invalid)&&e.validateFrom),g.xp6(1),g.Q6J("ngModel",e.postData.DispatchFolder.Subject),g.xp6(1),g.Q6J("ngIf",e.Form&&e.validateFrom),g.xp6(6),g.ekj("input-error",(null==e.Form||null==(n=e.Form.get("Location"))?null:n.invalid)&&e.validateFrom),g.xp6(1),g.Q6J("ngModel",e.postData.DispatchFolder.Message),g.xp6(5),g.ekj("input-error",(null==e.Form||null==(o=e.Form.get("Priority"))?null:o.invalid)&&e.validateFrom),g.xp6(1),g.Q6J("ngModel",e.postData.Priority),g.xp6(18),g.Q6J("ngModel",e.postData.Priority),g.xp6(17),g.Q6J("ngIf",e.Form&&e.validateFrom),g.xp6(5),g.ekj("input-error",(null==e.Form||null==(i=e.Form.get("selectedTypes"))?null:i.invalid)&&e.validateFrom),g.xp6(2),g.Q6J("ngModel",e.selectedTypes),g.xp6(1),g.Q6J("ngForOf",e.subjectTypes),g.xp6(1),g.Q6J("ngIf",e.Form&&e.validateFrom),g.xp6(5),g.ekj("input-error",(null==e.Form||null==(a=e.Form.get("participantes"))?null:a.invalid)&&e.validateFrom),g.xp6(4),g.Q6J("ngIf",(null==e.taskParticipants?null:e.taskParticipants.length)<1),g.xp6(1),g.Q6J("ngForOf",e.taskParticipants),g.xp6(11),g.Q6J("ngIf",(null==e.taskParticipantsCc?null:e.taskParticipantsCc.length)<1),g.xp6(1),g.Q6J("ngForOf",e.taskParticipantsCc),g.xp6(10),g.Q6J("ngForOf",e.documents),g.xp6(1),g.Q6J("ngIf",e.postData)}},directives:[u.W2,u.Ie,u.Q$,u.pK,u.j9,d.JJ,d.On,M.O5,u.gu,u.g2,u.t9,u.QI,d.Q7,u.n0,b.KE,P.gD,A.ey,M.sg,u.q_,u.fr,w.M,T.Y],pipes:[M.uU],styles:[".content[_ngcontent-%COMP%]{padding:30px 20px 0!important;margin:0;float:left}.content[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-family:Roboto;font-size:25px;font-weight:400;font-stretch:normal;font-style:normal;line-height:normal;letter-spacing:normal;color:#000}.content[_ngcontent-%COMP%] .container-div[_ngcontent-%COMP%]{margin-bottom:15px}.content[_ngcontent-%COMP%] .ion-item-container[_ngcontent-%COMP%]{margin:15px auto;border:1px solid #ebebeb;border-radius:5px;padding-left:5px}.content[_ngcontent-%COMP%] .ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.content[_ngcontent-%COMP%] .ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}.content[_ngcontent-%COMP%] ion-select[_ngcontent-%COMP%]{margin-left:0}.content[_ngcontent-%COMP%] .ion-input-class[_ngcontent-%COMP%]{width:calc(100% - 45px);border:1px solid #ebebeb;border-radius:5px;padding-left:5px;padding-right:10px;float:left;overflow:hidden;flex:1;min-height:44px}.content[_ngcontent-%COMP%] .ion-input-class-no-height[_ngcontent-%COMP%]{border:1px solid #ebebeb;border-radius:5px;overflow:auto}.content[_ngcontent-%COMP%] .list-people[_ngcontent-%COMP%]{width:256px;float:left}.content[_ngcontent-%COMP%] .add-people[_ngcontent-%COMP%]{width:45px;float:right;overflow:auto;font-size:25px;padding:10px}.content[_ngcontent-%COMP%] .list-people-title[_ngcontent-%COMP%]{color:#a3a3a3}.content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%], .content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1}.content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{width:100%}.content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.container-footer[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.container-footer[_ngcontent-%COMP%] .button-cancel[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;--background:#e0e9ee;--color:#061b52;margin:10px}.container-footer[_ngcontent-%COMP%] .button-save[_ngcontent-%COMP%]{width:170px;height:44px;border-radius:22.5px;--background:#42b9fe;--color:#fff;margin:10px}.buttons[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:20px;overflow:auto}@media only screen and (min-width: 1024px){.aside-content[_ngcontent-%COMP%]{display:block}}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attach-title-item[_ngcontent-%COMP%]{width:100%;font-size:15px;color:#0d89d1}.span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.close-button[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .app-name[_ngcontent-%COMP%]{display:none}.list[_ngcontent-%COMP%]:hover .close-button[_ngcontent-%COMP%]{display:block!important}.app-name[_ngcontent-%COMP%]{background:#42b9f2;border-radius:18px;text-align:center;display:flex;align-items:center;padding:0 5px;color:#fff;font-size:9pt;font-weight:500;height:19px;-webkit-border-radius:18px;-moz-border-radius:18px;-ms-border-radius:18px;-o-border-radius:18px}.icon-time[_ngcontent-%COMP%]{color:#797979b0} .mat-form-field-appearance-fill .mat-form-field-flex{background-color:#fff}"]}),t})()},11055:function(t,e,n){"use strict";n.d(e,{C:function(){return E}});var o=n(64762),i=n(32379),a=n(83189),s=n(75008),c=n(86807),r=n(45896),d=n(23066),l=n(4528),p=n(320),g=n(84393),u=n(37716),h=n(28621),m=n(53760),f=n(80106),v=n(39895),Z=n(35957),x=n(84465),C=n(38583),M=n(20985),b=n(96529);let P=(()=>{class t{constructor(t,e){this.processes=t,this.iab=e}viewDocument({DocId:t,ApplicationId:e}){this.processes.GetDocumentUrl(t,e).subscribe(t=>{const e=t.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");this.iab.create(e,"_blank").show()})}}return t.\u0275fac=function(e){return new(e||t)(u.LFG(h.$),u.LFG(m.i))},t.\u0275prov=u.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})(),A=(()=>{class t{constructor(t,e,n){this.iab=t,this.processDocumentService=e,this.processes=n}viewDocument({DocId:t,ApplicationId:e}){this.processDocumentService.viewDocument({DocId:t,ApplicationId:e})}CompleteTask({body:t}){return this.processes.CompleteTask(t)}UpdateTaskStatus({FolderId:t}){return this.processes.UpdateTaskStatus(t)}}return t.\u0275fac=function(e){return new(e||t)(u.LFG(m.i),u.LFG(P),u.LFG(h.$))},t.\u0275prov=u.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();function w(t,e){if(1&t&&(u.TgZ(0,"div"),u.TgZ(1,"p"),u._uU(2),u.qZA(),u.qZA()),2&t){const t=e.$implicit;u.xp6(2),u.Oqu(t.Name)}}function T(t,e){if(1&t&&(u.TgZ(0,"div"),u.TgZ(1,"h5"),u._uU(2,"Com conhecimento"),u.qZA(),u.TgZ(3,"ion-item",23),u.TgZ(4,"ion-label"),u.YNc(5,w,3,1,"div",27),u.qZA(),u.qZA(),u.qZA()),2&t){const t=u.oxw(2);u.xp6(5),u.Q6J("ngForOf",t.cc)}}function _(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"ion-item",28),u.TgZ(1,"ion-label",29),u.NdJ("click",function(){const e=u.CHM(t).$implicit;return u.oxw(2).viewDocument(e.DocId)}),u.TgZ(2,"p",30),u._uU(3),u.TgZ(4,"span",31),u._UZ(5,"ion-icon",32),u.qZA(),u.qZA(),u.TgZ(6,"p"),u.TgZ(7,"span",33),u._uU(8),u.qZA(),u.TgZ(9,"span",34),u._uU(10),u.ALo(11,"date"),u.qZA(),u.qZA(),u.qZA(),u.qZA()}if(2&t){const t=e.$implicit;u.xp6(3),u.Oqu(t.Assunto),u.xp6(5),u.Oqu(t.Sender),u.xp6(2),u.Oqu(u.xi3(11,3,t.DocDate,"dd/MM/yyyy HH:mm"))}}function O(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"ion-item",39),u.NdJ("click",function(){const e=u.CHM(t).$implicit;return u.oxw(4).goToEvent(e.EventId)}),u.TgZ(1,"div"),u.TgZ(2,"div",40),u.TgZ(3,"div",41),u._uU(4),u.ALo(5,"date"),u.qZA(),u.TgZ(6,"div",42),u._uU(7),u.ALo(8,"date"),u.qZA(),u.qZA(),u.TgZ(9,"div",43),u.TgZ(10,"div",44),u._uU(11),u.qZA(),u.TgZ(12,"div",45),u._uU(13),u.qZA(),u.qZA(),u.qZA(),u.qZA()}if(2&t){const t=e.$implicit,n=u.oxw(4);u.xp6(1),u.MT6("d-flex content-",n.profile,"-",t.CalendarName,""),u.xp6(3),u.Oqu(u.xi3(5,8,t.StartDate,"HH:mm")),u.xp6(3),u.Oqu(u.xi3(8,11,t.EndDate,"HH:mm")),u.xp6(4),u.Oqu(t.Location),u.xp6(2),u.Oqu(t.Subject)}}function q(t,e){if(1&t&&(u.TgZ(0,"div",37),u.TgZ(1,"ion-list"),u.YNc(2,O,14,14,"ion-item",38),u.qZA(),u.qZA()),2&t){const t=u.oxw(3);u.xp6(2),u.Q6J("ngForOf",t.eventsList)}}function k(t,e){if(1&t&&(u.TgZ(0,"div"),u.TgZ(1,"h5",35),u._uU(2,"Eventos Associados"),u.qZA(),u.TgZ(3,"ion-list"),u.YNc(4,q,3,1,"div",36),u.qZA(),u.qZA()),2&t){const t=u.oxw(2);u.xp6(4),u.Q6J("ngIf",t.eventsList)}}function y(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",5),u.TgZ(1,"div",6),u.TgZ(2,"div",7),u.TgZ(3,"div",8),u.NdJ("click",function(){return u.CHM(t),u.oxw().goBack()}),u._UZ(4,"ion-icon",9),u.qZA(),u.TgZ(5,"div",10),u.TgZ(6,"ion-label",11),u._uU(7),u.qZA(),u.qZA(),u.TgZ(8,"div",12),u.TgZ(9,"button",13),u.NdJ("click",function(){return u.CHM(t),u.oxw().openOptions()}),u._UZ(10,"ion-icon",14),u.qZA(),u.qZA(),u.qZA(),u.qZA(),u.TgZ(11,"div",15),u.TgZ(12,"div",16),u.TgZ(13,"ion-label"),u.TgZ(14,"p"),u.TgZ(15,"span",17),u._uU(16),u.qZA(),u.TgZ(17,"span",18),u._uU(18),u.qZA(),u.qZA(),u.qZA(),u.qZA(),u.qZA(),u._UZ(19,"div",19),u.TgZ(20,"div",20),u.TgZ(21,"div",21),u.YNc(22,T,6,1,"div",22),u.TgZ(23,"h5"),u._uU(24,"Detalhes"),u.qZA(),u.TgZ(25,"ion-item",23),u._UZ(26,"p",24),u.qZA(),u.qZA(),u.TgZ(27,"div",25),u.TgZ(28,"ion-list"),u.TgZ(29,"h5"),u._uU(30,"Documentos Anexados"),u.qZA(),u.YNc(31,_,12,6,"ion-item",26),u.qZA(),u.qZA(),u.YNc(32,k,5,1,"div",22),u.qZA(),u.qZA()}if(2&t){const t=u.oxw();u.xp6(7),u.Oqu(t.task.Folio),u.xp6(9),u.Oqu(t.customDate),u.xp6(2),u.Oqu(t.task.WorkflowName),u.xp6(4),u.Q6J("ngIf",t.cc.length>0),u.xp6(4),u.Q6J("innerHTML",t.task.Note,u.oJD),u.xp6(5),u.Q6J("ngForOf",t.fulltask.Documents),u.xp6(1),u.Q6J("ngIf",t.eventsList)}}function D(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw(2).attachDocument()}),u._uU(1,"Anexar Documentos"),u.qZA()}}function I(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"button",54),u.NdJ("click",function(){return u.CHM(t),u.oxw(2).sendExpedienteToPending()}),u._uU(1,"Enviar para pendentes"),u.qZA()}}const S=function(){return["PR"]};function N(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",46),u.TgZ(1,"div",47),u.TgZ(2,"div",48),u.TgZ(3,"div"),u._uU(4,"Enviar para o PR"),u.qZA(),u.qZA(),u.TgZ(5,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw().openAddNoteModal("Aprovar")}),u._uU(6,"Avalia\xe7\xe3o Superior"),u.qZA(),u.TgZ(7,"div",48),u.TgZ(8,"div"),u._uU(9,"Solicitar revis\xe3o"),u.qZA(),u.qZA(),u.TgZ(10,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw().openAddNoteModal("Revis\xe3o")}),u._uU(11,"Mandar para Revis\xe3o"),u.qZA(),u.TgZ(12,"div",48),u.TgZ(13,"div"),u._uU(14,"Outras op\xe7\xf5es"),u.qZA(),u.qZA(),u.TgZ(15,"button",50),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openExpedientActionsModal("0",e.fulltask)}),u._uU(16,"Efetuar Despacho"),u.qZA(),u.TgZ(17,"button",49),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openExpedientActionsModal("1",e.fulltask)}),u._uU(18,"Solicitar Parecer"),u.qZA(),u.TgZ(19,"button",49),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openExpedientActionsModal("2",e.fulltask)}),u._uU(20,"Pedido de Deferimento"),u.qZA(),u.TgZ(21,"button",49),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openBookMeetingModal(e.task)}),u._uU(22,"Marcar Reuni\xe3o"),u.qZA(),u.YNc(23,D,2,0,"button",51),u.TgZ(24,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw().distartExpedientModal("descartar")}),u._uU(25,"Descartar"),u.qZA(),u.YNc(26,I,2,0,"button",52),u._UZ(27,"div",53),u.qZA(),u.qZA()}if(2&t){const t=u.oxw();u.xp6(23),u.Q6J("ngIf",!t.p.userRole(u.DdM(2,S))),u.xp6(3),u.Q6J("ngIf","Pending"!=t.task.Status)}}function F(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw(2).sendExpedienteToPending()}),u._uU(1,"Enviar para Pendentes"),u.qZA()}}function U(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",46),u.TgZ(1,"div",47),u.TgZ(2,"button",50),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openExpedientActionsModal("0",e.fulltask)}),u._uU(3,"Efetuar Despacho"),u.qZA(),u.TgZ(4,"button",49),u.NdJ("click",function(){return u.CHM(t),u.oxw().distartExpedientModal("descartar")}),u._uU(5,"Descartar"),u.qZA(),u._UZ(6,"div",53),u.TgZ(7,"button",49),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openExpedientActionsModal("1",e.fulltask)}),u._uU(8,"Solicitar Parecer"),u.qZA(),u.TgZ(9,"button",49),u.NdJ("click",function(){u.CHM(t);const e=u.oxw();return e.openBookMeetingModal(e.task)}),u._uU(10,"Marcar Reuni\xe3o"),u.qZA(),u.YNc(11,F,2,0,"button",51),u._UZ(12,"div",55),u.TgZ(13,"button",56),u._uU(14,"Delegar"),u.qZA(),u.qZA(),u.qZA()}if(2&t){const t=u.oxw();u.xp6(11),u.Q6J("ngIf","Pending"!=t.task.Status)}}let E=(()=>{class t{constructor(t,e,n,o,i,a,s,c,r,d,l,p){this.processes=t,this.iab=e,this.events=n,this.router=o,this.modalController=i,this.popoverController=a,this.activatedRoute=s,this.toastService=c,this.location=r,this.attachmentsService=d,this.p=l,this.expedientesService=p,this.months=["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],this.days=["Domingo","Segunda-feira","Ter\xe7a-feira","Quarta-feira","Quinta-feira","Sexta-feira","S\xe1bado"],this.cc=[],this.documents=[],this.hideSendToPendentes=!0,this.searchDocumentPipe=new g.G,this.activatedRoute.paramMap.subscribe(t=>{t.params.SerialNumber&&(this.serialNumber=t.params.SerialNumber),t.params.caller&&(this.caller=t.params.caller)})}ngOnInit(){this.LoadTaskDetail(this.serialNumber)}close(){this.modalController.dismiss()}showToast(){this.toastService.presentToast('N\xe3o foi poss\xedvel fazer login"')}approve(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n={serialNumber:this.serialNumber,action:"Aprovar",ActionTypeId:100000004,dataFields:{ReviewUserComment:t},AttachmentList:e};console.log(n);const o=this.toastService.loading();try{yield this.processes.CompleteTask(n).toPromise(),this.close(),this.toastService.successMessage("Processo aprovado")}catch(i){this.toastService.badRequest("Processo n\xe3o aprovado")}finally{o.remove()}})}sendToReview(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n={serialNumber:this.serialNumber,action:"Retificar",ActionTypeId:99999877,dataFields:{ReviewUserComment:t},AttachmentList:e};const o=this.toastService.loading();try{yield this.processes.CompleteTask(n).toPromise(),this.close(),this.toastService.successMessage()}catch(i){this.toastService.badRequest()}finally{o.remove()}})}openAddNoteModal(t){return(0,o.mG)(this,void 0,void 0,function*(){let e;e=window.innerWidth<801?"modal modal-desktop":"add-note-modal";const n=yield this.modalController.create({component:p.C,componentProps:{showAttachmentBtn:!1},cssClass:e});yield n.present(),n.onDidDismiss().then(e=>{if(console.log(e),e.data){let n={ProcessInstanceID:"",Attachments:e.data.documents.map(t=>({ApplicationId:t.ApplicationType,SourceId:t.Id}))};"Aprovar"==t?this.approve(e.data.note,n):"Revis\xe3o"==t&&this.sendToReview(e.data.note,n),this.goBack()}})})}goBack(){this.location.back()}sendExpedienteToPending(){this.processes.SetTaskToPending(this.serialNumber).subscribe(t=>{console.log(t),this.toastService.successMessage("Processo enviado para pendentes"),this.goBack()},t=>{this.toastService.badRequest("Processo n\xe3o enviado para pendentes")})}LoadTaskDetail(t){return(0,o.mG)(this,void 0,void 0,function*(){this.processes.GetTask(t).subscribe(t=>{console.log(t),this.task={SerialNumber:t.serialNumber,Folio:t.workflowInstanceDataFields.Subject,Senders:t.originator.email,CreateDate:(0,c.momentG)(new Date(t.taskStartDate),"yyyy-MM-dd HH:mm:ss"),DocumentURL:t.workflowInstanceDataFields.ViewerRequest,Remetente:t.workflowInstanceDataFields.Sender,Note:t.workflowInstanceDataFields.TaskMessage||t.workflowInstanceDataFields.Note,FolderId:t.workflowInstanceDataFields.FolderID,FsId:t.workflowInstanceDataFields.FsId,DocId:t.workflowInstanceDataFields.DocID,WorkflowName:t.workflowDisplayName,Status:t.workflowInstanceDataFields.Status,DispatchNumber:t.workflowInstanceDataFields.DispatchNumber,AttachmentsProcessLastInstanceID:t.workflowInstanceDataFields.AttachmentsProcessLastInstanceID,InstanceID:t.workflowInstanceDataFields.InstanceID},this.fulltask=t;let e=new Date(this.task.CreateDate);this.customDate=this.days[e.getDay()]+", "+e.getDate()+" de "+this.months[e.getMonth()],this.processes.GetTaskParticipants(this.task.FolderId).subscribe(t=>{this.intervenientes=t.filter(t=>"I"==t.Type),this.cc=t.filter(t=>"CC"==t.Type)}),console.log("this.task",this.task.InstanceID),console.log("this.task.DocumentURL",this.task.DocumentURL)},t=>{try{this.toastService.badRequest("Processo n\xe3o encontrado"),this.goBack()}catch(e){window.history.back()}finally{this.toastService.badRequest(0==t.status?"N\xe3o \xe9 poss\xedvel visualizar este processo no modo offline":"Processo n\xe3o encontrado")}})})}LoadRelatedEvents(t){return(0,o.mG)(this,void 0,void 0,function*(){})}viewDocument(t){this.expedientesService.viewDocument({ApplicationId:"361",DocId:t})}getAttachments(t){console.log(t),this.attachmentsService.getAttachmentsBySerial(t).subscribe(t=>{this.attachments=t,console.log("res",t)})}attachDocument(){this.getDoc()}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:l.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){t&&(this.documents.push(t.data.selected),this.documents.forEach(t=>{let e={InstanceID:this.task.InstanceID,WorkflowDisplayName:this.task.WorkflowName,FolderID:this.task.FolderId,DispatchNumber:this.task.DispatchNumber,AttachmentsProcessLastInstanceID:this.task.AttachmentsProcessLastInstanceID,Attachments:[]};const n=this.searchDocumentPipe.transformToAttachment(t);e.Attachments=n;const o=this.toastService.loading();this.attachmentsService.AddAttachment(e).subscribe(t=>{this.toastService.successMessage()},()=>{this.toastService.badRequest()},()=>{o.remove()})}))}))})}openExpedientActionsModal(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n;n=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const a=yield this.modalController.create({component:i.F,componentProps:{taskAction:t,task:e,profile:this.profile},cssClass:n});yield a.present(),a.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){let e=t.data;if(t.data){const t=this.toastService.loading();try{yield this.processes.CompleteTask(e).toPromise(),this.toastService.successMessage("Processo descartado"),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{t.remove()}}else this.close()}))})}distartExpedientModal(t){return(0,o.mG)(this,void 0,void 0,function*(){const e=yield this.modalController.create({component:r.Q,componentProps:{},cssClass:"discart-expedient-modal",backdropDismiss:!1});yield e.present(),e.onDidDismiss().then(e=>(0,o.mG)(this,void 0,void 0,function*(){if(console.log(e.data),"descartar"==t){if("Yes"==e.data){let t={serialNumber:this.task.SerialNumber,action:"Passivo",ActionTypeId:99999877,dataFields:{Note:""}};const e=this.toastService.loading();try{yield this.processes.CompleteTask(t),this.toastService.successMessage("Processo descartado"),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{e.remove()}}}else if("Yes"==e.data){const e=this.toastService.loading();try{yield this.expedientesService.CompleteTask(t).toPromise(),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{e.remove()}}else if("No"==e.data){console.log("Update");const t=this.toastService.loading();try{yield this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(),this.toastService.successMessage(),this.goBack()}catch(n){this.toastService.badRequest()}finally{t.remove()}}}))})}openBookMeetingModal(t){return(0,o.mG)(this,void 0,void 0,function*(){let e;console.log(t),e=window.innerWidth<=800?"book-meeting-modal modal modal-desktop":"modal modal-desktop showAsideOptions";const n=yield this.modalController.create({component:a.k,componentProps:{task:this.task},cssClass:e,backdropDismiss:!1});yield n.present(),n.onDidDismiss().then(t=>{this.goBack()})})}goToEvent(t){this.router.navigate(["/home/events",t,"expediente"])}viewEventDetail(t){return(0,o.mG)(this,void 0,void 0,function*(){console.log(this.profile);const e=yield this.modalController.create({component:s.u,componentProps:{eventId:t,profile:this.profile},cssClass:"modal modal-desktop",backdropDismiss:!1});yield e.present(),e.onDidDismiss().then(t=>{})})}openOptions(t){return(0,o.mG)(this,void 0,void 0,function*(){const e=yield this.popoverController.create({component:d.M,cssClass:"exp-options",componentProps:{task:this.task,fulltask:this.fulltask,taskAction:t},translucent:!0});return yield e.present()})}}return t.\u0275fac=function(e){return new(e||t)(u.Y36(h.$),u.Y36(m.i),u.Y36(f.n),u.Y36(v.F0),u.Y36(Z.IN),u.Y36(Z.Dh),u.Y36(v.gz),u.Y36(x.k),u.Y36(C.Ye),u.Y36(M.o),u.Y36(b.$),u.Y36(A))},t.\u0275cmp=u.Xpm({type:t,selectors:[["app-expediente-detail"]],decls:9,vars:5,consts:[[1,"ion-no-border"],["id","main-content",1,"ion-page","d-none"],[1,"main-content","d-flex","height-100","overflow-hidden"],["class","content d-flex flex-column",4,"ngIf"],["class","aside-right flex-column height-100 overflow-y-auto",4,"ngIf"],[1,"content","d-flex","flex-column"],[1,"main-header",2,"overflow","unset !important"],[1,"title-content","width-100","d-flex","justify-between"],["defaultHref","#",1,"font-30","cursor-pointer",3,"click"],["slot","end","src","assets/images/icons-arrow-arrow-left.svg"],[1,"middle","flex-grow-1"],[1,"title"],[1,"menu-ptions"],[1,"btn-no-color",3,"click"],["src","assets/images/icons-menu.svg"],[1,"upper-content",2,"overflow","unset !important"],[1,"content-details"],[1,"date"],[1,"label"],[1,"line"],[1,"overflow-y-auto"],[1,"middle-content"],[4,"ngIf"],[1,"ion-no-margin","ion-no-padding"],[3,"innerHTML"],[1,"bottom-content","width-100"],["class","ion-no-margin ion-no-padding cursor-pointer",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],[1,"ion-no-margin","ion-no-padding","cursor-pointer"],[1,"d-block",3,"click"],[1,"attach-title-item"],[1,"span-right","color-red","btn-size"],["hidden","","name","close"],[1,"span-left"],[1,"span-right"],[1,"h3-event-title"],["class","content-items width-100",4,"ngIf"],[1,"content-items","width-100"],["class"," ion-no-padding width-100 cursor-pointer","lines","none",3,"click",4,"ngFor","ngForOf"],["lines","none",1,"ion-no-padding","width-100","cursor-pointer",3,"click"],[1,"schedule-time"],[1,"time-start"],[1,"time-end"],[1,"schedule-details"],[1,"location"],[1,"description"],[1,"aside-right","flex-column","height-100","overflow-y-auto"],[1,"buttons"],[1,"option-desc"],["shape","round",1,"btn-cancel",3,"click"],["shape","round",1,"btn-ok",3,"click"],["class","btn-cancel","shape","round",3,"click",4,"ngIf"],["full","","class","btn-ok","shape","round",3,"click",4,"ngIf"],[1,"solid"],["full","","shape","round",1,"btn-ok",3,"click"],["hidden","",1,"solid"],["hidden","","shape","round",1,"btn-cancel"]],template:function(t,e){1&t&&(u.TgZ(0,"ion-header",0),u._UZ(1,"app-header"),u.qZA(),u.TgZ(2,"div",1),u._UZ(3,"ion-menu-button"),u.qZA(),u.TgZ(4,"ion-content"),u.TgZ(5,"div",2),u.YNc(6,y,33,7,"div",3),u.YNc(7,N,28,3,"div",4),u.YNc(8,U,15,1,"div",4),u.qZA(),u.qZA()),2&t&&(u.xp6(6),u.Q6J("ngIf",e.task),u.xp6(1),u.Q6J("ngIf",e.task&&!e.p.userRole(u.DdM(3,S))),u.xp6(1),u.Q6J("ngIf",e.task&&e.p.userRole(u.DdM(4,S))))},styles:[".main-content[_ngcontent-%COMP%]{background-color:#fff!important;border-top-left-radius:25px;border-top-right-radius:25px}.content[_ngcontent-%COMP%]{padding:30px 20px 0!important;margin:0;float:left}.color-red[_ngcontent-%COMP%]{font-weight:500;color:#d30a0a!important}.btn-size[_ngcontent-%COMP%]{font-size:18px!important}.main-header[_ngcontent-%COMP%]{font-family:Roboto;border-top-left-radius:25px;border-top-right-radius:25px;background-color:#fff;overflow:auto;color:#000;transform:translate3d(0,1px,0)}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%]{width:360px;margin:0 auto;overflow:auto;padding:0!important;background:#fff}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%] .middle[_ngcontent-%COMP%]{padding:0!important;float:left;width:280px;margin:2.5px 0 0 5px;display:flex;align-items:center}.main-header[_ngcontent-%COMP%] .header-top[_ngcontent-%COMP%] .right[_ngcontent-%COMP%]{padding:0!important;float:right;font-size:25px;color:#0782c9;margin:5px 0 0}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%]{width:310px;overflow:auto;margin:0 auto}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%] .header-bottom-icon[_ngcontent-%COMP%]{width:30px;font-size:25px;float:left;padding:2px}.main-header[_ngcontent-%COMP%] .header-bottom[_ngcontent-%COMP%] .header-bottom-contacts[_ngcontent-%COMP%]{width:275px;font-size:15px;color:#797979;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;float:left;padding:5px;margin:1px}.main-header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:25px;overflow:auto;float:left;padding-top:4px;padding-left:5px}.main-header[_ngcontent-%COMP%] .btn-no-color[_ngcontent-%COMP%] icon[_ngcontent-%COMP%]{font-size:15px;border:1px solid red}ion-item-group[_ngcontent-%COMP%]{margin:15px}ion-button[_ngcontent-%COMP%]{display:block;width:80%;margin:20px auto}.upper-content[_ngcontent-%COMP%]{font-family:Roboto;margin-left:41px;overflow:auto;font-size:18px}.upper-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{border-radius:20px;background:#ffb703;float:right;padding:5px 13.5px;color:#fff}.upper-content[_ngcontent-%COMP%] .button-calendar-type[_ngcontent-%COMP%] ion-button[_ngcontent-%COMP%]{height:25px}.upper-content[_ngcontent-%COMP%] .content-details[_ngcontent-%COMP%]{font-size:17px}.upper-content[_ngcontent-%COMP%] .content-details[_ngcontent-%COMP%] .date[_ngcontent-%COMP%]{color:#797979}.middle-conten[_ngcontent-%COMP%] .middle-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:16px}.bottom-content[_ngcontent-%COMP%]{margin:0 auto}.bottom-content[_ngcontent-%COMP%] .bottom-content[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:16px;margin:0 0 0 10px}.bottom-content[_ngcontent-%COMP%] .attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 5px 10px;padding:5px;float:left}.bottom-content[_ngcontent-%COMP%] .attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.bottom-content[_ngcontent-%COMP%] .attach-title-item[_ngcontent-%COMP%]{font-size:18px;width:100%;color:#0d89d1;padding-bottom:5px}.bottom-content[_ngcontent-%COMP%] .span-left[_ngcontent-%COMP%]{float:left;font-size:15x}.bottom-content[_ngcontent-%COMP%] .span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:13px}.aside-right[_ngcontent-%COMP%]{padding:0 20px;margin:20px 0}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;margin-bottom:20px}.aside-right[_ngcontent-%COMP%] .arrow-right[_ngcontent-%COMP%] .arrow-right-icon[_ngcontent-%COMP%]{width:37px;float:right;font-size:35px;overflow:hidden}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:space-between}.aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-cancel[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-delete[_ngcontent-%COMP%], .aside-right[_ngcontent-%COMP%] .buttons[_ngcontent-%COMP%] .btn-ok[_ngcontent-%COMP%]{height:auto!important;font-size:16px!important;font-weight:600!important;width:100%!important;margin-bottom:10px!important;padding:15px!important}.aside-right[_ngcontent-%COMP%] .solid[_ngcontent-%COMP%]{display:block;width:90%;border-top:1px solid #ebebeb;margin:0 auto 10px!important}.content-items[_ngcontent-%COMP%] .item-exp[_ngcontent-%COMP%]{overflow:auto;padding-top:5px;padding-bottom:5px}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%]{padding:0;margin:0}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:space-between;align-items:center}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%]{padding-bottom:5px;margin-top:5px;border-bottom:1px solid #ebebeb;display:flex;justify-content:space-between;align-items:center}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-time[_ngcontent-%COMP%]{margin-right:10px}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-time[_ngcontent-%COMP%] .time-end[_ngcontent-%COMP%], .content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-time[_ngcontent-%COMP%] .time-start[_ngcontent-%COMP%]{color:#797979!important;font-family:Roboto;font-size:13px}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-date[_ngcontent-%COMP%]{margin-right:10px;width:22%;color:#797979!important;font-size:13px}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-details[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;width:100%}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-details[_ngcontent-%COMP%] .location[_ngcontent-%COMP%]{font-family:Roboto;font-size:13px;color:#000;width:100%}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .schedule-details[_ngcontent-%COMP%] .description[_ngcontent-%COMP%]{font-family:Roboto;font-size:15px;font-weight:700;color:#0d89d1}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%] .color[_ngcontent-%COMP%]{width:5px;height:40px;border-top-right-radius:5px;border-bottom-right-radius:5px;background-color:#f05d5e}.content-items[_ngcontent-%COMP%] ion-list[_ngcontent-%COMP%] ion-item[_ngcontent-%COMP%]:last-child{border-bottom:unset!important;padding-bottom:unset!important}@media only screen and (max-width: 800px){.content[_ngcontent-%COMP%]{width:100%!important}.aside-right[_ngcontent-%COMP%]{display:none}}@media only screen and (min-width: 801px){.menu-ptions[_ngcontent-%COMP%]{display:none}.content[_ngcontent-%COMP%]{width:65%;border-right:1px solid #d8d8d8}.aside-right[_ngcontent-%COMP%]{width:35%}}@media only screen and (min-width: 1024px){.content[_ngcontent-%COMP%]{width:70%}.aside-right[_ngcontent-%COMP%]{width:30%}}@media only screen and (min-width: 1140px){.content[_ngcontent-%COMP%]{width:75%}.aside-right[_ngcontent-%COMP%]{width:25%}}.option-desc[_ngcontent-%COMP%]{display:flex;color:#828282;width:100%;justify-content:space-between;align-items:center;font-size:11pt}.option-desc[_ngcontent-%COMP%] .option-desc-line[_ngcontent-%COMP%]{height:1px;flex-grow:1;background-color:#e0e0e0;padding-left:4px}"]}),t})()},58970:function(t,e,n){"use strict";n.d(e,{e:function(){return a}});var o=n(37716),i=n(35957);let a=(()=>{class t{constructor(t,e){this.modalController=t,this.navParams=e,this.imageUrl=this.navParams.get("imageUrl")}ngOnInit(){}zoom(t){}close(){this.modalController.dismiss()}}return t.\u0275fac=function(e){return new(e||t)(o.Y36(i.IN),o.Y36(i.X1))},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-image-modal"]],decls:9,vars:1,consts:[["fullscreen",""],["lines","none","text-center","",1,"close"],["fill","clear",3,"click"],["name","close","slot","start"],[1,"swipper-zoom-container"],[3,"src"]],template:function(t,e){1&t&&(o.TgZ(0,"ion-content",0),o.TgZ(1,"ion-item",1),o.TgZ(2,"ion-button",2),o.NdJ("click",function(){return e.close()}),o.TgZ(3,"ion-icon",3),o._uU(4,"Fechar"),o.qZA(),o.qZA(),o.qZA(),o.TgZ(5,"ion-slides"),o.TgZ(6,"ion-slide"),o.TgZ(7,"div",4),o._UZ(8,"img",5),o.qZA(),o.qZA(),o.qZA(),o.qZA()),2&t&&(o.xp6(8),o.s9C("src",e.imageUrl,o.LSH))},directives:[i.W2,i.Ie,i.YG,i.gu,i.Hr,i.A$],styles:[".close[_ngcontent-%COMP%]{--background:transparent;margin-top:40px}.close[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{font-size:2rem}ion-content[_ngcontent-%COMP%]{--background:#ccc}ion-slides[_ngcontent-%COMP%]{height:80%}"]}),t})()},29777:function(t,e,n){"use strict";n.d(e,{i:function(){return Z}});var o=n(64762),i=n(45470),a=n(82316),s=n(3679),c=n(86807),r=n(37716),d=n(35957),l=n(61957),p=n(86704),g=n(84267),u=n(84465),h=n(38583);function m(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"div",19),r.TgZ(1,"ion-input",20),r.NdJ("ngModelChange",function(e){return r.CHM(t),r.oxw().pub.Title=e}),r.qZA(),r.qZA()}if(2&t){const t=r.oxw();let e;r.ekj("input-error",(null==t.Form||null==(e=t.Form.get("Subject"))?null:e.invalid)&&t.validateFrom),r.xp6(1),r.Q6J("ngModel",t.pub.Title)}}function f(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"div",21),r.TgZ(1,"div",22),r.TgZ(2,"div",23),r._UZ(3,"ion-icon",24),r.qZA(),r.TgZ(4,"div",25),r.TgZ(5,"ion-textarea",26),r.NdJ("ngModelChange",function(e){return r.CHM(t),r.oxw().pub.Message=e}),r.qZA(),r.qZA(),r.qZA(),r.qZA()}if(2&t){const t=r.oxw();let e;r.xp6(4),r.ekj("input-error",(null==t.Form||null==(e=t.Form.get("Message"))?null:e.invalid)&&t.validateFrom),r.xp6(1),r.Q6J("ngModel",t.pub.Message)}}function v(t,e){if(1&t){const t=r.EpF();r.TgZ(0,"div",7),r.TgZ(1,"ion-label",27),r._uU(2,"Fotografia Anexada"),r.qZA(),r.TgZ(3,"ion-item",28),r.TgZ(4,"ion-thumbnail",15),r.TgZ(5,"ion-img",29),r.NdJ("ngModelChange",function(e){return r.CHM(t),r.oxw().capturedImage=e}),r.qZA(),r.qZA(),r.TgZ(6,"ion-label"),r.TgZ(7,"p"),r._uU(8),r.qZA(),r.TgZ(9,"p",30),r._uU(10,"size"),r.qZA(),r.qZA(),r.TgZ(11,"ion-icon",31),r.NdJ("click",function(){return r.CHM(t),r.oxw().clear()}),r.qZA(),r.qZA(),r.qZA()}if(2&t){const t=r.oxw();r.xp6(5),r.Q6J("ngModel",t.capturedImage)("src","data:image/png;base64,"+t.capturedImage),r.xp6(3),r.Oqu(t.capturedImageTitle)}}let Z=(()=>{class t{constructor(t,e,n,o,s,c){this.modalController=t,this.photoService=e,this.navParams=n,this.publications=o,this.camera=s,this.toastService=c,this.disabled=!1,this.showSpinners=!0,this.showSeconds=!1,this.touchUi=!1,this.enableMeridian=!1,this.minDate=(new Date).toISOString().slice(0,10),this.endMinDate=new Date((new Date).getTime()+9e5),this.stepHour=1,this.stepMinute=5,this.stepSecond=5,this.color="primary",this.validateFrom=!1,this.pub=new i.S,this.image=new a.E,this.Defaultimage="",this.publicationType=this.navParams.get("publicationType"),this.folderId=this.navParams.get("folderId"),this.publicationTitle="Nova Publica\xe7\xe3o"}ngOnInit(){this.setTitle(),this.clear()}takePicture(){this.camera.getPicture({quality:90,destinationType:this.camera.DestinationType.DATA_URL,encodingType:this.camera.EncodingType.JPEG,mediaType:this.camera.MediaType.PICTURE,targetWidth:720,targetHeight:720}).then(t=>{this.capturedImage=t,this.capturedImageTitle=(new Date).getTime()+".jpeg"},t=>{})}getPicture(){this.camera.getPicture({quality:90,sourceType:this.camera.PictureSourceType.PHOTOLIBRARY,destinationType:this.camera.DestinationType.DATA_URL,encodingType:this.camera.EncodingType.JPEG,mediaType:this.camera.MediaType.PICTURE,targetWidth:720,targetHeight:720}).then(t=>{this.capturedImage=t,this.capturedImageTitle=(new Date).getTime()+".jpeg"},t=>{})}runValidation(){this.validateFrom=!0}injectValidation(){this.Form=new s.cw({Subject:new s.NI(this.pub.Title,[]),capturedImage:new s.NI(this.capturedImage,[]),Message:new s.NI(this.pub.Message,[s.kI.maxLength(1e3)])})}save(){return(0,o.mG)(this,void 0,void 0,function*(){if(this.injectValidation(),this.runValidation(),this.Form.invalid)return!1;if("3"==this.publicationType)if(console.log(this.navParams.get("publication")),""!=this.capturedImage){this.publication={DateIndex:this.publication.DateIndex,DocumentId:this.publication.DocumentId,ProcessId:this.publication.ProcessId,Title:this.pub.Title,Message:this.pub.Message,DatePublication:this.publication.DatePublication,OriginalFileName:this.capturedImageTitle,FileBase64:this.capturedImage,FileExtension:"jpeg"};const e=this.toastService.loading();try{console.log(this.publication),yield this.publications.UpdatePublication(this.publication.ProcessId,this.publication).toPromise(),this.toastService.successMessage("Publica\xe7\xe3o criado"),this.close()}catch(t){this.toastService.badRequest("Publica\xe7\xe3o n\xe3o criado")}finally{e.remove()}}else if(this.publication.OriginalFileName){this.publication={DateIndex:this.publication.DateIndex,DocumentId:this.publication.DocumentId,ProcessId:this.publication.ProcessId,Title:this.pub.Title,Message:this.pub.Message,DatePublication:this.publication.DatePublication,OriginalFileName:this.capturedImageTitle,FileBase64:this.capturedImage,FileExtension:"jpeg"},console.log("Edit change image"),console.log(this.publication);const e=this.toastService.loading();try{yield this.publications.UpdatePublication(this.publication.ProcessId,this.publication).toPromise(),this.toastService.successMessage("Publica\xe7\xe3o criado"),this.close()}catch(t){this.toastService.badRequest("Publica\xe7\xe3o n\xe3o criado")}finally{e.remove()}}else{this.publication={DateIndex:this.publication.DateIndex,DocumentId:this.publication.DocumentId,ProcessId:this.publication.ProcessId,Title:this.pub.Title,Message:this.pub.Message,DatePublication:this.publication.DatePublication};const e=this.toastService.loading();try{console.log(this.publication),yield this.publications.UpdatePublication(this.publication.ProcessId,this.publication).toPromise(),this.toastService.successMessage("Publica\xe7\xe3o criado"),this.close()}catch(t){this.toastService.badRequest("Publica\xe7\xe3o n\xe3o criado")}finally{e.remove()}}else{const e=(0,c.formatDate)(new Date,"yyyy-MM-dd HH:mm:ss");console.log(e),this.publication={DateIndex:e,DocumentId:null,ProcessId:this.folderId,Title:this.pub.Title,Message:this.pub.Message,DatePublication:e,OriginalFileName:this.capturedImageTitle,FileBase64:this.capturedImage,FileExtension:"jpeg"};const n=this.toastService.loading();try{console.log(this.publication),yield this.publications.CreatePublication(this.folderId,this.publication).toPromise(),this.close(),this.toastService.successMessage("Publica\xe7\xe3o criado"),this.close()}catch(t){this.toastService.badRequest("Publica\xe7\xe3o n\xe3o criado")}finally{n.remove()}}})}close(){this.modalController.dismiss().then(()=>{this.showLoader=!0})}clear(){this.capturedImage=""}setTitle(){"1"==this.publicationType?this.publicationTitle="Nova Publica\xe7\xe3o R\xe1pida":"2"==this.publicationType?this.publicationTitle="Nova Publica\xe7\xe3o":"3"==this.publicationType&&(this.publicationTitle="Editar Publica\xe7\xe3o",this.pub=this.navParams.get("publication"),console.log(this.pub,"pub"))}}return t.\u0275fac=function(e){return new(e||t)(r.Y36(d.IN),r.Y36(l.T),r.Y36(d.X1),r.Y36(p.H),r.Y36(g.V1),r.Y36(u.k))},t.\u0275cmp=r.Xpm({type:t,selectors:[["app-new-publication"]],decls:33,vars:4,consts:[[1,"content-container"],[1,"title-content","width-100"],[1,"div-title"],[1,"title"],["class","ion-item-container",3,"input-error",4,"ngIf"],["class","container-div",4,"ngIf"],["class","ion-item-container-no-border",4,"ngIf"],[1,"ion-item-container-no-border"],[3,"click"],[1,"attach-icon"],["src","assets/images/icons-add-photo.svg"],[1,"attach-document"],["src","assets/images/icons-add-photos.svg"],[1,"ion-no-border"],[1,"footer-toolbar"],["slot","start"],["fill","clear","color","#061b52",1,"btn-cancel",3,"click"],["slot","end"],["fill","clear","color","#fff",1,"btn-ok",3,"click"],[1,"ion-item-container"],["name","title","ngDefaultControl","","placeholder","T\xedtulo",3,"ngModel","ngModelChange"],[1,"container-div"],[1,"ion-item-class-2"],[1,"ion-icon-class"],["slot","start","src","assets/images/icons-description.svg"],[1,"ion-textarea-class"],["name","description","ngDefaultControl","","rows","12","cols","20","placeholder","Corpo de texto...",3,"ngModel","ngModelChange"],[1,"attached-title"],["lines","none"],["name","image","ngDefaultControl","",3,"ngModel","src","ngModelChange"],["hidden",""],["name","close",3,"click"]],template:function(t,e){1&t&&(r.TgZ(0,"ion-content"),r.TgZ(1,"div",0),r.TgZ(2,"div",1),r.TgZ(3,"div",2),r.TgZ(4,"ion-label",3),r._uU(5),r.qZA(),r.qZA(),r.qZA(),r.YNc(6,m,2,3,"div",4),r.YNc(7,f,6,3,"div",5),r.YNc(8,v,12,3,"div",6),r.TgZ(9,"div",7),r.TgZ(10,"ion-label",8),r.NdJ("click",function(){return e.takePicture()}),r.TgZ(11,"div",9),r._UZ(12,"ion-icon",10),r.qZA(),r.TgZ(13,"div",11),r.TgZ(14,"ion-label"),r._uU(15,"Tirar Fotografia"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(16,"div",7),r.TgZ(17,"ion-label",8),r.NdJ("click",function(){return e.getPicture()}),r.TgZ(18,"div",9),r._UZ(19,"ion-icon",12),r.qZA(),r.TgZ(20,"div",11),r.TgZ(21,"ion-label"),r._uU(22,"Anexar Fotografia"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.TgZ(23,"ion-footer",13),r.TgZ(24,"ion-toolbar",14),r.TgZ(25,"ion-buttons",15),r.TgZ(26,"ion-button",16),r.NdJ("click",function(){return e.close()}),r.TgZ(27,"ion-label"),r._uU(28,"Cancelar"),r.qZA(),r.qZA(),r.qZA(),r.TgZ(29,"ion-buttons",17),r.TgZ(30,"ion-button",18),r.NdJ("click",function(){return e.save()}),r.TgZ(31,"ion-label"),r._uU(32,"Gravar"),r.qZA(),r.qZA(),r.qZA(),r.qZA(),r.qZA()),2&t&&(r.xp6(5),r.Oqu(e.publicationTitle),r.xp6(1),r.Q6J("ngIf","1"!=e.publicationType),r.xp6(1),r.Q6J("ngIf","1"!=e.publicationType),r.xp6(1),r.Q6J("ngIf",""!=e.capturedImage))},directives:[d.W2,d.Q$,h.O5,d.gu,d.fr,d.sr,d.Sm,d.YG,d.pK,d.j9,s.Fj,s.JJ,s.On,d.g2,d.Ie,d.Bs,d.Xz],styles:["[_nghost-%COMP%]{background:#0782c9}ion-content[_ngcontent-%COMP%]{--background:transparent;transform:translate3d(0,5px,0);--border-radius:30px}ion-footer[_ngcontent-%COMP%]{background:#fff}ion-toolbar[_ngcontent-%COMP%]{border-width:0!important}.div-top-header[_ngcontent-%COMP%]{margin:0 auto;background-color:#0782c9;overflow:auto;padding-top:15px;border:0!important}.div-search[_ngcontent-%COMP%]{font-size:45px;float:left;margin:0 0 0 10px}.div-logo[_ngcontent-%COMP%]{background:transparent;width:140px;margin:5px 0 0 71px;float:left}.div-logo[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:100%}.div-profile[_ngcontent-%COMP%]{font-size:45px;float:right;margin-right:10px}.content-top[_ngcontent-%COMP%]{background:#f3f2f2;height:20px}.content-container[_ngcontent-%COMP%], .content-top[_ngcontent-%COMP%]{margin:0 auto;border-top-left-radius:25px;border-top-right-radius:25px}.content-container[_ngcontent-%COMP%]{width:100%;background:#fff;height:100%;box-shadow:0 0 18px rgba(0,0,0,.6);padding:25px 20px 0;overflow:auto}.title-content[_ngcontent-%COMP%]{margin:0 auto;overflow:auto;padding:0!important}.div-title[_ngcontent-%COMP%]{width:270px;float:left;margin:2.5px 0 0 5px}.title[_ngcontent-%COMP%]{font-size:25px}.container-div[_ngcontent-%COMP%]{margin-bottom:15px;overflow:auto}.ion-item-container[_ngcontent-%COMP%]{margin:15px auto;border:1px solid #ebebeb;border-radius:5px;padding-left:10px}.ion-item-container-no-border[_ngcontent-%COMP%]{width:100%;margin:0 auto;padding:0!important;overflow:auto}.ion-item-class-2[_ngcontent-%COMP%]{margin:0 auto;display:flex}.ion-icon-class[_ngcontent-%COMP%]{width:45px;height:45px;float:left;padding:10px;font-size:25px}.ion-textarea-class[_ngcontent-%COMP%]{width:315px;height:auto;border:1px solid #ebebeb;border-radius:5px;padding-left:5px;padding-right:10px;flex:1}.ion-input-class-no-height[_ngcontent-%COMP%]{border:1px solid #ebebeb;border-radius:5px;overflow:auto}.attach-document[_ngcontent-%COMP%]{font-size:15px;color:#0d89d1;margin:5px 5px 20px 10px;padding:5px;float:left}.attach-icon[_ngcontent-%COMP%]{width:37px;font-size:35px;float:left}.attached-title[_ngcontent-%COMP%]{font-family:Roboto;font-size:15px;font-weight:700;font-stretch:normal;font-style:normal;line-height:normal;letter-spacing:normal;color:#000}"]}),t})()},51230:function(t,e,n){"use strict";n.d(e,{e:function(){return f}});var o=n(64762),i=n(58970),a=n(29777),s=n(37716),c=n(35957),r=n(86704),d=n(84465),l=n(39895);function p(t,e){1&t&&s._UZ(0,"ion-progress-bar",10)}function g(t,e){if(1&t){const t=s.EpF();s.TgZ(0,"div",21),s.TgZ(1,"img",22),s.NdJ("click",function(){s.CHM(t);const e=s.oxw(2);return e.openPreview(e.publication.FileBase64)}),s.qZA(),s.qZA()}if(2&t){const t=s.oxw(2);s.xp6(1),s.s9C("src",t.publication.FileBase64,s.LSH)}}function u(t,e){1&t&&(s.TgZ(0,"div",21),s._UZ(1,"img",23),s.qZA())}function h(t,e){if(1&t){const t=s.EpF();s.TgZ(0,"div",11),s.TgZ(1,"div",12),s.TgZ(2,"div",13),s.NdJ("click",function(){return s.CHM(t),s.oxw().goBack()}),s._UZ(3,"ion-icon",14),s.qZA(),s.TgZ(4,"div",15),s.TgZ(5,"ion-label",16),s._uU(6),s.qZA(),s.TgZ(7,"p",17),s._uU(8),s.ALo(9,"date"),s.qZA(),s.qZA(),s.qZA(),s.TgZ(10,"div",18),s.YNc(11,g,2,1,"div",19),s.YNc(12,u,2,0,"div",19),s.TgZ(13,"div",20),s.TgZ(14,"p"),s._uU(15),s.qZA(),s.qZA(),s.qZA(),s.qZA()}if(2&t){const t=s.oxw();s.xp6(6),s.hij(" ",t.publication.Title,""),s.xp6(2),s.Oqu(s.xi3(9,5,t.publication.DatePublication,"dd-MM-yy | h:mm")),s.xp6(3),s.Q6J("ngIf",t.publication.FileBase64.length>30),s.xp6(1),s.Q6J("ngIf",t.publication.FileBase64.length<30),s.xp6(3),s.Oqu(t.publication.Message)}}function m(t,e){if(1&t){const t=s.EpF();s.TgZ(0,"div",11),s.TgZ(1,"div",24),s.TgZ(2,"div",25),s.TgZ(3,"ion-icon",26),s.NdJ("click",function(){return s.CHM(t),s.oxw().close()}),s.qZA(),s.qZA(),s.TgZ(4,"div",15),s.TgZ(5,"ion-label",16),s._UZ(6,"ion-skeleton-text",27),s.qZA(),s.TgZ(7,"p",17),s._UZ(8,"ion-skeleton-text",28),s.qZA(),s.qZA(),s.qZA(),s.TgZ(9,"div",18),s.TgZ(10,"div",21),s._UZ(11,"img",23),s.qZA(),s.TgZ(12,"div",29),s.TgZ(13,"p"),s._UZ(14,"ion-skeleton-text",30),s.qZA(),s.TgZ(15,"p"),s._UZ(16,"ion-skeleton-text",30),s.qZA(),s.qZA(),s.qZA(),s.qZA()}}let f=(()=>{class t{constructor(t,e,n,o,i,a){this.modalController=t,this.publications=e,this.animationController=n,this.toastService=o,this.activatedRoute=i,this.router=a,this.isModal=!1,this.activatedRoute.paramMap.subscribe(t=>{console.log(t),t.params&&(this.folderId=t.params.folderId,this.publicationId=t.params.publicationId,console.log(t.params))}),this.publication={DateIndex:null,DocumentId:"",ProcessId:"",Title:"",Message:"",DatePublication:null,FileBase64:"",OriginalFileName:"",FileExtension:""}}ngOnInit(){this.getPublicationDetail()}doRefresh(t){this.getPublicationDetail(),setTimeout(()=>{t.target.complete()},2e3)}getPublicationDetail(){this.showLoader=!0,console.log(this.publicationId),this.publications.GetPublicationById(this.publicationId).subscribe(t=>{console.log(t),this.publication={DateIndex:t.DateIndex,DocumentId:t.DocumentId,ProcessId:t.ProcessId,Title:t.Title,Message:t.Message,DatePublication:t.DatePublication,FileBase64:"data:image/jpg;base64,"+t.FileBase64,OriginalFileName:t.OriginalFileName,FileExtension:"jpeg"},this.showLoader=!1})}close(){this.modalController.dismiss()}goBack(){this.isModal?this.close():this.router.navigate(["/home/publications",this.folderId])}deletePost(){return(0,o.mG)(this,void 0,void 0,function*(){const t=this.toastService.loading();try{yield this.publications.DeletePublication(this.folderId,this.publicationId).toPromise(),this.toastService.successMessage("Publica\xe7ao eliminado"),this.close()}catch(e){this.toastService.badRequest("Publica\xe7ao n\xe3o eliminado")}finally{t.remove()}})}editPost(t){return(0,o.mG)(this,void 0,void 0,function*(){console.log(this.publication);const e=yield this.modalController.create({component:a.i,componentProps:{publicationType:t,publication:this.publication,folderId:this.folderId},cssClass:"new-publication modal modal-desktop",backdropDismiss:!1});yield e.present(),e.onDidDismiss().then(()=>{setTimeout(()=>{this.getPublicationDetail()},5e3)})})}openPreview(t){this.modalController.create({component:i.e,componentProps:{imageUrl:t}}).then(t=>t.present())}}return t.\u0275fac=function(e){return new(e||t)(s.Y36(c.IN),s.Y36(r.H),s.Y36(c.vB),s.Y36(d.k),s.Y36(l.gz),s.Y36(l.F0))},t.\u0275cmp=s.Xpm({type:t,selectors:[["app-publication-detail"]],decls:19,vars:3,consts:[[1,"ion-no-border","d-md-none"],["name","refresher","slot","fixed",3,"ionRefresh"],["type","indeterminate",4,"ngIf"],[1,"content-container"],["class","d-flex flex-column",4,"ngIf"],[1,"footer-toolbar"],["slot","start"],["fill","clear","color","#ffe0e0",1,"btn-delete",3,"click"],["slot","end"],["fill","clear","color","#fff",1,"btn-ok",3,"click"],["type","indeterminate"],[1,"d-flex","flex-column"],[1,"title-content","px-20","width-100"],[1,"back-icon","cursor-pointer",3,"click"],["slot","end","src","assets/images/icons-arrow-arrow-left.svg"],[1,"div-title"],[1,"title"],[1,"post-data"],[1,"post-item","overflow-y-auto"],["class","post-img",4,"ngIf"],[1,"post-description","px-20"],[1,"post-img"],["alt","image","tappable","",3,"src","click"],["src","/assets/icon/icon-no-image.svg","alt","image"],[1,"title-content","width-100"],[1,"back-icon","cursor-pointer"],["slot","end","src","assets/images/icons-arrow-arrow-left.svg",3,"click"],["animated","",2,"width","60%"],["animated","",2,"width","20%"],[1,"post-description"],["animated",""]],template:function(t,e){1&t&&(s.TgZ(0,"ion-header",0),s._UZ(1,"app-header"),s.qZA(),s.TgZ(2,"ion-content"),s.TgZ(3,"ion-refresher",1),s.NdJ("ionRefresh",function(t){return e.doRefresh(t)}),s.YNc(4,p,1,0,"ion-progress-bar",2),s._UZ(5,"ion-refresher-content"),s.qZA(),s.TgZ(6,"div",3),s.YNc(7,h,16,8,"div",4),s.YNc(8,m,17,0,"div",4),s.qZA(),s.qZA(),s.TgZ(9,"ion-footer"),s.TgZ(10,"ion-toolbar",5),s.TgZ(11,"ion-buttons",6),s.TgZ(12,"ion-button",7),s.NdJ("click",function(){return e.deletePost()}),s.TgZ(13,"ion-label"),s._uU(14,"Eliminar"),s.qZA(),s.qZA(),s.qZA(),s.TgZ(15,"ion-buttons",8),s.TgZ(16,"ion-button",9),s.NdJ("click",function(){return e.editPost("3")}),s.TgZ(17,"ion-label"),s._uU(18,"Editar"),s.qZA(),s.qZA(),s.qZA(),s.qZA(),s.qZA()),2&t&&(s.xp6(4),s.Q6J("ngIf",e.showLoader),s.xp6(3),s.Q6J("ngIf",""!=e.publication.Title),s.xp6(1),s.Q6J("ngIf",""==e.publication.Title))},styles:["ion-content[_ngcontent-%COMP%]{--background:transparent;transform:translate3d(0,5px,0);--border-radius:30px}ion-footer[_ngcontent-%COMP%]{background:#fff}ion-toolbar[_ngcontent-%COMP%]{border-width:0!important}.div-top-header[_ngcontent-%COMP%]{margin:0 auto;background-color:#0782c9;overflow:auto;padding-top:15px;border:0!important}.div-search[_ngcontent-%COMP%]{font-size:45px;float:left;margin:0 0 0 10px}.div-logo[_ngcontent-%COMP%]{background:transparent;width:140px;margin:5px 0 0 71px;float:left}.div-logo[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:100%}.div-profile[_ngcontent-%COMP%]{font-size:45px;float:right;margin-right:10px}.content-top[_ngcontent-%COMP%]{background:#f3f2f2;height:20px}.content-container[_ngcontent-%COMP%], .content-top[_ngcontent-%COMP%]{margin:0 auto;border-top-left-radius:25px;border-top-right-radius:25px}.content-container[_ngcontent-%COMP%]{width:100%;background:#fff;height:100%;box-shadow:0 0 18px rgba(0,0,0,.6);padding:25px 0 0;overflow:auto}.title-content[_ngcontent-%COMP%]{margin:0 auto;overflow:auto}.back-icon[_ngcontent-%COMP%]{width:auto;float:left;font-size:35px;overflow:auto}.div-title[_ngcontent-%COMP%]{float:left;margin:2.5px 0 0 5px}.title[_ngcontent-%COMP%]{font-size:25px}.post-img[_ngcontent-%COMP%]{width:100%;height:400px;margin:0 auto;border-radius:0!important;overflow:hidden}.post-img[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:100%;height:100%;-o-object-fit:cover;object-fit:cover}.post-description[_ngcontent-%COMP%]{margin:0 auto 35px}"]}),t})()},57363:function(t,e,n){"use strict";n.d(e,{k:function(){return g}});var o=n(37716),i=n(35957),a=n(91841),s=n(92340),c=n(37556);let r=(()=>{class t{constructor(t,e){this.http=t,this.authheader={},this.loggeduser=e.ValidatedUser,this.headers=new a.WM,this.headers=this.headers.set("Authorization",this.loggeduser.BasicAuthKey)}getOrganicEntity(){return this.http.get(s.N.apiURL+"ecm/organic",{headers:this.headers})}}return t.\u0275fac=function(e){return new(e||t)(o.LFG(a.eN),o.LFG(c.e))},t.\u0275prov=o.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();var d=n(3679),l=n(38583);function p(t,e){if(1&t){const t=o.EpF();o.TgZ(0,"li",9),o.NdJ("click",function(){const e=o.CHM(t).$implicit;return o.oxw().selectOrganicEntidy(e.Description)}),o._uU(1),o.qZA()}if(2&t){const t=e.$implicit;o.xp6(1),o.hij(" ",t.Description," ")}}let g=(()=>{class t{constructor(t,e){this.modalController=t,this.OrganicEntityService=e}ngOnInit(){this.getOrganicEntity()}getOrganicEntity(){this.OrganicEntityService.getOrganicEntity().subscribe(t=>{console.log(t),this.organicEntities=t,this.showOrganicEntities=t})}filterContact(){const t=this.findEntity.toLowerCase(),e=this.organicEntities.filter(e=>{if(0==e.Description.toLowerCase().indexOf(t))return!0});this.showOrganicEntities=e}selectOrganicEntidy(t){this.modalController.dismiss(t)}close(){this.modalController.dismiss()}}return t.\u0275fac=function(e){return new(e||t)(o.Y36(i.IN),o.Y36(r))},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-organic-entity"]],decls:14,vars:2,consts:[[1,"main-header"],[1,"main-header","d-flex"],[1,"d-flex","align-center"],[1,"icon",3,"click"],["src","assets/images/icons-arrow-arrow-left.svg",2,"font-size","35px"],[1,"main-container"],[1,"input-text","d-flex","ion-align-items-center"],["type","search","placeholder","Pesquisar",1,"search-input",3,"ngModel","ngModelChange"],[3,"click",4,"ngFor","ngForOf"],[3,"click"]],template:function(t,e){1&t&&(o._UZ(0,"ion-header",0),o.TgZ(1,"ion-toolbar",1),o.TgZ(2,"div",2),o.TgZ(3,"div",3),o.NdJ("click",function(){return e.close()}),o._UZ(4,"ion-icon",4),o.qZA(),o.TgZ(5,"div"),o.TgZ(6,"ion-title"),o._uU(7,"Entidade Org\xe2nica"),o.qZA(),o.qZA(),o.qZA(),o.qZA(),o.TgZ(8,"ion-content"),o.TgZ(9,"div",5),o.TgZ(10,"div",6),o.TgZ(11,"ion-input",7),o.NdJ("ngModelChange",function(t){return e.findEntity=t})("ngModelChange",function(){return e.filterContact()}),o.qZA(),o.qZA(),o.TgZ(12,"ul"),o.YNc(13,p,2,1,"li",8),o.qZA(),o.qZA(),o.qZA()),2&t&&(o.xp6(11),o.Q6J("ngModel",e.findEntity),o.xp6(2),o.Q6J("ngForOf",e.showOrganicEntities))},directives:[i.Gu,i.sr,i.gu,i.wd,i.W2,i.pK,i.j9,d.JJ,d.On,l.sg],styles:[".icon[_ngcontent-%COMP%], .main-header[_ngcontent-%COMP%]{display:flex;align-items:center}.icon[_ngcontent-%COMP%]{color:#797979;width:45px;height:45px;justify-content:center;font-size:25px}.main-container[_ngcontent-%COMP%]{padding:0 20px}.main-container[_ngcontent-%COMP%] .input-text[_ngcontent-%COMP%]{margin-top:20px;width:100%;height:45px;border-radius:5px;border:1px solid #ebebeb}.main-container[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{margin:0;padding:10px 0 0}.main-container[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{padding-top:10px;margin:0;padding-bottom:10px;border-bottom:1px solid #ebebeb;list-style:none;font-family:Roboto;font-size:15px}"]}),t})()},4528:function(t,e,n){"use strict";n.d(e,{Z:function(){return J}});var o=n(64762),i=n(38583),a=n(35161),s=n(57363),c=n(27538),r=n.n(c),d=n(75008),l=n(51230),p=n(33289),g=n(23066),u=n(37716),h=n(35957),m=n(91841),f=n(92340),v=n(37556);let Z=(()=>{class t{constructor(t,e){this.http=t,this.authheader={},this.categories=Array,this.loggeduser=e.ValidatedUser,this.headers=new m.WM,this.headers=this.headers.set("Authorization",this.loggeduser.BasicAuthKey)}basicSearch(t,e=null,n=null,o=null,i=null,a){const s=f.N.apiURL+"search";let c=new m.LE;return console.log(t),c=c.set("assunto",t),c=c.set("data",e),c=c.set("remetente",n),c=c.set("entidadeOrganica",o),c=c.set("docTypeId",i),c=c.set("applicationType",a),this.http.get(`${s}`,{headers:this.headers,params:c})}mostSeachWord(t){let e=this.loggeduser.UserId.toString();const n=f.N.apiURL+"Processes/GetHitsByUserId";let o=new m.LE;return o=o.set("userId",e),o=o.set("size",t),this.http.get(`${n}`,{headers:this.headers,params:o})}searchForDoc(t,e,n,o,i,a){const s=f.N.apiURL+"search/attachment?";let c=new m.LE;return console.log(t),c=c.set("assunto",t),c=c.set("data",e),c=c.set("remetente",n),c=c.set("entidadeOrganica",o),c=c.set("docTypeId",i),c=c.set("applicationType",a),this.http.get(`${s}`,{headers:this.headers,params:c})}}return t.\u0275fac=function(e){return new(e||t)(u.LFG(m.eN),u.LFG(v.e))},t.\u0275prov=u.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})();var x=n(3679);function C(t,e){1&t&&u._UZ(0,"ion-progress-bar",23)}function M(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",24),u.NdJ("click",function(){return u.CHM(t),u.oxw().showHideAdvanceSearch(!0)}),u._UZ(1,"ion-icon",25),u.qZA()}}function b(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",26),u.NdJ("click",function(){return u.CHM(t),u.oxw().showHideAdvanceSearch(!1)}),u._UZ(1,"ion-icon",27),u.qZA()}}function P(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",28),u.TgZ(1,"button",5),u.NdJ("click",function(){return u.CHM(t),u.oxw().close()}),u._UZ(2,"ion-icon",29),u.qZA(),u.qZA()}}function A(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",30),u.TgZ(1,"li",31),u.TgZ(2,"div",32),u._UZ(3,"ion-icon",33),u.qZA(),u.TgZ(4,"div",34),u.TgZ(5,"ion-datetime",35),u.NdJ("ngModelChange",function(e){return u.CHM(t),u.oxw().searchDocumentDate=e}),u.qZA(),u.TgZ(6,"div",36),u.NdJ("click",function(){return u.CHM(t),u.oxw().clearInputDocumentDate()}),u._UZ(7,"ion-icon",37),u.qZA(),u.qZA(),u.qZA(),u.TgZ(8,"li",31),u.TgZ(9,"div",32),u._UZ(10,"ion-icon",38),u.qZA(),u.TgZ(11,"div",34),u.TgZ(12,"ion-input",39),u.NdJ("ngModelChange",function(e){return u.CHM(t),u.oxw().searchSender=e})("click",function(){return u.CHM(t),u.oxw().openAdvanceSearchSelection()}),u.qZA(),u.TgZ(13,"div",36),u.NdJ("click",function(){return u.CHM(t),u.oxw().clearInputRemetente()}),u._UZ(14,"ion-icon",37),u.qZA(),u.qZA(),u.qZA(),u.TgZ(15,"li",31),u.TgZ(16,"div",32),u._UZ(17,"ion-icon",40),u.qZA(),u.TgZ(18,"div",34),u.TgZ(19,"ion-input",41),u.NdJ("ngModelChange",function(e){return u.CHM(t),u.oxw().searchOrganicEntiry=e})("click",function(){return u.CHM(t),u.oxw().openOrganicEntitySelection()}),u.qZA(),u.TgZ(20,"div",36),u.NdJ("click",function(){return u.CHM(t),u.oxw().clearInputOrganicEntity()}),u._UZ(21,"ion-icon",37),u.qZA(),u.qZA(),u.qZA(),u.qZA()}if(2&t){const t=u.oxw();u.xp6(5),u.Q6J("ngModel",t.searchDocumentDate),u.xp6(7),u.Q6J("ngModel",t.searchSender),u.xp6(7),u.Q6J("ngModel",t.searchOrganicEntiry)}}const w=function(t){return{"active-category":t}};function T(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",47),u.NdJ("click",function(){const e=u.CHM(t).$implicit;return u.oxw(2).filterDocList(e.Name)})("click",function(){const e=u.CHM(t).index;return u.oxw(2).activeCategoty(e)}),u.TgZ(1,"span"),u._uU(2),u.qZA(),u.TgZ(3,"ion-label",48),u._uU(4),u.qZA(),u.qZA()}if(2&t){const t=e.$implicit;u.Q6J("ngClass",u.VKq(3,w,t.Active)),u.xp6(2),u.Oqu(t.Name),u.xp6(2),u.Oqu(t.Qtd)}}function _(t,e){if(1&t&&(u.TgZ(0,"div",42),u.TgZ(1,"div",43),u.TgZ(2,"div",44),u.YNc(3,T,5,5,"div",45),u.qZA(),u.TgZ(4,"button",46),u._UZ(5,"ion-icon",25),u.qZA(),u.qZA(),u.qZA()),2&t){const t=u.oxw();u.xp6(3),u.Q6J("ngForOf",t.searchCategories)}}function O(t,e){1&t&&(u.TgZ(0,"div",49),u.TgZ(1,"div",50),u.TgZ(2,"p",51),u._uU(3,"Assuntos mais recebidos"),u.qZA(),u._UZ(4,"div",52),u.qZA(),u.qZA())}function q(t,e){1&t&&(u.TgZ(0,"span",62),u._uU(1,"Mais Recentes"),u.qZA())}function k(t,e){1&t&&(u.TgZ(0,"span",62),u._uU(1,"Mais Antigos"),u.qZA())}function y(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",63),u.NdJ("click",function(){return u.CHM(t),u.oxw(2).reorderList("recent")}),u._UZ(1,"ion-icon",64),u.qZA()}}function D(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"div",63),u.NdJ("click",function(){return u.CHM(t),u.oxw(2).reorderList("old")}),u._UZ(1,"ion-icon",65),u.qZA()}}function I(t,e){1&t&&u._UZ(0,"ion-icon",76)}function S(t,e){1&t&&u._UZ(0,"ion-icon",77)}function N(t,e){1&t&&u._UZ(0,"ion-icon",78)}function F(t,e){if(1&t&&(u.TgZ(0,"span",79),u._uU(1),u.qZA()),2&t){const t=u.oxw().$implicit;u.xp6(1),u.Oqu(t.appName)}}function U(t,e){if(1&t){const t=u.EpF();u.TgZ(0,"li",66),u.NdJ("click",function(){const e=u.CHM(t).$implicit,n=u.oxw(2);return n.viewDetail(e),n.selectItem(e)}),u.TgZ(1,"div",4),u.YNc(2,I,1,0,"ion-icon",67),u.YNc(3,S,1,0,"ion-icon",68),u.YNc(4,N,1,0,"ion-icon",69),u.qZA(),u.TgZ(5,"div",70),u.TgZ(6,"div",71),u.TgZ(7,"span",72),u._uU(8),u.qZA(),u.YNc(9,F,2,1,"span",73),u.qZA(),u.TgZ(10,"div",71),u.TgZ(11,"span",74),u._uU(12),u.qZA(),u.TgZ(13,"span",75),u._uU(14),u.qZA(),u.qZA(),u.qZA(),u.qZA()}if(2&t){const t=e.$implicit,n=u.oxw(2);u.xp6(2),u.Q6J("ngIf","AccoesPresidenciais & ArquivoDespachoElect"==n.itemIcons()),u.xp6(1),u.Q6J("ngIf","Agenda"==n.itemIcons()),u.xp6(1),u.Q6J("ngIf","AccoesPresidenciais"==n.itemIcons()),u.xp6(4),u.Oqu(t.Assunto),u.xp6(1),u.Q6J("ngIf","AccoesPresidenciais & ArquivoDespachoElect"==n.itemIcons()),u.xp6(3),u.Oqu(t.EntidadeOrganicaNome),u.xp6(2),u.Oqu(n.formateIsoDate(t.Data))}}function E(t,e){if(1&t&&(u.TgZ(0,"div",53),u.TgZ(1,"div"),u.TgZ(2,"div",54),u.TgZ(3,"div",55),u.TgZ(4,"div",56),u.TgZ(5,"div",57),u.TgZ(6,"p"),u.TgZ(7,"span",58),u._uU(8,"Order por:"),u.qZA(),u.YNc(9,q,2,0,"span",59),u.YNc(10,k,2,0,"span",59),u.qZA(),u.qZA(),u.TgZ(11,"div"),u.YNc(12,y,2,0,"div",60),u.YNc(13,D,2,0,"div",60),u.qZA(),u.qZA(),u.qZA(),u.TgZ(14,"ul"),u.YNc(15,U,15,7,"li",61),u.qZA(),u.qZA(),u.qZA(),u.qZA()),2&t){const t=u.oxw();u.xp6(9),u.Q6J("ngIf","recent"==t.ordinance),u.xp6(1),u.Q6J("ngIf","old"==t.ordinance),u.xp6(2),u.Q6J("ngIf","old"==t.ordinance),u.xp6(1),u.Q6J("ngIf","recent"==t.ordinance),u.xp6(2),u.Q6J("ngForOf",t.showSearchDocuments)}}let J=(()=>{class t{constructor(t,e,n,o){this.modalController=t,this.search=e,this.modalCtrl=n,this.navParams=o,this.searchCategories=[],this.showSearchDocuments=[],this.searchDocuments=[],this.showDocuments=!1,this.showAdvanceSearch=!1,this.slideOpts={slidesPerView:parseInt(""+window.innerWidth/147,10),initialSlide:0,speed:400},this.list=[],this.type="Agenda",this.select=!1,this.showSearchInput=!1,this.ordinance="recent",this.currentPath=window.location.pathname,this.type=this.navParams.get("type"),this.type=this.navParams.get("type"),this.select=this.navParams.get("select"),this.showSearchInput=this.navParams.get("showSearchInput"),null!=this.type&&null!=this.type||("/home/agenda"==this.currentPath?this.type="Agenda":"/home/gabinete-digital"==this.currentPath?this.type="AccoesPresidenciais & ArquivoDespachoElect":"/home/publications"==this.currentPath?this.type="AccoesPresidenciais":console.log("search bug!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"))}selectItem(t){return this.select&&this.modalController.dismiss({selected:t}),this.select}ngOnInit(){this.wordCloud(),window.onresize=t=>{this.windowWidth=window.innerWidth,this.loadWordCloud()},this.windowWidth=window.innerWidth,window.dynamicSearch=t=>{this.searchSubject=t},window.searchTriger=()=>{this.basicSearch()}}wordCloud(){this.search.mostSeachWord("15").subscribe(t=>{document.querySelector(".seach-wrapper");const e=t[t.length-1].Hits,n=(t[0].Hits-e)/100;let o=[];t.forEach(t=>{const i=Object.values(t);i[1]=(i[1]-e)/n*55/100+9,o.push(i)}),this.list=o,console.log(this.list);const i=document.documentElement.querySelector(".most-searched-word-container");setTimeout(()=>{r()(i,{list:this.list,Family:"Times, serif",gridSize:15})},300)})}loadWordCloud(){setTimeout(()=>{const t=document.documentElement.querySelector(".most-searched-word-container");r()(t,{list:this.list,Family:"Times, serif",gridSize:15})},100)}close(){this.modalController.dismiss()}reorderList(t){this.ordinance=t,this.showSearchDocuments="recent"==this.ordinance?this.sortArrayISODate(this.searchDocuments).reverse():this.sortArrayISODate(this.searchDocuments)}sortArrayISODate(t){return t.sort(function(t,e){return t.Data<e.Data?-1:t.Data>e.Data?1:0})}basicSearch(){if("Agenda"==this.type)this.showLoader=!0,this.search.basicSearch(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"0").subscribe(t=>{console.log(t),t.Categories.forEach(t=>{t.Active=!1}),this.searchCategories=t.Categories,this.searchDocuments=this.sortArrayISODate(t.Documents),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,this.showLoader=!1,this.loadWordCloud()});else if("AccoesPresidenciais & ArquivoDespachoElect"==this.type)if(this.showLoader=!0,this.searchCategories=[],this.searchDocuments=[],this.showSearchDocuments=[],this.select){let t=0;this.search.searchForDoc(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"8").subscribe(e=>{e.Categories.forEach(t=>{t.Active=!1,this.searchCategories.push(t)}),this.sortArrayISODate(e.Documents).forEach(t=>{t.appName="Correspondencia",this.searchDocuments.push(t)}),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,t++,2==t&&(this.showLoader=!1),this.loadWordCloud()}),this.search.searchForDoc(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"361").subscribe(e=>{e.Categories.forEach(t=>{t.Active=!1,this.searchCategories.push(t)}),this.sortArrayISODate(e.Documents).forEach(t=>{t.appName="ArquivoDespachoElect",this.searchDocuments.push(t)}),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,this.loadWordCloud(),t++,2==t&&(this.showLoader=!1)})}else{let t=0;this.search.basicSearch(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"8").subscribe(e=>{e.Categories.forEach(t=>{t.Active=!1,this.searchCategories.push(t)}),this.sortArrayISODate(e.Documents).forEach(t=>{t.appName="Correspondencia",this.searchDocuments.push(t)}),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,t++,2==t&&(this.showLoader=!1),this.loadWordCloud()}),this.search.basicSearch(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"361").subscribe(e=>{e.Categories.forEach(t=>{t.Active=!1,this.searchCategories.push(t)}),this.sortArrayISODate(e.Documents).forEach(t=>{t.appName="ArquivoDespachoElect",this.searchDocuments.push(t)}),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,t++,2==t&&(this.showLoader=!1),this.loadWordCloud()})}else"AccoesPresidenciais"==this.type&&(this.showLoader=!0,this.search.basicSearch(this.searchSubject,this.searchDocumentDate,this.searchSender,this.searchOrganicEntiry,this.searchDocTypeId,"386").subscribe(t=>{console.log(t),t.Categories.forEach(t=>{t.Active=!1}),this.searchCategories=t.Categories,this.searchDocuments=this.sortArrayISODate(t.Documents),this.reorderList(this.ordinance),this.showDocuments=this.searchDocuments.length>=1,this.showLoader=!1,this.loadWordCloud()}))}clearSearchInput(){this.searchSubject="",this.searchCategories=[],this.searchDocuments=[],this.showDocuments=!1,this.wordCloud()}formateIsoDate(t){const e=new Date(t);return(0,i.p6)(e,"dd/MM/yyyy","pt")}activeCategoty(t){this.searchCategories.forEach((e,n)=>{t!=n&&(e.Active=!1)}),this.searchCategories[t].Active=!this.searchCategories[t].Active}clearInputRemetente(){this.searchSender=""}clearInputDocumentDate(){this.searchDocumentDate=""}clearInputOrganicEntity(){this.searchOrganicEntiry=""}showHideAdvanceSearch(t){this.showAdvanceSearch=t}openAdvanceSearchSelection(){return(0,o.mG)(this,void 0,void 0,function*(){let t;t=window.innerWidth<=1024?"modal modal-desktop":"search-desktop-modal search-submodal";const e=yield this.modalController.create({component:a.$,cssClass:t,componentProps:{}});yield e.present(),e.onDidDismiss().then(t=>{this.searchSender=t.data})})}openOrganicEntitySelection(){return(0,o.mG)(this,void 0,void 0,function*(){let t;t=window.innerWidth<=1024?"modal modal-desktop":"search-desktop-modal search-submodal";const e=yield this.modalController.create({component:s.k,cssClass:t,componentProps:{}});yield e.present(),e.onDidDismiss().then(t=>{this.searchOrganicEntiry=t.data})})}filterDocList(t){return(0,o.mG)(this,void 0,void 0,function*(){this.showSearchDocuments=this.showCategory==t?this.searchDocuments:this.searchDocuments.filter(e=>e.DocTypeDesc==t),this.showCategory=t})}itemIcons(){return this.type}viewDocument(){this.loadedAttachments.DocumentURL.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1")}viewDetail(t){return(0,o.mG)(this,void 0,void 0,function*(){const e=t.ApplicationType.toString(),n=t.Id;if(0==this.select)if("Agenda"==this.type){const t=yield this.modalCtrl.create({component:d.u,componentProps:{eventId:n,isModal:!0},cssClass:"modal modal-desktop"});yield t.present(),t.onDidDismiss().then(t=>{})}else"AccoesPresidenciais"==this.type?this.viewPublicationDetail(n):"AccoesPresidenciais & ArquivoDespachoElect"==this.type&&("8"!=e&&"361"!=e||this.viewDocumentDetail(n,e))})}viewPublicationDetail(t){return(0,o.mG)(this,void 0,void 0,function*(){const e=yield this.modalController.create({component:l.e,componentProps:{publicationId:t,isModal:!0},cssClass:"publication-detail modal modal-desktop "});yield e.present(),e.onDidDismiss().then(()=>{})})}viewDocumentDetail(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n;n=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const o=yield this.modalController.create({component:p.j,componentProps:{docId:t,applicationId:e},cssClass:n});yield o.present(),o.onDidDismiss().then(t=>{})})}openExpedientActionsModal(t){return(0,o.mG)(this,void 0,void 0,function*(){let e={serialNumber:t.SourceId,taskStartDate:t.CreateDate,isEvent:!0,workflowInstanceDataFields:{FsId:t.ApplicationId,FolderID:null,DocId:t.SourceId,Subject:t.SourceName}};const n=yield this.modalController.create({component:g.M,cssClass:"model aside-modal search-submodal",componentProps:{fulltask:e,task:e}});return yield n.present()})}}return t.\u0275fac=function(e){return new(e||t)(u.Y36(h.IN),u.Y36(Z),u.Y36(h.IN),u.Y36(h.X1))},t.\u0275cmp=u.Xpm({type:t,selectors:[["app-search"]],decls:24,vars:11,consts:[[1,"ion-no-border","header-main","d-md-flex","flex-md-row-reverse"],["type","indeterminate","class","loader",4,"ngIf"],[1,"top-box","d-flex","ion-justify-content-between"],[1,"d-flex","search-input-container","ion-justify-content-between"],[1,"icon"],[1,"btn-no-color",3,"click"],["slot","end","name","search",1,"icon-z"],[1,"input-text","d-flex","ion-align-items-center"],["type","search","placeholder","Pesquisar",1,"search-input",3,"ngModel","keyup.enter","ngModelChange"],[1,"d-flex","align-center","icon",3,"click"],["name","restaurant-outline","src","assets/images/icons-search-close.svg",1,"font-25"],["class","icon-z icon-most-searched-word-open",3,"click",4,"ngIf"],["class","icon-z icon-most-searched-word-open align-md-baseline pl-10",3,"click",4,"ngIf"],[1,"profile"],["src","assets/images/icons-profile.svg",1,"icon"],["class","btn-modal-dismiss",4,"ngIf"],["class","advance-search pa-0 pt-10 flex-md-grow-1",4,"ngIf"],["class","options flex-md-grow-1 ","style","border-bottom: 1px solid #f3f3f3;width: unset",4,"ngIf"],[1,"main-content"],[1,"height-100"],[1,"d-flex","seach-wrapper","height-100","flex-row","justify-space-between"],["class","d-flex height-100 overflow-y-auto flex-1","style","border-right: 1px solid #ddd7d7;",4,"ngIf"],["class"," height-100 overflow-y-auto flex-1",4,"ngIf"],["type","indeterminate",1,"loader"],[1,"icon-z","icon-most-searched-word-open",3,"click"],["src","assets/images/icons-most-searched-words-open.svg","slot","end",1,"icon"],[1,"icon-z","icon-most-searched-word-open","align-md-baseline","pl-10",3,"click"],["src","assets/images/advance-search-show-modal.svg","slot","end",1,"icon"],[1,"btn-modal-dismiss"],["src","assets/images/icons-search-close.svg",1,"icon"],[1,"advance-search","pa-0","pt-10","flex-md-grow-1"],[1,"d-flex","date-container","ion-justify-content-between"],[1,"icon-mer","icon"],["name","restaurant-outline","src","assets/images/icons-advance-search-document.svg"],[1,"input-container","d-flex","ion-align-items-center"],["placeholder","Data","display-timezone","utc",3,"ngModel","ngModelChange"],[1,"icon",3,"click"],["name","restaurant-outline","src","assets/images/icons-search-close.svg"],["name","restaurant-outline","src","assets/images/icons-advance-search-sender.svg"],["type","search","placeholder","Remetentes",1,"search-input",3,"ngModel","ngModelChange","click"],["name","restaurant-outline","src","assets/images/icons-arrow-arrow-down-25-copy.svg"],["type","search","placeholder","Entidade Org\xe2nica",1,"search-input",3,"ngModel","ngModelChange","click"],[1,"options","flex-md-grow-1",2,"border-bottom","1px solid #f3f3f3","width","unset"],[1,"container"],[1,"d-flex","overflow-x-auto"],["class","d-flex py-10","style","width:0px","class","button",3,"ngClass","click",4,"ngFor","ngForOf"],["ion-button","","icon-only","",1,"icon-z","icon-most-searched-word-open"],[1,"button",2,"width","0px",3,"ngClass","click"],[1,"label"],[1,"d-flex","height-100","overflow-y-auto","flex-1",2,"border-right","1px solid #ddd7d7"],[1,"most-searched-words","d-md-flex","flex-md-column"],[1,"title","ion-text-center"],[1,"most-searched-word-container","height-100","overflow-y-auto"],[1,"height-100","overflow-y-auto","flex-1"],[1,"search-result"],[1,"header"],[1,"d-flex","ion-justify-content-between","ion-align-items-center"],[1,"d-flex","sort-by","ion-justify-content-center"],[1,"order"],["class","order-labal",4,"ngIf"],[3,"click",4,"ngIf"],["class","d-flex cursor-pointer",3,"click",4,"ngFor","ngForOf"],[1,"order-labal"],[3,"click"],["src","assets/images/icons-arrow-arrow-up.svg"],["src","assets/images/icons-arrow-arrow-down-25.svg"],[1,"d-flex","cursor-pointer",3,"click"],["src","assets/images/icons-search-document.svg",4,"ngIf"],["src","assets/images/icons-default-agenda.svg",4,"ngIf"],["src","assets/images/icons-viagem.svg",4,"ngIf"],[1,"content","ion-align-items-center"],[1,"d-flex","ion-justify-content-between"],[1,"result-name"],["class","app-name",4,"ngIf"],[1,"organic-entity"],[1,"documente-date"],["src","assets/images/icons-search-document.svg"],["src","assets/images/icons-default-agenda.svg"],["src","assets/images/icons-viagem.svg"],[1,"app-name"]],template:function(t,e){1&t&&(u.TgZ(0,"ion-header",0),u.YNc(1,C,1,0,"ion-progress-bar",1),u.TgZ(2,"div",2),u.TgZ(3,"ion-form"),u.TgZ(4,"div",3),u.TgZ(5,"div",4),u.TgZ(6,"button",5),u.NdJ("click",function(){return e.basicSearch()}),u._UZ(7,"ion-icon",6),u.qZA(),u.qZA(),u.TgZ(8,"div",7),u.TgZ(9,"ion-input",8),u.NdJ("keyup.enter",function(){return e.basicSearch()})("ngModelChange",function(t){return e.searchSubject=t}),u.qZA(),u.qZA(),u.TgZ(10,"div",9),u.NdJ("click",function(){return e.clearSearchInput()}),u._UZ(11,"ion-icon",10),u.qZA(),u.qZA(),u.qZA(),u.YNc(12,M,2,0,"div",11),u.YNc(13,b,2,0,"div",12),u.TgZ(14,"div",13),u._UZ(15,"ion-icon",14),u.qZA(),u.YNc(16,P,3,0,"div",15),u.qZA(),u.YNc(17,A,22,3,"div",16),u.YNc(18,_,6,1,"div",17),u.qZA(),u.TgZ(19,"ion-content",18),u.TgZ(20,"div",19),u.TgZ(21,"div",20),u.YNc(22,O,5,0,"div",21),u.YNc(23,E,16,5,"div",22),u.qZA(),u.qZA(),u.qZA()),2&t&&(u.xp6(1),u.Q6J("ngIf",e.showLoader),u.xp6(2),u.ekj("d-none",!e.showSearchInput),u.xp6(6),u.Q6J("ngModel",e.searchSubject),u.xp6(3),u.Q6J("ngIf",!e.showAdvanceSearch),u.xp6(1),u.Q6J("ngIf",e.showAdvanceSearch),u.xp6(3),u.Q6J("ngIf",e.showSearchInput),u.xp6(1),u.Q6J("ngIf",e.showAdvanceSearch),u.xp6(1),u.Q6J("ngIf",e.showDocuments),u.xp6(4),u.Q6J("ngIf",!e.showDocuments||e.windowWidth>=1024),u.xp6(1),u.Q6J("ngIf",e.showDocuments))},directives:[h.Gu,i.O5,h.gu,h.pK,h.j9,x.JJ,x.On,h.W2,h.X7,h.x4,h.QI,i.sg,i.mk,h.Q$],styles:[".top-box[_ngcontent-%COMP%]{display:flex;align-content:center;align-items:center;justify-content:center}.header-main[_ngcontent-%COMP%]{padding:25px 18px 2px}.header-main[_ngcontent-%COMP%] ion-form[_ngcontent-%COMP%]{width:100%;padding-right:10px}.header-main[_ngcontent-%COMP%] .btn-modal-dismiss[_ngcontent-%COMP%]{display:flex;width:50px!important;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;padding:0!important;margin:5px 0 0 25px!important;align-content:center;align-items:center}.header-main[_ngcontent-%COMP%] .btn-modal-dismiss[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{font-size:32pt!important}.header-main[_ngcontent-%COMP%] .ion-align-content-center[_ngcontent-%COMP%]{align-content:center}.header-main[_ngcontent-%COMP%] .search-input-container[_ngcontent-%COMP%]{background-color:#fff;border-radius:27.5px;border:1px solid #ebebeb}.header-main[_ngcontent-%COMP%] .search-input-container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{color:#797979;width:45px;height:45px;display:flex;justify-content:center;font-size:25px;align-items:center}.header-main[_ngcontent-%COMP%] .search-input-container[_ngcontent-%COMP%] .input-text[_ngcontent-%COMP%]{width:100%}.header-main[_ngcontent-%COMP%] .search-input-container[_ngcontent-%COMP%] .icon-z[_ngcontent-%COMP%]{width:20px}.header-main[_ngcontent-%COMP%] .icon-z[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;font-size:45px}.header-main[_ngcontent-%COMP%] .profile[_ngcontent-%COMP%]{display:none;font-size:45px}ion-slide[_ngcontent-%COMP%]{padding-top:5px}.options[_ngcontent-%COMP%]{margin-top:10px}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%]{width:100%}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .button[_ngcontent-%COMP%]{min-width:116px;border:1px solid #e9e9e9;margin:0 5px 10px;padding:5px 20px;box-sizing:border-box;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;border-radius:15px}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{padding:0;margin:0;font-family:Roboto;color:#0d89d1;font-size:15px;text-align:center}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .button[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{width:100%;font-family:Roboto;font-size:13px;font-weight:300;color:#797979;text-align:center}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .active-category[_ngcontent-%COMP%]{background-color:#42b9fe;color:#fff}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .active-category[_ngcontent-%COMP%] .label[_ngcontent-%COMP%], .options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .d-flex[_ngcontent-%COMP%] .active-category[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:#fff}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{display:none;width:45px;height:45px;justify-content:center;align-items:center}.options[_ngcontent-%COMP%] .container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{width:25px}.d-flex[_ngcontent-%COMP%]{display:flex}.search-result[_ngcontent-%COMP%]{width:100%;border-bottom:unset;padding:0 20px}.search-result[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .sort-by[_ngcontent-%COMP%]{width:100%}.search-result[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .sort-by[_ngcontent-%COMP%] .order[_ngcontent-%COMP%]{font-family:Roboto;font-size:13px;font-weight:300;color:#797979}.search-result[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] .sort-by[_ngcontent-%COMP%] .order-labal[_ngcontent-%COMP%]{font-family:Roboto;font-size:15px;color:#0d89d1;margin-left:20px}.search-result[_ngcontent-%COMP%] .header[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{font-size:25px}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{padding:0;margin:0}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{padding-top:8px;padding-bottom:8px;border-top:1px solid #ebebeb;display:flex;align-items:center}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{font-size:35px;align-items:center;display:flex}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{width:100%;margin-left:10px}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] .result-name[_ngcontent-%COMP%]{margin:0;width:100%;font-family:Roboto;font-size:15px;color:#0d89d1;line-height:1.67}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-family:Roboto;font-size:13px;font-weight:300;color:#797979}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] .app-name[_ngcontent-%COMP%]{background:#42b9f2;border-radius:18px;text-align:center;display:flex;align-items:center;padding:0 5px;color:#fff;font-size:9pt;font-weight:500;height:19px;-webkit-border-radius:18px;-moz-border-radius:18px;-ms-border-radius:18px;-o-border-radius:18px}.search-result[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] span.organic-entity[_ngcontent-%COMP%]{width:100%}.most-searched-words[_ngcontent-%COMP%]{width:100%!important}.most-searched-words[_ngcontent-%COMP%] p.title[_ngcontent-%COMP%]{width:100%;height:24px;font-family:Roboto;font-size:20px;text-align:center;color:#000}.most-searched-words[_ngcontent-%COMP%] .most-searched-word-container[_ngcontent-%COMP%]{height:400px}@media only screen and (min-width: 1024px){.advance-search[_ngcontent-%COMP%]{max-width:47%}}.advance-search[_ngcontent-%COMP%]{padding:14px 20px 20px}.advance-search[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{color:#797979;width:45px;height:45px;display:flex;justify-content:center;font-size:25px;align-items:center}.advance-search[_ngcontent-%COMP%] .input-container[_ngcontent-%COMP%]{margin-bottom:15px;width:100%;border-radius:5px;border:1px solid #ebebeb}.advance-search[_ngcontent-%COMP%] .date-container[_ngcontent-%COMP%] .icon-mer[_ngcontent-%COMP%]{margin-right:10px}.advance-search[_ngcontent-%COMP%] ion-datetime[_ngcontent-%COMP%]{width:100%}.loader[_ngcontent-%COMP%]{position:absolute;margin-top:-14px;width:calc(100% - 39px)}.swiper-container[_ngcontent-%COMP%]{width:100%}"]}),t})()},35161:function(t,e,n){"use strict";n.d(e,{$:function(){return d}});var o=n(37716),i=n(35957),a=n(30407),s=n(3679),c=n(38583);function r(t,e){if(1&t){const t=o.EpF();o.TgZ(0,"li",8),o.NdJ("click",function(){const e=o.CHM(t).$implicit;return o.oxw().selectUser(e.Name)}),o._uU(1),o.qZA()}if(2&t){const t=e.$implicit;o.xp6(1),o.hij(" ",t.Name," ")}}let d=(()=>{class t{constructor(t,e){this.modalController=t,this.ContactsService=e}ngOnInit(){this.getSender()}getSender(){this.ContactsService.getContacts("").subscribe(t=>{this.contacts=t,this.showContacts=t})}filterContact(t){const e=this.sender.toLowerCase(),n=this.contacts.filter(t=>{if(0==t.Name.toLowerCase().indexOf(e))return!0});this.showContacts=n}selectUser(t){console.log(t),this.selectedUser=t,this.close(this.selectedUser)}close(t){this.modalController.dismiss(t)}}return t.\u0275fac=function(e){return new(e||t)(o.Y36(i.IN),o.Y36(a.P))},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-sender"]],decls:13,vars:2,consts:[[1,"main-header","d-flex"],[1,"d-flex","align-center"],[1,"icon",3,"click"],["src","assets/images/icons-arrow-arrow-left.svg",2,"font-size","35px"],[1,"main-container"],[1,"input-text","d-flex","ion-align-items-center"],["type","search","placeholder","Pesquisar",1,"search-input",3,"ngModel","ngModelChange"],[3,"click",4,"ngFor","ngForOf"],[3,"click"]],template:function(t,e){1&t&&(o.TgZ(0,"ion-toolbar",0),o.TgZ(1,"div",1),o.TgZ(2,"div",2),o.NdJ("click",function(){return e.close()}),o._UZ(3,"ion-icon",3),o.qZA(),o.TgZ(4,"div"),o.TgZ(5,"ion-title"),o._uU(6,"Remetentes"),o.qZA(),o.qZA(),o.qZA(),o.qZA(),o.TgZ(7,"ion-content"),o.TgZ(8,"div",4),o.TgZ(9,"div",5),o.TgZ(10,"ion-input",6),o.NdJ("ngModelChange",function(t){return e.sender=t})("ngModelChange",function(t){return e.filterContact(t)}),o.qZA(),o.qZA(),o.TgZ(11,"ul"),o.YNc(12,r,2,1,"li",7),o.qZA(),o.qZA(),o.qZA()),2&t&&(o.xp6(10),o.Q6J("ngModel",e.sender),o.xp6(2),o.Q6J("ngForOf",e.showContacts))},directives:[i.sr,i.gu,i.wd,i.W2,i.pK,i.j9,s.JJ,s.On,c.sg],styles:[".icon[_ngcontent-%COMP%], .main-header[_ngcontent-%COMP%]{display:flex;align-items:center}.icon[_ngcontent-%COMP%]{color:#797979;width:45px;height:45px;justify-content:center;font-size:25px}.main-container[_ngcontent-%COMP%]{padding:0 20px}.main-container[_ngcontent-%COMP%] .input-text[_ngcontent-%COMP%]{margin-top:20px;width:100%;height:45px;border-radius:5px;border:1px solid #ebebeb}.main-container[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{margin:0;padding:10px 0 0}.main-container[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{padding-top:10px;margin:0;padding-bottom:10px;border-bottom:1px solid #ebebeb;list-style:none;font-family:Roboto;font-size:15px}"]}),t})()},84393:function(t,e,n){"use strict";n.d(e,{G:function(){return i}});var o=n(37716);let i=(()=>{class t{transform(t){return null}transformToAttachment(t){const e=[];return 361==t.ApplicationType?e.push({ApplicationId:361,Source:1,SourceId:t.docID||t.docId||t.DocId||t.Id,SourceName:t.Assunto,SourceType:"FOLDER"}):8==t.ApplicationType&&e.push({ApplicationId:8,Source:1,SourceId:t.docID||t.docId||t.DocId||t.Id,SourceName:t.Assunto,SourceType:"WEBTRIX"}),e}}return t.\u0275fac=function(e){return new(e||t)},t.\u0275pipe=o.Yjl({name:"searchDocument",type:t,pure:!0}),t})()},61957:function(t,e,n){"use strict";n.d(e,{T:function(){return s}});var o=n(64762),i=n(37716),a=n(35957);let s=(()=>{class t{constructor(t){this.photos=[],this.PHOTO_STORAGE="photos",this.platform=t}takePicture(){return(0,o.mG)(this,void 0,void 0,function*(){})}}return t.\u0275fac=function(e){return new(e||t)(i.LFG(a.t4))},t.\u0275prov=i.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})()},86704:function(t,e,n){"use strict";n.d(e,{H:function(){return r}});var o=n(91841),i=n(92340),a=n(40205),s=n(37716),c=n(37556);let r=(()=>{class t{constructor(t,e){this.http=t,this.authheader={},this.loggeduser=e.ValidatedUser,this.headers=new o.WM,this.headers=this.headers.set("Authorization",this.loggeduser.BasicAuthKey)}GetPublicationFolderList(){return this.http.get(i.N.apiURL+"presidentialActions",{headers:this.headers})}GetPresidentialAction(t){return this.http.get(i.N.apiURL+"presidentialActions/"+t,{headers:this.headers})}UpdatePresidentialAction(t){return this.http.put(i.N.apiURL+"presidentialActions",t,{headers:this.headers})}CreatePublicationFolder(t){return this.http.post(i.N.apiURL+"presidentialActions",t,{headers:this.headers})}UpdatePublicationFolder(t){return this.http.put(i.N.apiURL+"presidentialActions",t,{headers:this.headers}).toPromise().then(t=>{console.log(t)})}DeletePresidentialAction(t){return this.http.delete(i.N.apiURL+"presidentialActions/"+t,{headers:this.headers})}GetPublications(t){const e=i.N.apiURL+"presidentialActions/"+t+"/posts";let n=new o.LE;return n=n.set("folderId",t),this.http.get(`${e}`,{headers:this.headers,params:n})}GetPublicationById(t){const e=i.N.apiURL+"presidentialActions/posts/"+t;return new o.LE,this.http.get(`${e}`,{headers:this.headers})}CreatePublication(t,e){const n=i.N.apiURL+"presidentialActions/"+t+"/posts";let a=new o.LE;return a=a.set("folderId",t),this.http.post(`${n}`,e,{headers:this.headers})}UpdatePublication(t,e){const n=i.N.apiURL+"presidentialActions/"+t+"/posts";let a=new o.LE;return a=a.set("folderId",t),this.http.put(`${n}`,e,{headers:this.headers})}DeletePublication(t,e){const n=i.N.apiURL+"presidentialActions/"+t+"/posts/"+e;let a=new o.LE;return a=a.set("folderId",t),a=a.set("id",e),this.http.delete(`${n}`,{headers:this.headers})}handleError(t){return(0,a._)(t||"Server Error")}}return t.\u0275fac=function(e){return new(e||t)(s.LFG(o.eN),s.LFG(c.e))},t.\u0275prov=s.Yz7({token:t,factory:t.\u0275fac,providedIn:"root"}),t})()},23890:function(t,e,n){"use strict";n.d(e,{E:function(){return a}});var o=n(37716),i=n(35957);let a=(()=>{class t{constructor(t){this.modalController=t}ngOnInit(){}close(){this.modalController.dismiss()}}return t.\u0275fac=function(e){return new(e||t)(o.Y36(i.IN))},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-btn-modal-dismiss"]],decls:3,vars:0,consts:[[1,"btn-modal-dismiss"],[1,"btn-no-color",3,"click"],["slot","end","src","assets/images/icons-arrow-arrow-left.svg"]],template:function(t,e){1&t&&(o.TgZ(0,"div",0),o.TgZ(1,"button",1),o.NdJ("click",function(){return e.close()}),o._UZ(2,"ion-icon",2),o.qZA(),o.qZA())},directives:[i.gu],styles:[".btn-modal-dismiss[_ngcontent-%COMP%]{width:37px;float:left;font-size:35px;overflow:hidden}"]}),t})()},1491:function(t,e,n){"use strict";n.d(e,{M:function(){return a}});var o=n(37716),i=n(35957);let a=(()=>{class t{constructor(){}ngOnInit(){}}return t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=o.Xpm({type:t,selectors:[["app-empty-container"]],inputs:{texto:"texto"},decls:4,vars:1,consts:[[1,"center","height-100"]],template:function(t,e){1&t&&(o.TgZ(0,"ion-content"),o.TgZ(1,"div",0),o.TgZ(2,"p"),o._uU(3),o.qZA(),o.qZA(),o.qZA()),2&t&&(o.xp6(3),o.Oqu(e.texto))},directives:[i.W2],styles:[".center[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}"]}),t})()},23066:function(t,e,n){"use strict";n.d(e,{M:function(){return A}});var o=n(64762),i=n(320),a=n(45896),s=n(83189),c=n(32379),r=n(4528),d=n(84393),l=n(37716),p=n(35957),g=n(28621),u=n(84465),h=n(39895),m=n(96529),f=n(20985),v=n(38583);function Z(t,e){if(1&t){const t=l.EpF();l.TgZ(0,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw(2).attachDocument()}),l._uU(1,"Anexar Documentos"),l.qZA()}}function x(t,e){if(1&t){const t=l.EpF();l.TgZ(0,"button",15),l.NdJ("click",function(){return l.CHM(t),l.oxw(2).sendExpedienteToPending()}),l._uU(1,"Enviar para pendentes"),l.qZA()}}const C=function(){return["PR"]};function M(t,e){if(1&t){const t=l.EpF();l.TgZ(0,"div",8),l.TgZ(1,"div",9),l.TgZ(2,"button",10),l._uU(3," Enviar para o PR "),l.qZA(),l.TgZ(4,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().openAddNoteModal("Aprovar")}),l._uU(5,"Avalia\xe7\xe3o Superior"),l.qZA(),l.TgZ(6,"button",10),l._uU(7," Solicitar revis\xe3o "),l.qZA(),l.TgZ(8,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().openAddNoteModal("Revis\xe3o")}),l._uU(9,"Mandar para Revis\xe3o"),l.qZA(),l.TgZ(10,"button",10),l._uU(11,"Outras op\xe7\xf5es "),l.qZA(),l.TgZ(12,"button",12),l.NdJ("click",function(){l.CHM(t);const e=l.oxw();return e.openExpedientActionsModal("0",e.fulltask)}),l._uU(13,"Efetuar Despacho"),l.qZA(),l.qZA(),l.TgZ(14,"div",9),l.TgZ(15,"button",11),l.NdJ("click",function(){l.CHM(t);const e=l.oxw();return e.openExpedientActionsModal("1",e.fulltask)}),l._uU(16,"Solicitar Parecer"),l.qZA(),l.TgZ(17,"button",11),l.NdJ("click",function(){l.CHM(t);const e=l.oxw();return e.openExpedientActionsModal("2",e.fulltask)}),l._uU(18,"Pedido de Deferimento"),l.qZA(),l.TgZ(19,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().openBookMeetingModal()}),l._uU(20,"Marcar Reuni\xe3o"),l.qZA(),l.YNc(21,Z,2,0,"button",13),l.TgZ(22,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().distartExpedientModal("descartar")}),l._uU(23,"Descartar"),l.qZA(),l.YNc(24,x,2,0,"button",14),l.qZA(),l.qZA()}if(2&t){const t=l.oxw();l.xp6(21),l.Q6J("ngIf",!t.p.userRole(l.DdM(2,C))),l.xp6(3),l.Q6J("ngIf","Pending"!=t.task.Status)}}function b(t,e){if(1&t){const t=l.EpF();l.TgZ(0,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw(2).sendExpedienteToPending()}),l._uU(1,"Enviar para Pendentes"),l.qZA()}}function P(t,e){if(1&t){const t=l.EpF();l.TgZ(0,"div",8),l.TgZ(1,"div",9),l.TgZ(2,"button",12),l.NdJ("click",function(){l.CHM(t);const e=l.oxw();return e.openExpedientActionsModal("0",e.fulltask)}),l._uU(3,"Efetuar Despacho"),l.qZA(),l.TgZ(4,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().distartExpedientModal("descartar")}),l._uU(5,"Descartar"),l.qZA(),l._UZ(6,"div",6),l.TgZ(7,"button",11),l.NdJ("click",function(){l.CHM(t);const e=l.oxw();return e.openExpedientActionsModal("1",e.fulltask)}),l._uU(8,"Solicitar Parecer"),l.qZA(),l.TgZ(9,"button",11),l.NdJ("click",function(){return l.CHM(t),l.oxw().openBookMeetingModal()}),l._uU(10,"Marcar Reuni\xe3o"),l.qZA(),l.YNc(11,b,2,0,"button",13),l._UZ(12,"div",16),l.TgZ(13,"button",17),l._uU(14,"Delegar"),l.qZA(),l.qZA(),l.qZA()}if(2&t){const t=l.oxw();l.xp6(11),l.Q6J("ngIf","Pending"!=t.task.Status)}}let A=(()=>{class t{constructor(t,e,n,o,i,a,s,c,r){this.popoverController=t,this.modalController=e,this.navParams=n,this.processes=o,this.toastService=i,this.router=a,this.activatedRoute=s,this.p=c,this.attachmentsService=r,this.showEnviarPendentes=!1,this.searchDocumentPipe=new d.G,this.documents=[],this.task=this.navParams.get("task"),this.fulltask=this.navParams.get("fulltask"),"Pending"!=this.task.Status&&(this.showEnviarPendentes=!0)}ngOnInit(){window.onresize=t=>{window.innerWidth>=800&&this.popoverController.dismiss()}}close(){window,this.popoverController.dismiss()}goBack(){"Pending"==this.task.Status&&"events"!=this.caller?window.innerWidth<=800?this.router.navigate(["/home/gabinete-digital/pendentes"]):this.router.navigate(["/home/gabinete-digital"],{queryParams:{pendentes:!0}}):window.history.back()}attachDocument(){this.getDoc()}getDoc(){return(0,o.mG)(this,void 0,void 0,function*(){const t=yield this.modalController.create({component:r.Z,cssClass:"modal-width-100-width-background modal",componentProps:{type:"AccoesPresidenciais & ArquivoDespachoElect",showSearchInput:!0,select:!0}});yield t.present(),t.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){t&&(this.documents.push(t.data.selected),this.documents.forEach(t=>{let e={InstanceID:this.task.InstanceID,WorkflowDisplayName:this.task.WorkflowName,FolderID:this.task.FolderId,DispatchNumber:this.task.DispatchNumber,AttachmentsProcessLastInstanceID:this.task.AttachmentsProcessLastInstanceID,Attachments:[]};const n=this.searchDocumentPipe.transformToAttachment(t);e.Attachments=n;const o=this.toastService.loading();this.attachmentsService.AddAttachment(e).subscribe(t=>{this.toastService.successMessage()},()=>{this.toastService.badRequest()},()=>{o.remove()})}),this.popoverController.dismiss())}))})}openAddNoteModal(t){return(0,o.mG)(this,void 0,void 0,function*(){let e;e=window.innerWidth<801?"modal modal-desktop":"add-note-modal";const n=yield this.modalController.create({component:i.C,componentProps:{showAttachmentBtn:!1},cssClass:e});yield n.present(),n.onDidDismiss().then(e=>(0,o.mG)(this,void 0,void 0,function*(){if(console.log(e),e.data){let n={ProcessInstanceID:"",Attachments:e.data.documents.map(t=>({ApplicationId:t.ApplicationType,SourceId:t.Id}))};"Aprovar"==t?yield this.approve(e.data.note,n):"Revis\xe3o"==t&&(yield this.sendToReview(e.data.note,n)),this.popoverController.dismiss(),this.goBack()}}))})}sendToReview(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n={serialNumber:this.task.serialnumber||this.task.SerialNumber,action:"Retificar",ActionTypeId:99999877,dataFields:{ReviewUserComment:t},AttachmentList:e};const o=this.toastService.loading();try{yield this.processes.CompleteTask(n).toPromise(),this.close(),this.toastService.successMessage()}catch(i){this.toastService.badRequest()}finally{o.remove()}})}sendExpedienteToPending(){this.close(),this.processes.SetTaskToPending(this.task.SerialNumber).subscribe(t=>{this.goBack()},()=>{this.toastService.badRequest("Processo n\xe3o encontrado")})}approve(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n={serialNumber:this.task.serialnumber||this.task.SerialNumber,action:"Aprovar",ActionTypeId:100000004,dataFields:{ReviewUserComment:t},AttachmentList:e};console.log(n);const o=this.toastService.loading();try{yield this.processes.CompleteTask(n).toPromise(),this.close(),this.toastService.successMessage("Processo aprovado")}catch(i){this.toastService.badRequest("Processo n\xe3o aprovado")}finally{o.remove()}})}openBookMeetingModal(){return(0,o.mG)(this,void 0,void 0,function*(){let t;this.close(),t=window.innerWidth<=800?"book-meeting-modal modal modal-desktop":"modal modal-desktop showAsideOptions";const e=yield this.modalController.create({component:s.k,componentProps:{task:this.task},cssClass:t,backdropDismiss:!1});yield e.present(),e.onDidDismiss()})}openExpedientActionsModal(t,e){return(0,o.mG)(this,void 0,void 0,function*(){let n;console.log(t,e),this.close(),n=window.innerWidth<=800?"modal modal-desktop":"modal modal-desktop showAsideOptions";const i=yield this.modalController.create({component:c.F,componentProps:{taskAction:t,task:e},cssClass:n});yield i.present(),i.onDidDismiss().then(t=>(0,o.mG)(this,void 0,void 0,function*(){console.log(t.data);let e=t.data;if(t.data){console.log("open discart");const t=this.toastService.loading();try{yield this.processes.CompleteTask(e).toPromise(),this.toastService.successMessage("Processo descartado"),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{t.remove()}}else console.log("Not open")}))})}distartExpedientModal(t){return(0,o.mG)(this,void 0,void 0,function*(){this.close();const e=yield this.modalController.create({component:a.Q,componentProps:{},cssClass:"discart-expedient-modal",backdropDismiss:!1});yield e.present(),e.onDidDismiss().then(e=>(0,o.mG)(this,void 0,void 0,function*(){if(console.log(e.data),"descartar"==t){if("Yes"==e.data){let t={serialNumber:this.task.SerialNumber,action:"Passivo",ActionTypeId:99999877,dataFields:{Note:""}};const e=this.toastService.loading();try{yield this.processes.CompleteTask(t).toPromise(),this.toastService.successMessage("Processo descartado"),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{e.remove()}}}else if("Yes"==e.data){const e=this.toastService.loading();try{yield this.processes.CompleteTask(t).toPromise(),this.toastService.successMessage("Processo descartado"),this.goBack()}catch(n){this.toastService.badRequest("Processo n\xe3o descartado")}finally{e.remove()}this.goBack()}else if("No"==e.data){console.log("Update");const t=this.toastService.loading();try{yield this.processes.UpdateTaskStatus(this.task.FolderId).toPromise(),this.toastService.successMessage(),this.goBack()}catch(n){this.toastService.badRequest()}finally{t.remove()}}}))})}}return t.\u0275fac=function(e){return new(e||t)(l.Y36(p.Dh),l.Y36(p.IN),l.Y36(p.X1),l.Y36(g.$),l.Y36(u.k),l.Y36(h.F0),l.Y36(h.gz),l.Y36(m.$),l.Y36(f.o))},t.\u0275cmp=l.Xpm({type:t,selectors:[["app-opts-expediente"]],decls:10,vars:4,consts:[[1,"container","width-100"],[1,"arrow-right",3,"click"],[1,"btn-no-color"],["slot","end","src","assets/images/icons-arrow-arrow-right.svg",1,"arrow-right-icon"],[1,"width-100"],["class","d-flex width-100",4,"ngIf"],[1,"solid"],["full","","shape","round",1,"btn-cancel",3,"click"],[1,"d-flex","width-100"],[1,"flex-grow-1"],["shape","round",1,"btn-cancel","desk"],["shape","round",1,"btn-cancel",3,"click"],["shape","round",1,"btn-ok",3,"click"],["class","btn-cancel","shape","round",3,"click",4,"ngIf"],["full","","class","btn-ok","shape","round",3,"click",4,"ngIf"],["full","","shape","round",1,"btn-ok",3,"click"],["hidden","",1,"solid"],["hidden","","shape","round",1,"btn-cancel"]],template:function(t,e){1&t&&(l.TgZ(0,"ion-content",0),l.TgZ(1,"div",1),l.NdJ("click",function(){return e.close()}),l.TgZ(2,"button",2),l._UZ(3,"ion-icon",3),l.qZA(),l.qZA(),l.TgZ(4,"div",4),l.YNc(5,M,25,3,"div",5),l.YNc(6,P,15,1,"div",5),l._UZ(7,"div",6),l.TgZ(8,"button",7),l.NdJ("click",function(){return e.close()}),l._uU(9,"Cancelar"),l.qZA(),l.qZA(),l.qZA()),2&t&&(l.xp6(5),l.Q6J("ngIf",e.task&&!e.p.userRole(l.DdM(2,C))),l.xp6(1),l.Q6J("ngIf",e.task&&e.p.userRole(l.DdM(3,C))))},directives:[p.W2,p.gu,v.O5],styles:[".container[_ngcontent-%COMP%]{--padding-top:20px!important;--padding-bottom:20px!important;--padding-start:20px!important;--padding-end:20px!important;width:100%}.arrow-right[_ngcontent-%COMP%]{display:none;margin-bottom:20px}.arrow-right[_ngcontent-%COMP%] .arrow-right-icon[_ngcontent-%COMP%]{width:37px;float:right;font-size:35px;overflow:hidden}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:space-around}.solid[_ngcontent-%COMP%]{display:none;width:90%;border-top:1px solid #bbb;margin:0 auto!important}.btn-cancel[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{margin-bottom:5px!important;margin-top:5px!important}@media only screen and (max-width: 800px){.btn-cancel[_ngcontent-%COMP%], .btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{width:100%!important}}@media only screen and (min-width: 1024px){.arrow-right[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.btn-cancel[_ngcontent-%COMP%]{display:none}.btn-cancel[_ngcontent-%COMP%], .btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{width:100%!important;margin-bottom:10px!important}.btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{margin-top:10px!important}}.desk[_ngcontent-%COMP%]{text-align:left;background-color:#fff}"]}),t})()},18057:function(t,e,n){"use strict";n.d(e,{S:function(){return g}});var o=n(64762),i=n(37716),a=n(35957),s=n(96529),c=n(38583);function r(t,e){if(1&t){const t=i.EpF();i.TgZ(0,"button",6),i.NdJ("click",function(){return i.CHM(t),i.oxw().openExpedientActionsModal("0")}),i._uU(1,"Efetuar Despacho"),i.qZA()}}function d(t,e){if(1&t){const t=i.EpF();i.TgZ(0,"button",6),i.NdJ("click",function(){return i.CHM(t),i.oxw().openExpedientActionsModal("0")}),i._uU(1,"Efetuar Despacho"),i.qZA()}}function l(t,e){if(1&t){const t=i.EpF();i.TgZ(0,"button",4),i.NdJ("click",function(){return i.CHM(t),i.oxw().openExpedientActionsModal("2")}),i._uU(1,"Pedido de Deferimento"),i.qZA()}}const p=function(){return["PR"]};let g=(()=>{class t{constructor(t,e,n,o){this.popoverController=t,this.modalController=e,this.navParams=n,this.p=o}ngOnInit(){this.task=this.navParams.get("task"),this.LoadedDocument=this.navParams.get("LoadedDocument")}close(){this.popoverController.dismiss()}goBack(){this.popoverController.dismiss()}openBookMeetingModal(){return(0,o.mG)(this,void 0,void 0,function*(){this.popoverController.dismiss({component:"openBookMeetingModal",taskAction:""})})}openExpedientActionsModal(t){return(0,o.mG)(this,void 0,void 0,function*(){this.popoverController.dismiss({component:"openExpedientActionsModal",taskAction:t})})}distartExpedientModal(t){return(0,o.mG)(this,void 0,void 0,function*(){})}}return t.\u0275fac=function(e){return new(e||t)(i.Y36(a.Dh),i.Y36(a.IN),i.Y36(a.X1),i.Y36(s.$))},t.\u0275cmp=i.Xpm({type:t,selectors:[["app-searched-document-options"]],decls:10,vars:6,consts:[[1,"container","width-100"],[1,"buttons"],["class","btn-ok","shape","round",3,"click",4,"ngIf"],[1,"solid"],["shape","round",1,"btn-cancel",3,"click"],["class","btn-cancel","shape","round",3,"click",4,"ngIf"],["shape","round",1,"btn-ok",3,"click"]],template:function(t,e){1&t&&(i.TgZ(0,"ion-content",0),i.TgZ(1,"div",1),i.YNc(2,r,2,0,"button",2),i.YNc(3,d,2,0,"button",2),i._UZ(4,"div",3),i.TgZ(5,"button",4),i.NdJ("click",function(){return e.openExpedientActionsModal("0")}),i._uU(6,"Solicitar Parecer"),i.qZA(),i.YNc(7,l,2,0,"button",5),i.TgZ(8,"button",4),i.NdJ("click",function(){return e.openBookMeetingModal()}),i._uU(9,"Marcar Reuni\xe3o"),i.qZA(),i.qZA(),i.qZA()),2&t&&(i.xp6(2),i.Q6J("ngIf",e.p.userRole(i.DdM(3,p))),i.xp6(1),i.Q6J("ngIf",!e.p.userRole(i.DdM(4,p))),i.xp6(4),i.Q6J("ngIf",!e.p.userRole(i.DdM(5,p))))},directives:[a.W2,c.O5],styles:[".container[_ngcontent-%COMP%]{--padding-top:20px!important;--padding-bottom:20px!important;--padding-start:20px!important;--padding-end:20px!important;width:100%}.arrow-right[_ngcontent-%COMP%]{display:none;margin-bottom:20px}.arrow-right[_ngcontent-%COMP%] .arrow-right-icon[_ngcontent-%COMP%]{width:37px;float:right;font-size:35px;overflow:hidden}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:space-around}.solid[_ngcontent-%COMP%]{display:none;width:90%;border-top:1px solid #bbb;margin:0 auto!important}.btn-cancel[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{margin-bottom:5px!important;margin-top:5px!important}@media only screen and (max-width: 800px){.btn-cancel[_ngcontent-%COMP%], .btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{width:100%!important}}@media only screen and (min-width: 1024px){.arrow-right[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.btn-cancel[_ngcontent-%COMP%]{display:none}.btn-cancel[_ngcontent-%COMP%], .btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{width:100%!important;margin-bottom:10px!important}.btn-delete[_ngcontent-%COMP%], .btn-ok[_ngcontent-%COMP%]{margin-top:10px!important}}.desk[_ngcontent-%COMP%]{text-align:left;background-color:#fff}"]}),t})()},86807:function(t){var e=["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],n=new Array("Domingo","Segunda","Ter\xe7a","Quarta","Quinta","Sexta","S\xe1bado"),o=new Array("Do","Seg","Ter\xe7","Qua","Qui","Sex","S\xe1b");t.exports={momentG:class{static run(t,i,a){if("function"!=typeof t.getMonth&&!(t=new Date(t))instanceof Date)throw new UserException("Invalid date formate momentG");let s={};var c={d:t.getDate().toString(),M:t.getMonth().toString(),ss:t.getSeconds().toString().padStart(2,"0"),mm:t.getMinutes().toString().padStart(2,"0"),dd:t.getDate().toString().padStart(2,"0"),MM:(t.getMonth()+1).toString().padStart(2,"0"),HH:t.getHours().toString().padStart(2,"0"),yy:t.getFullYear().toString().slice(2,4).padStart(2,"0"),EEEE:n[t.getDay()].padStart(2,"0"),EEEEV:o[t.getDay()].padStart(2,"0"),MMMM:e[t.getMonth()],yyyy:t.getFullYear()};for(var r in Object.keys(c).reverse().forEach((t,e)=>{s[e]=c[t];var n=new RegExp(t,"g");i=i.replace(n,`___${e}___`)}),s){var d=new RegExp(`___${r}___`,"g");i=i.replace(d,s[r])}return i}}.run,formatDate:function(t,e){e||(e="M/d/yyyy");var n=t.getDate(),o=t.getMonth(),c=t.getFullYear(),r=t.getHours(),d=t.getMinutes(),l=t.getSeconds(),p=t.getMilliseconds(),g=r%12,u=s(g),h=s(r),m=s(d),f=s(l),v=r<12?"AM":"PM",Z=a[t.getDay()],x=Z.substr(0,3),C=s(n),M=o+1,b=s(M),P=i[o],A=P.substr(0,3),w=c+"",T=w.substr(2,2);return(e=e.replace("hh",u).replace("h",g).replace("HH",h).replace("H",r).replace("mm",m).replace("m",d).replace("ss",f).replace("s",l).replace("S",p).replace("dd",C).replace("d",n).replace("EEEE",Z).replace("EEE",x).replace("yyyy",w).replace("yy",T).replace("aaa",v)).indexOf("MMM")>-1?e.replace("MMMM",P).replace("MMM",A):e.replace("MM",b).replace("M",M)}};var i=["January","February","March","April","May","June","July","August","September","October","November","December"],a=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function s(t){return t<10?"0"+t:t}},27538:function(t,e){"use strict";var n,o,i,a,s;window.setImmediate||(window.setImmediate=window.msSetImmediate||window.webkitSetImmediate||window.mozSetImmediate||window.oSetImmediate||function(){if(!window.postMessage||!window.addEventListener)return null;var t=[void 0],e="zero-timeout-message";return window.addEventListener("message",function(n){if("string"==typeof n.data&&n.data.substr(0,e.length)===e){n.stopImmediatePropagation();var o=parseInt(n.data.substr(e.length),36);t[o]&&(t[o](),t[o]=void 0)}},!0),window.clearImmediate=function(e){t[e]&&(t[e]=void 0)},function(n){var o=t.length;return t.push(n),window.postMessage(e+o.toString(36),"*"),o}}()||function(t){window.setTimeout(t,0)}),window.clearImmediate||(window.clearImmediate=window.msClearImmediate||window.webkitClearImmediate||window.mozClearImmediate||window.oClearImmediate||function(t){window.clearTimeout(t)}),o=function(){var t=document.createElement("canvas");if(!t||!t.getContext)return!1;var e=t.getContext("2d");return!!(e&&e.getImageData&&e.fillText&&Array.prototype.some&&Array.prototype.push)}(),i=function(){if(o){for(var t,e,n=document.createElement("canvas").getContext("2d"),i=20;i;){if(n.font=i.toString(10)+"px sans-serif",n.measureText("\uff37").width===t&&n.measureText("m").width===e)return i+1;t=n.measureText("\uff37").width,e=n.measureText("m").width,i--}return 0}}(),a=function(t){for(var e,n,o=t.length;o;)e=Math.floor(Math.random()*o),n=t[--o],t[o]=t[e],t[e]=n;return t},(s=function(t,e){if(o){Array.isArray(t)||(t=[t]),t.forEach(function(e,n){if("string"==typeof e){if(t[n]=document.getElementById(e),!t[n])throw new Error("The element id specified is not found.")}else if(!e.tagName&&!e.appendChild)throw new Error("You must pass valid HTML elements, or ID of the element.")});var n={list:[],fontFamily:'"Trebuchet MS", "Heiti TC", "\u5fae\u8edf\u6b63\u9ed1\u9ad4", "Arial Unicode MS", "Droid Fallback Sans", sans-serif',fontWeight:"normal",color:"random-dark",minSize:0,weightFactor:1,clearCanvas:!0,backgroundColor:"#fff",gridSize:8,drawOutOfBound:!1,shrinkToFit:!1,origin:null,drawMask:!1,maskColor:"rgba(255,0,0,0.3)",maskGapWidth:.3,wait:0,abortThreshold:0,abort:function(){},minRotation:-Math.PI/2,maxRotation:Math.PI/2,rotationSteps:0,shuffle:!0,rotateRatio:.1,shape:"circle",ellipticity:.65,classes:null,hover:null,click:null};if(e)for(var s in e)s in n&&(n[s]=e[s]);if("function"!=typeof n.weightFactor){var c=n.weightFactor;n.weightFactor=function(t){return t*c}}if("function"!=typeof n.shape)switch(n.shape){case"circle":default:n.shape="circle";break;case"cardioid":n.shape=function(t){return 1-Math.sin(t)};break;case"diamond":n.shape=function(t){var e=t%(2*Math.PI/4);return 1/(Math.cos(e)+Math.sin(e))};break;case"square":n.shape=function(t){return Math.min(1/Math.abs(Math.cos(t)),1/Math.abs(Math.sin(t)))};break;case"triangle-forward":n.shape=function(t){var e=t%(2*Math.PI/3);return 1/(Math.cos(e)+Math.sqrt(3)*Math.sin(e))};break;case"triangle":case"triangle-upright":n.shape=function(t){var e=(t+3*Math.PI/2)%(2*Math.PI/3);return 1/(Math.cos(e)+Math.sqrt(3)*Math.sin(e))};break;case"pentagon":n.shape=function(t){var e=(t+.955)%(2*Math.PI/5);return 1/(Math.cos(e)+.726543*Math.sin(e))};break;case"star":n.shape=function(t){var e=(t+.955)%(2*Math.PI/10);return(t+.955)%(2*Math.PI/5)-2*Math.PI/10>=0?1/(Math.cos(2*Math.PI/10-e)+3.07768*Math.sin(2*Math.PI/10-e)):1/(Math.cos(e)+3.07768*Math.sin(e))}}n.gridSize=Math.max(Math.floor(n.gridSize),4);var r,d,l,p,g,u,h,m,f=n.gridSize,v=f-n.maskGapWidth,Z=Math.abs(n.maxRotation-n.minRotation),x=Math.abs(Math.floor(n.rotationSteps)),C=Math.min(n.maxRotation,n.minRotation);switch(n.color){case"random-dark":h=function(){return S(10,50)};break;case"random-light":h=function(){return S(50,90)};break;default:"function"==typeof n.color&&(h=n.color)}"function"==typeof n.fontWeight&&(m=n.fontWeight);var M=null;"function"==typeof n.classes&&(M=n.classes);var b,P=!1,A=[],w=function(t){var e,n,o=t.currentTarget,i=o.getBoundingClientRect();t.touches?(e=t.touches[0].clientX,n=t.touches[0].clientY):(e=t.clientX,n=t.clientY);var a=n-i.top,s=Math.floor((e-i.left)*(o.width/i.width||1)/f),c=Math.floor(a*(o.height/i.height||1)/f);return A[s][c]},T=function(t){var e=w(t);b!==e&&(b=e,e?n.hover(e.item,e.dimension,t):n.hover(void 0,void 0,t))},_=function(t){var e=w(t);e&&(n.click(e.item,e.dimension,t),t.preventDefault())},O=[],q=function(t){if(O[t])return O[t];var e=8*t,o=e,i=[];for(0===t&&i.push([p[0],p[1],0]);o--;){var a=1;"circle"!==n.shape&&(a=n.shape(o/e*2*Math.PI)),i.push([p[0]+t*a*Math.cos(-o/e*2*Math.PI),p[1]+t*a*Math.sin(-o/e*2*Math.PI)*n.ellipticity,o/e*2*Math.PI])}return O[t]=i,i},k=function(){return n.abortThreshold>0&&(new Date).getTime()-u>n.abortThreshold},y=function(e,n,o,i,a){e>=d||n>=l||e<0||n<0||(r[e][n]=!1,o&&t[0].getContext("2d").fillRect(e*f,n*f,v,v),P&&(A[e][n]={item:a,dimension:i}))},D=function e(o){var s,c,p;Array.isArray(o)?(s=o[0],c=o[1]):(s=o.word,c=o.weight,p=o.attributes);var u=0===n.rotateRatio||Math.random()>n.rotateRatio?0:0===Z?C:x>0?C+Math.floor(Math.random()*x)*Z/(x-1):C+Math.random()*Z,v=function(t,e,o){var a=n.weightFactor(e);if(a<=n.minSize)return!1;var s,c=1;a<i&&(c=function(){for(var t=2;t*a<i;)t+=2;return t}()),s=m?m(t,e,a):n.fontWeight;var r=document.createElement("canvas"),d=r.getContext("2d",{willReadFrequently:!0});d.font=s+" "+(a*c).toString(10)+"px "+n.fontFamily;var l=d.measureText(t).width/c,p=Math.max(a*c,d.measureText("m").width,d.measureText("\uff37").width)/c,g=l+2*p,u=3*p,h=Math.ceil(g/f),v=Math.ceil(u/f);g=h*f,u=v*f;var Z=-l/2,x=.4*-p,C=Math.ceil((g*Math.abs(Math.sin(o))+u*Math.abs(Math.cos(o)))/f),M=Math.ceil((g*Math.abs(Math.cos(o))+u*Math.abs(Math.sin(o)))/f),b=M*f,P=C*f;r.setAttribute("width",b),r.setAttribute("height",P),d.scale(1/c,1/c),d.translate(b*c/2,P*c/2),d.rotate(-o),d.font=s+" "+(a*c).toString(10)+"px "+n.fontFamily,d.fillStyle="#000",d.textBaseline="middle",d.fillText(t,Z*c,(x+.5*a)*c);var A=d.getImageData(0,0,b,P).data;if(k())return!1;for(var w,T,_,O=[],q=M,y=[C/2,M/2,C/2,M/2];q--;)for(w=C;w--;){_=f;t:for(;_--;)for(T=f;T--;)if(A[4*((w*f+_)*b+(q*f+T))+3]){O.push([q,w]),q<y[3]&&(y[3]=q),q>y[1]&&(y[1]=q),w<y[0]&&(y[0]=w),w>y[2]&&(y[2]=w);break t}}return{mu:c,occupied:O,bounds:y,gw:M,gh:C,fillTextOffsetX:Z,fillTextOffsetY:x,fillTextWidth:l,fillTextHeight:p,fontSize:a}}(s,c,u);if(!v)return!1;if(k())return!1;if(!n.drawOutOfBound&&!n.shrinkToFit){var b=v.bounds;if(b[1]-b[3]+1>d||b[2]-b[0]+1>l)return!1}for(var A=g+1,w=function(e){var i=Math.floor(e[0]-v.gw/2),a=Math.floor(e[1]-v.gh/2);return!!function(t,e,o,i,a){for(var s=a.length;s--;){var c=t+a[s][0],p=e+a[s][1];if(c>=d||p>=l||c<0||p<0){if(!n.drawOutOfBound)return!1}else if(!r[c][p])return!1}return!0}(i,a,0,0,v.occupied)&&(function(e,o,i,a,s,c,r,d,l){var p,g,u,v=i.fontSize;p=h?h(a,s,v,c,r):n.color,g=m?m(a,s,v):n.fontWeight,u=M?M(a,s,v):n.classes,t.forEach(function(t){if(t.getContext){var s=t.getContext("2d"),c=i.mu;s.save(),s.scale(1/c,1/c),s.font=g+" "+(v*c).toString(10)+"px "+n.fontFamily,s.fillStyle=p,s.translate((e+i.gw/2)*f*c,(o+i.gh/2)*f*c),0!==d&&s.rotate(-d),s.textBaseline="middle",s.fillText(a,i.fillTextOffsetX*c,(i.fillTextOffsetY+.5*v)*c),s.restore()}else{var r=document.createElement("span"),h="";h="rotate("+-d/Math.PI*180+"deg) ",1!==i.mu&&(h+="translateX(-"+i.fillTextWidth/4+"px) scale("+1/i.mu+")");var m={position:"absolute",display:"block",font:g+" "+v*i.mu+"px "+n.fontFamily,left:(e+i.gw/2)*f+i.fillTextOffsetX+"px",top:(o+i.gh/2)*f+i.fillTextOffsetY+"px",width:i.fillTextWidth+"px",height:i.fillTextHeight+"px",lineHeight:v+"px",whiteSpace:"nowrap",transform:h,webkitTransform:h,msTransform:h,transformOrigin:"50% 40%",webkitTransformOrigin:"50% 40%",msTransformOrigin:"50% 40%"};for(var Z in p&&(m.color=p),r.textContent=a,m)r.style[Z]=m[Z];if(l)for(var x in l)r.setAttribute(x,l[x]);u&&(r.className+=u),t.appendChild(r)}})}(i,a,v,s,c,g-A,e[2],u,p),function(e,o,i,a,s,c){var r,p,g=s.occupied,u=n.drawMask;if(u&&((r=t[0].getContext("2d")).save(),r.fillStyle=n.maskColor),P){var h=s.bounds;p={x:(e+h[3])*f,y:(o+h[0])*f,w:(h[1]-h[3]+1)*f,h:(h[2]-h[0]+1)*f}}for(var m=g.length;m--;){var v=e+g[m][0],Z=o+g[m][1];v>=d||Z>=l||v<0||Z<0||y(v,Z,u,p,c)}u&&r.restore()}(i,a,0,0,v,o),!0)};A--;){var T=q(g-A);if(n.shuffle&&(T=[].concat(T),a(T)),T.some(w))return!0}return!!n.shrinkToFit&&(Array.isArray(o)?o[1]=3*o[1]/4:o.weight=3*o.weight/4,e(o))},I=function(e,n,o){if(n)return!t.some(function(t){var n=new CustomEvent(e,{detail:o||{}});return!t.dispatchEvent(n)},this);t.forEach(function(t){var n=new CustomEvent(e,{detail:o||{}});t.dispatchEvent(n)},this)};!function(){var e=t[0];if(e.getContext)d=Math.ceil(e.width/f),l=Math.ceil(e.height/f);else{var o=e.getBoundingClientRect();d=Math.ceil(o.width/f),l=Math.ceil(o.height/f)}if(I("wordcloudstart",!0)){var i,a,s,c,h;if(p=n.origin?[n.origin[0]/f,n.origin[1]/f]:[d/2,l/2],g=Math.floor(Math.sqrt(d*d+l*l)),r=[],!e.getContext||n.clearCanvas)for(t.forEach(function(t){if(t.getContext){var e=t.getContext("2d");e.fillStyle=n.backgroundColor,e.clearRect(0,0,d*(f+1),l*(f+1)),e.fillRect(0,0,d*(f+1),l*(f+1))}else t.textContent="",t.style.backgroundColor=n.backgroundColor,t.style.position="relative"}),i=d;i--;)for(r[i]=[],a=l;a--;)r[i][a]=!0;else{var m=document.createElement("canvas").getContext("2d");m.fillStyle=n.backgroundColor,m.fillRect(0,0,1,1);var v,Z,x=m.getImageData(0,0,1,1).data,C=e.getContext("2d").getImageData(0,0,d*f,l*f).data;for(i=d;i--;)for(r[i]=[],a=l;a--;){Z=f;t:for(;Z--;)for(v=f;v--;)for(s=4;s--;)if(C[4*((a*f+Z)*d*f+(i*f+v))+s]!==x[s]){r[i][a]=!1;break t}!1!==r[i][a]&&(r[i][a]=!0)}C=m=x=void 0}if(n.hover||n.click){for(P=!0,i=d+1;i--;)A[i]=[];n.hover&&e.addEventListener("mousemove",T),n.click&&(e.addEventListener("click",_),e.style.webkitTapHighlightColor="rgba(0, 0, 0, 0)"),e.addEventListener("wordcloudstart",function t(){e.removeEventListener("wordcloudstart",t),e.removeEventListener("mousemove",T),e.removeEventListener("click",_),b=void 0})}s=0,0!==n.wait?(c=window.setTimeout,h=window.clearTimeout):(c=window.setImmediate,h=window.clearImmediate);var M=function(e,n){t.forEach(function(t){t.removeEventListener(e,n)},this)},w=function t(){M("wordcloudstart",t),h(O)};!function(e,n){t.forEach(function(t){t.addEventListener("wordcloudstart",n)},this)}(0,w);var O=c(function t(){if(s>=n.list.length)return h(O),I("wordcloudstop",!1),void M("wordcloudstart",w);u=(new Date).getTime();var e=D(n.list[s]),o=!I("wordclouddrawn",!0,{item:n.list[s],drawn:e});if(k()||o)return h(O),n.abort(),I("wordcloudabort",!1),I("wordcloudstop",!1),void M("wordcloudstart",w);s++,O=c(t,n.wait)},n.wait)}}()}function S(t,e){return"hsl("+(360*Math.random()).toFixed()+","+(30*Math.random()+70).toFixed()+"%,"+(Math.random()*(e-t)+t).toFixed()+"%)"}}).isSupported=o,s.minFontSize=i,this.WordCloud=s,void 0===(n=(function(){return s}).apply(e,[]))||(t.exports=n)}}]); |