Files
doneit-web/_platforms/browser/www/6204-es2015.609b3f25ad0cb215d644.js
T
tiago.kayaya 24e2a8f518 save
2021-08-18 18:58:02 +01:00

1 line
8.7 KiB
JavaScript

(self.webpackChunkgabinete_digital=self.webpackChunkgabinete_digital||[]).push([[6204],{6204:function(t,e,n){"use strict";n.r(e),n.d(e,{PendentesPageModule:function(){return w}});var o=n(38583),i=n(3679),a=n(35957),r=n(39895),d=n(64762),l=n(87732),s=n(44940),c=n(54271),g=n(17690),p=n(37716),f=n(28621),h=n(25970),u=n(37556),m=n(962),P=n(23890),x=n(95526);const C=[{path:"",component:(()=>{class t{constructor(t,e,n,o,i){this.processes=t,this.alertService=e,this.router=n,this.authService=o,this.activatedRoute=i,this.skeletonLoader=!0,this.pendentesstore=c.G,this.customTaskPipe=new g.g,this.loggeduser=o.ValidatedUser,this.profile="mdgpr"}ngOnInit(){this.segment="despachos";const t=window.location,e=t.pathname+t.search;this.LoadList(),this.router.events.forEach(t=>{t instanceof r.m2&&t.url.startsWith(e)&&(window.location.pathname.split("/").length>=4&&window.location.pathname.startsWith("/home/gabinete-digital")?this.refreshing():this.LoadList())})}segmentChanged(t){this.refreshing()}goBack(){this.router.navigate(["/home/gabinete-digital"])}notImplemented(){this.alertService.presentAlert("Funcionalidade em desenvolvimento")}LoadList(){return(0,d.mG)(this,void 0,void 0,function*(){this.skeletonLoader=!0;let t=yield this.processes.GetPendingTasks(!1).toPromise(),e=[];t.forEach(t=>{let n=this.customTaskPipe.transform(t);e.push(n)}),e=(0,s.removeDuplicate)(e),e=this.sortArrayISODate(e),this.pendentesstore.reset(e),this.skeletonLoader=!1})}sortArrayISODate(t){return t.sort(function(t,e){return t.CreateDate<e.CreateDate?-1:t.CreateDate>e.CreateDate?1:0})}refreshing(){return(0,d.mG)(this,void 0,void 0,function*(){setTimeout(()=>{this.LoadList()},1500)})}doRefresh(t){this.LoadList(),setTimeout(()=>{t.target.complete()},2e3)}viewTaskDetails({SerialNumber:t,WorkflowName:e,activityInstanceName:n}){return(0,d.mG)(this,void 0,void 0,function*(){"Despacho"==e?this.router.navigate(["/home/gabinete-digital/despachos",t,"gabinete-digital"]):"Pedido de Parecer"==e||"Pedido de Deferimento"==e||"Pedido de Parecer do Presidente"==e?this.router.navigate(["/home/gabinete-digital/pedidos",t,"gabinete-digital"]):"Expediente"==e?this.router.navigate(["/home/gabinete-digital/expediente",t,"gabinete-digital"]):"Expediente"==e&&"PR"==this.loggeduser.Profile?this.router.navigate(["/home/gabinete-digital/expedientes-pr",t,"gabinete-digital"]):"Tarefa de Parecer"==n?this.router.navigate(["/home/gabinete-digital/pedidos",t,"gabinete-digital"]):"Tarefa de Despacho"==n?this.router.navigate(["/home/gabinete-digital/despachos",t,"gabinete-digital"]):console.log("cant find page for this task",e,n)})}toDateString(t){return new Date(t).toDateString()}}return t.\u0275fac=function(e){return new(e||t)(p.Y36(f.$),p.Y36(h.c),p.Y36(r.F0),p.Y36(u.e),p.Y36(r.gz))},t.\u0275cmp=p.Xpm({type:t,selectors:[["app-pendentes"]],viewQuery:function(t,e){if(1&t&&p.Gf(l.eV,5),2&t){let t;p.iGM(t=p.CRH())&&(e.myCal=t.first)}},inputs:{profile:"profile"},decls:15,vars:2,consts:[[1,"ion-no-border"],[1,"ion-no-border","header-2"],[3,"click"],[1,"title"],[1,"thetitle"],[1,"theicon","btn-refresh"],[1,"btn-no-color",3,"click"],["slot","end","name","reload-circle",1,"title-icon"],[2,"background-color","white"],["name","refresher","slot","fixed",3,"ionRefresh"],["pullingIcon","chevron-down-circle-outline","pullingText","deslize para actualizar","refreshingSpinner","circles","refreshingText","A actualizar..."],[1,"height-100",3,"taskList","skeletonLoader","viewTaskDetail"]],template:function(t,e){1&t&&(p.TgZ(0,"ion-header",0),p._UZ(1,"app-header"),p.qZA(),p.TgZ(2,"ion-header",1),p.TgZ(3,"app-btn-modal-dismiss",2),p.NdJ("click",function(){return e.goBack()}),p.qZA(),p.TgZ(4,"div",3),p.TgZ(5,"div",4),p.TgZ(6,"ion-label"),p._uU(7,"Pendentes"),p.qZA(),p.qZA(),p.TgZ(8,"div",5),p.TgZ(9,"button",6),p.NdJ("click",function(t){return e.doRefresh(t)}),p._UZ(10,"ion-icon",7),p.qZA(),p.qZA(),p.qZA(),p.qZA(),p.TgZ(11,"ion-content",8),p.TgZ(12,"ion-refresher",9),p.NdJ("ionRefresh",function(t){return e.doRefresh(t)}),p._UZ(13,"ion-refresher-content",10),p.qZA(),p.TgZ(14,"app-task-list",11),p.NdJ("viewTaskDetail",function(t){return e.viewTaskDetails(t)}),p.qZA(),p.qZA()),2&t&&(p.xp6(14),p.Q6J("taskList",e.pendentesstore.list)("skeletonLoader",e.skeletonLoader))},directives:[a.Gu,m.E,P.E,a.Q$,a.gu,a.W2,a.nJ,a.Wo,x.V],styles:["[_nghost-%COMP%]{margin:0}.header-2[_ngcontent-%COMP%]{border-top-right-radius:24px;border-top-left-radius:24px;padding:30px 20px 0!important;background-color:#fff}.main-content[_ngcontent-%COMP%]{background-color:#fff;padding-top:0!important}.title[_ngcontent-%COMP%]{font-family:Roboto;font-size:25px;color:#000;overflow:auto}.title[_ngcontent-%COMP%] .thetitle[_ngcontent-%COMP%]{float:left}.title[_ngcontent-%COMP%] .theicon[_ngcontent-%COMP%], .title[_ngcontent-%COMP%] .thetitle[_ngcontent-%COMP%]{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}.title[_ngcontent-%COMP%] .theicon[_ngcontent-%COMP%]{float:right}.item-list-small[_ngcontent-%COMP%]{font-size:11px;overflow:hidden}.ion-item-class[_ngcontent-%COMP%]{padding:0}.label-text[_ngcontent-%COMP%]{width:100%;padding:0;margin:0}ion-item[_ngcontent-%COMP%]{--background:none}.item[_ngcontent-%COMP%]{background-color:var(--white);margin:0 auto;overflow:auto}.div-content-expediente[_ngcontent-%COMP%]{width:100%;float:left;border-left:3px solid #dae3f3;padding:5px 5px 15px;margin:10px 0;background:#dae3f3;border-radius:20px}.div-content-pendentes[_ngcontent-%COMP%]{width:100%;float:left;border-left:3px solid #d9d9d9;padding:5px}.div-content-expediente[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .div-content-pendentes[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0;padding:0;font-size:14pt;width:100%}.div-icon[_ngcontent-%COMP%]{width:10%;font-size:20px;float:left;color:grey}.div-icon[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{display:block;margin:0 auto}.div-content-expediente[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .div-content-pendentes[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font-size:14pt;color:#5e5c5c;padding:0;margin:0}.span-left[_ngcontent-%COMP%]{float:left;font-size:12px;padding-left:18px}.span-right[_ngcontent-%COMP%]{text-align:right;float:right;font-size:12px;padding-right:18px}.expediente[_ngcontent-%COMP%]{border-radius:15px;box-shadow:0 0 10px 0 rgba(0,0,0,.07);border:1px solid #e9e9e9!important;background-color:var(--white);margin-bottom:10px!important;padding:15px}.exp-list-item[_ngcontent-%COMP%]{overflow:auto;margin:10px auto}.exp-top-detail[_ngcontent-%COMP%]{width:100%;float:left;font-family:Roboto;font-size:12pt;font-weight:700;color:#0d89d1;padding-left:3px}.exp-top-detail[_ngcontent-%COMP%] .subject[_ngcontent-%COMP%]{width:84%;float:left}.exp-top-detail[_ngcontent-%COMP%] .exp-icon[_ngcontent-%COMP%]{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;float:right;margin:0!important;padding:0!important}.exp-top-detail[_ngcontent-%COMP%] .exp-icon[_ngcontent-%COMP%] ion-icon[_ngcontent-%COMP%]{font-size:12pt;color:#42b9fe;float:left}.exp-top-detail[_ngcontent-%COMP%] .exp-icon[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{font-size:10pt}.exp-bottom-detail[_ngcontent-%COMP%], .exp-middle-detail[_ngcontent-%COMP%]{margin-bottom:5px}.exp-middle-detail[_ngcontent-%COMP%]{font-size:12pt;width:100%;overflow:auto}.exp-middle-detail[_ngcontent-%COMP%] .exp-workflow[_ngcontent-%COMP%]{float:left;margin:0!important}.exp-middle-detail[_ngcontent-%COMP%] .exp-workflow[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{border-radius:15px;background:#ffb703;float:right;padding:2.5px 13.5px;color:#fff}.exp-middle-detail[_ngcontent-%COMP%] .exp-date[_ngcontent-%COMP%]{width:auto;font-family:Roboto;font-size:10pt;font-weight:400;font-stretch:normal;font-style:normal;line-height:normal;letter-spacing:normal;color:#797979;float:right}.exp-bottom-detail[_ngcontent-%COMP%]{font-size:8pt;width:100%;overflow:auto;padding-left:3px}.exp-bottom-detail[_ngcontent-%COMP%] .exp-remetente[_ngcontent-%COMP%]{font-family:Roboto;font-weight:400;color:#000;float:left}.div-top-header[_ngcontent-%COMP%]{width:400px;margin:6px auto;background-color:#0782c9;overflow:auto}.div-search[_ngcontent-%COMP%]{font-size:45px;float:left;margin:0 0 0 10px}.div-logo[_ngcontent-%COMP%]{background:transparent;width:150px;margin:2.5px 0 2.5px 71px;float:left}.div-logo[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:100%}.div-profile[_ngcontent-%COMP%]{font-size:45px;float:right;margin-right:10px}"]}),t})()}];let _=(()=>{class t{}return t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=p.oAB({type:t}),t.\u0275inj=p.cJS({imports:[[r.Bz.forChild(C)],r.Bz]}),t})();var M=n(6527),O=n(4502),b=n(84747);let w=(()=>{class t{}return t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=p.oAB({type:t}),t.\u0275inj=p.cJS({imports:[[o.ez,i.u5,a.Pc,_,M.a,O.F,b.TaskListPageModule]]}),t})()}}]);