mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 13:26:08 +00:00
save
This commit is contained in:
@@ -5,6 +5,7 @@ import { HomeGuard } from '../guards/home.guard';
|
|||||||
import { LoginGuard } from '../guards/login.guard';
|
import { LoginGuard } from '../guards/login.guard';
|
||||||
import { GroupMessagesPage } from '../pages/chat/group-messages/group-messages.page';
|
import { GroupMessagesPage } from '../pages/chat/group-messages/group-messages.page';
|
||||||
import { MessagesPage } from '../pages/chat/messages/messages.page';
|
import { MessagesPage } from '../pages/chat/messages/messages.page';
|
||||||
|
import { PendentesResolverService } from '../resolvers/pendentes-resolver.service';
|
||||||
import { ProcessesResolverService } from '../resolvers/processes-resolver.service';
|
import { ProcessesResolverService } from '../resolvers/processes-resolver.service';
|
||||||
import { UserDataResolver } from '../resolvers/userData.resolver';
|
import { UserDataResolver } from '../resolvers/userData.resolver';
|
||||||
import { DiplomasPage } from '../shared/gabinete-digital/diplomas/diplomas.page';
|
import { DiplomasPage } from '../shared/gabinete-digital/diplomas/diplomas.page';
|
||||||
@@ -143,7 +144,8 @@ const routes: Routes = [
|
|||||||
{
|
{
|
||||||
path: 'gabinete-digital',
|
path: 'gabinete-digital',
|
||||||
resolve: {
|
resolve: {
|
||||||
diplomas: ProcessesResolverService
|
diplomas: ProcessesResolverService,
|
||||||
|
pendentes: PendentesResolverService,
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ export class Event{
|
|||||||
EventRecurrence?: EventRecurrence;
|
EventRecurrence?: EventRecurrence;
|
||||||
|
|
||||||
/* public Event(){
|
/* public Event(){
|
||||||
this.EventRecurrence.Type = '-1';
|
this.EventRecurrence = new EventRecurrence();
|
||||||
} */
|
} */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -556,7 +556,7 @@ export class AgendaPage implements OnInit {
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else if(this.loggeduser.Profile == 'PR') {
|
||||||
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then(
|
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then(
|
||||||
(response:any) => {
|
(response:any) => {
|
||||||
|
|
||||||
|
|||||||
@@ -155,41 +155,41 @@
|
|||||||
<div class="container-div width-100">
|
<div class="container-div width-100">
|
||||||
<div class="ion-item-class-2">
|
<div class="ion-item-class-2">
|
||||||
<div class="ion-icon-class">
|
<div class="ion-icon-class">
|
||||||
<ion-icon slot="start" src="assets/images/icons-calendar.svg"></ion-icon>
|
<ion-icon slot="start" src="assets/images/icons-refresh.svg"></ion-icon>
|
||||||
</div>
|
</div>
|
||||||
<div class="ion-input-class" [class.input-error]="Form?.get('Categories')?.invalid && validateFrom ">
|
<div class="ion-input-class" [class.input-error]="Form?.get('Categories')?.invalid && validateFrom ">
|
||||||
<ion-select placeholder="Selecione a repetição*"
|
<ion-select placeholder="Selecione a repetição*"
|
||||||
[(ngModel)]="postEvent.EventRecurrence.Type"
|
[(ngModel)]="selectedRecurringType"
|
||||||
selectedText="{{postEvent.EventRecurrence.Type}}"
|
(ngModelChange)="onSelectedRecurringChanged($event)"
|
||||||
interface="action-sheet"
|
interface="action-sheet"
|
||||||
Cancel-text="Cancelar" required>
|
Cancel-text="Cancelar" required>
|
||||||
<ion-select-option value="-1">Nunca</ion-select-option>
|
<ion-select-option *ngFor="let recurring of recurringTypes" value="{{recurring.Code}}">{{recurring.Description}}</ion-select-option>
|
||||||
<ion-select-option value="0">Diário</ion-select-option>
|
|
||||||
<ion-select-option value="1">Semanal</ion-select-option>
|
|
||||||
<ion-select-option value="2">Mensal</ion-select-option>
|
|
||||||
<ion-select-option value="3">Anual</ion-select-option>
|
|
||||||
</ion-select>
|
</ion-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="container-div width-100">
|
<div *ngIf="selectedRecurringType != '-1'" class="container-div width-100">
|
||||||
<div class="ion-item-class-2">
|
<div class="ion-item-class-2">
|
||||||
<div class="ion-icon-class">
|
<div class="ion-icon-class">
|
||||||
<ion-icon slot="start" src="assets/images/icons-refresh.svg"></ion-icon>
|
<ion-icon slot="start" src="assets/images/icons-calendar.svg"></ion-icon>
|
||||||
</div>
|
</div>
|
||||||
<div class="ion-input-class">
|
<div class="ion-input-class">
|
||||||
<ion-select placeholder="Selecione repetição*"
|
<ion-datetime
|
||||||
[(ngModel)]="postEvent.IsRecurring"
|
placeholder="Última ocorrência"
|
||||||
selectedText="{{isRecurring}}"
|
[(ngModel)]="postEvent.EventRecurrence.LastOcurrence"
|
||||||
interface="action-sheet"
|
displayFormat="D MMM YYYY H:mm"
|
||||||
Cancel-text="Cancelar" required>
|
minuteValues="0,15,30,45"
|
||||||
<ion-select-option value="false">Não se repete</ion-select-option>
|
monthShortNames="Jan, Fev, Mar, Abr, Mai, Jun, Jul, Aug, Sep, Out, Nov, Dez"
|
||||||
<ion-select-option value="true">Repete</ion-select-option>
|
min="2021"
|
||||||
</ion-select>
|
max="2025"
|
||||||
|
>
|
||||||
|
</ion-datetime>
|
||||||
|
<!-- <ion-input placeholder="Data fim" [(ngModel)]="postData.EndDate"></ion-input> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="container-div width-100">
|
<div class="container-div width-100">
|
||||||
<div (click)="addParticipants()" class="ion-item-class-2 cursor-pointer">
|
<div (click)="addParticipants()" class="ion-item-class-2 cursor-pointer">
|
||||||
<div class="ion-icon-class">
|
<div class="ion-icon-class">
|
||||||
|
|||||||
@@ -36,6 +36,8 @@ export class EditEventPage implements OnInit {
|
|||||||
minDate: string;
|
minDate: string;
|
||||||
initCalendarName: string;
|
initCalendarName: string;
|
||||||
caller:string;
|
caller:string;
|
||||||
|
recurringTypes: any;
|
||||||
|
selectedRecurringType: any;
|
||||||
|
|
||||||
|
|
||||||
loadedEventAttachments: Attachment[];
|
loadedEventAttachments: Attachment[];
|
||||||
@@ -57,10 +59,9 @@ export class EditEventPage implements OnInit {
|
|||||||
) {
|
) {
|
||||||
|
|
||||||
this.postEvent = new Event();
|
this.postEvent = new Event();
|
||||||
console.log(this.postEvent);
|
|
||||||
this.postEvent.EventRecurrence = {Type:'-1'}
|
|
||||||
this.isEventEdited = false;
|
this.isEventEdited = false;
|
||||||
this.postEvent = this.navParams.get('event');
|
this.postEvent = this.navParams.get('event');
|
||||||
|
this.postEvent.EventRecurrence = {Type:'-1'};
|
||||||
this.caller = this.navParams.get('caller');
|
this.caller = this.navParams.get('caller');
|
||||||
this.initCalendarName = this.postEvent.CalendarName;
|
this.initCalendarName = this.postEvent.CalendarName;
|
||||||
|
|
||||||
@@ -97,8 +98,7 @@ export class EditEventPage implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
|
this.selectedRecurringType = "-1";
|
||||||
console.log(this.caller);
|
|
||||||
|
|
||||||
window.onresize = (event) => {
|
window.onresize = (event) => {
|
||||||
// if not mobile remove all component
|
// if not mobile remove all component
|
||||||
@@ -126,9 +126,21 @@ export class EditEventPage implements OnInit {
|
|||||||
getRecurrenceTypes() {
|
getRecurrenceTypes() {
|
||||||
this.eventsService.getRecurrenceTypes().subscribe(res=>{
|
this.eventsService.getRecurrenceTypes().subscribe(res=>{
|
||||||
console.log(res);
|
console.log(res);
|
||||||
|
this.recurringTypes = res;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onSelectedRecurringChanged(ev:any){
|
||||||
|
console.log(ev);
|
||||||
|
if(ev.length > 1){
|
||||||
|
console.log(ev.filter(data => data != '-1'));
|
||||||
|
this.selectedRecurringType = ev.filter(data => data != '-1');
|
||||||
|
}
|
||||||
|
if(ev.length == 0){
|
||||||
|
this.selectedRecurringType = "-1";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
runValidation() {
|
runValidation() {
|
||||||
this.validateFrom = true
|
this.validateFrom = true
|
||||||
@@ -171,8 +183,9 @@ export class EditEventPage implements OnInit {
|
|||||||
this.postEvent.Attendees = this.taskParticipants.concat(this.taskParticipantsCc)
|
this.postEvent.Attendees = this.taskParticipants.concat(this.taskParticipantsCc)
|
||||||
try{
|
try{
|
||||||
console.log(this.postEvent);
|
console.log(this.postEvent);
|
||||||
|
this.postEvent.EventRecurrence.Type = this.selectedRecurringType;
|
||||||
|
|
||||||
/* this.eventsService.editEvent(this.postEvent, 2, 3).subscribe(async () => {
|
this.eventsService.editEvent(this.postEvent, 2, 3).subscribe(async () => {
|
||||||
if(this.initCalendarName != this.postEvent.CalendarName){
|
if(this.initCalendarName != this.postEvent.CalendarName){
|
||||||
let body = {
|
let body = {
|
||||||
"EventId": this.postEvent.EventId,
|
"EventId": this.postEvent.EventId,
|
||||||
@@ -185,7 +198,7 @@ export class EditEventPage implements OnInit {
|
|||||||
|
|
||||||
}, error => {
|
}, error => {
|
||||||
this.toastService.badRequest()
|
this.toastService.badRequest()
|
||||||
}); */
|
});
|
||||||
|
|
||||||
this.isEventEdited = true;
|
this.isEventEdited = true;
|
||||||
this.goBack();
|
this.goBack();
|
||||||
|
|||||||
@@ -154,20 +154,44 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="container-div">
|
<div class="container-div width-100">
|
||||||
<div class="ion-item-class-2">
|
<div class="ion-item-class-2">
|
||||||
<div class="ion-icon-class">
|
<div class="ion-icon-class">
|
||||||
<ion-icon slot="start" src="assets/images/icons-refresh.svg"></ion-icon>
|
<ion-icon slot="start" src="assets/images/icons-refresh.svg"></ion-icon>
|
||||||
</div>
|
</div>
|
||||||
<div class="ion-input-class">
|
<div class="ion-input-class" [class.input-error]="Form?.get('Categories')?.invalid && validateFrom ">
|
||||||
<ion-select placeholder="Selecione repetição*" value="false" interface="action-sheet" Cancel-text="Cancelar" required>
|
<ion-select placeholder="Selecione a repetição*"
|
||||||
<ion-select-option value="false">Não se repete</ion-select-option>
|
[(ngModel)]="selectedRecurringType"
|
||||||
<ion-select-option value="true">Repete</ion-select-option>
|
(ngModelChange)="onSelectedRecurringChanged($event)"
|
||||||
|
interface="action-sheet"
|
||||||
|
Cancel-text="Cancelar" required>
|
||||||
|
<ion-select-option *ngFor="let recurring of recurringTypes" value="{{recurring.Code}}">{{recurring.Description}}</ion-select-option>
|
||||||
</ion-select>
|
</ion-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div *ngIf="selectedRecurringType != '-1'" class="container-div width-100">
|
||||||
|
<div class="ion-item-class-2">
|
||||||
|
<div class="ion-icon-class">
|
||||||
|
<ion-icon slot="start" src="assets/images/icons-calendar.svg"></ion-icon>
|
||||||
|
</div>
|
||||||
|
<div class="ion-input-class">
|
||||||
|
<ion-datetime
|
||||||
|
placeholder="Última ocorrência"
|
||||||
|
[(ngModel)]="postEvent.EventRecurrence.LastOcurrence"
|
||||||
|
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"
|
||||||
|
>
|
||||||
|
</ion-datetime>
|
||||||
|
<!-- <ion-input placeholder="Data fim" [(ngModel)]="postData.EndDate"></ion-input> -->
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="container-div">
|
<div class="container-div">
|
||||||
<div class="ion-item-class-2">
|
<div class="ion-item-class-2">
|
||||||
<div class="ion-icon-class">
|
<div class="ion-icon-class">
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ import { AttendeesPageModal } from '../../events/attendees/attendees.page';
|
|||||||
import { SearchPage } from '../../search/search.page';
|
import { SearchPage } from '../../search/search.page';
|
||||||
import { ThemePalette } from '@angular/material/core';
|
import { ThemePalette } from '@angular/material/core';
|
||||||
import { FormControl, FormGroup, Validators } from '@angular/forms';
|
import { FormControl, FormGroup, Validators } from '@angular/forms';
|
||||||
|
import { EventRecurrence } from 'src/app/models/agenda/eventrecurrence.model';
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
@@ -47,6 +48,8 @@ export class NewEventPage implements OnInit {
|
|||||||
eventAttendees: EventPerson[];
|
eventAttendees: EventPerson[];
|
||||||
selectedSegment: string;
|
selectedSegment: string;
|
||||||
selectedDate: Date;
|
selectedDate: Date;
|
||||||
|
recurringTypes: any;
|
||||||
|
selectedRecurringType: any;
|
||||||
|
|
||||||
adding: "intervenient" | "CC";
|
adding: "intervenient" | "CC";
|
||||||
|
|
||||||
@@ -77,6 +80,8 @@ export class NewEventPage implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
|
this.selectedRecurringType = "-1";
|
||||||
|
this.getRecurrenceTypes();
|
||||||
|
|
||||||
/* console.log(this.profile); */
|
/* console.log(this.profile); */
|
||||||
|
|
||||||
@@ -142,6 +147,25 @@ export class NewEventPage implements OnInit {
|
|||||||
close(){
|
close(){
|
||||||
this.modalController.dismiss();
|
this.modalController.dismiss();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
getRecurrenceTypes() {
|
||||||
|
this.eventService.getRecurrenceTypes().subscribe(res=>{
|
||||||
|
console.log(res);
|
||||||
|
this.recurringTypes = res;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
onSelectedRecurringChanged(ev:any){
|
||||||
|
console.log(ev);
|
||||||
|
if(ev.length > 1){
|
||||||
|
console.log(ev.filter(data => data != '-1'));
|
||||||
|
this.selectedRecurringType = ev.filter(data => data != '-1');
|
||||||
|
}
|
||||||
|
if(ev.length == 0){
|
||||||
|
this.selectedRecurringType = "-1";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
runValidation() {
|
runValidation() {
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';
|
import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';
|
||||||
import { NavigationExtras, Router } from '@angular/router';
|
import { ActivatedRoute, NavigationEnd, NavigationExtras, Router } from '@angular/router';
|
||||||
import { CalendarComponent } from 'ionic2-calendar';
|
import { CalendarComponent } from 'ionic2-calendar';
|
||||||
|
import { removeDuplicate } from 'src/plugin/removeDuplicate.js'
|
||||||
import { DailyWorkTask } from '../../../models/dailyworktask.model';
|
import { DailyWorkTask } from '../../../models/dailyworktask.model';
|
||||||
import { ProcessesService } from 'src/app/services/processes.service';
|
import { ProcessesService } from 'src/app/services/processes.service';
|
||||||
import { formatDate } from '@angular/common';
|
import { formatDate } from '@angular/common';
|
||||||
@@ -32,22 +32,58 @@ export class PendentesPage implements OnInit {
|
|||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private processes:ProcessesService,
|
private processes:ProcessesService,
|
||||||
private modalController: ModalController,
|
|
||||||
private alertService: AlertService,
|
private alertService: AlertService,
|
||||||
private authService: AuthService,
|
|
||||||
private router: Router,
|
private router: Router,
|
||||||
|
private activatedRoute: ActivatedRoute,
|
||||||
) {
|
) {
|
||||||
this.profile = 'mdgpr';
|
this.profile = 'mdgpr';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
|
this.initPendentes();
|
||||||
//Inicializar segment
|
//Inicializar segment
|
||||||
this.segment = "despachos";
|
this.segment = "despachos";
|
||||||
this.LoadList();
|
this.router.events.forEach((event) => {
|
||||||
|
if(event instanceof NavigationEnd && event.url == this.router.url) {
|
||||||
|
this.refreshing();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
initPendentes(){
|
||||||
|
this.activatedRoute.data.subscribe(data => {
|
||||||
|
console.log(data['pendentes']);
|
||||||
|
data['pendentes'].forEach(element => {
|
||||||
|
let DocId = element.workflowInstanceDataFields.FolderID;
|
||||||
|
let ApplicationId = element.workflowInstanceDataFields.ApplicationId;
|
||||||
|
|
||||||
|
let date = new Date(element.taskStartDate);
|
||||||
|
date.setMonth(date.getMonth() + 1);
|
||||||
|
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||||
|
|
||||||
|
let task = {
|
||||||
|
"SerialNumber": element.serialNumber,
|
||||||
|
"Folio": element.workflowInstanceDataFields.Subject,
|
||||||
|
"Senders": element.workflowInstanceDataFields.Sender,
|
||||||
|
"CreateDate": taskDate,
|
||||||
|
"DocumentURL": element.workflowInstanceDataFields.ViewerRequest,
|
||||||
|
"Remetente": element.workflowInstanceDataFields.Remetente,
|
||||||
|
"DocumentsQty": 0,
|
||||||
|
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||||
|
"WorkflowName": element.workflowDisplayName,
|
||||||
|
"activityInstanceName": element.activityInstanceName,
|
||||||
|
}
|
||||||
|
console.log(task);
|
||||||
|
|
||||||
|
this.pendentesList.push.call(task);
|
||||||
|
this.pendentesList = removeDuplicate( this.pendentesList);
|
||||||
|
});
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
segmentChanged(ev: any) {
|
segmentChanged(ev: any) {
|
||||||
this.LoadList();
|
this.refreshing();
|
||||||
}
|
}
|
||||||
|
|
||||||
goBack() {
|
goBack() {
|
||||||
@@ -98,6 +134,7 @@ export class PendentesPage implements OnInit {
|
|||||||
"Status": element.workflowInstanceDataFields.Status,
|
"Status": element.workflowInstanceDataFields.Status,
|
||||||
}
|
}
|
||||||
this.pendentesList.push(task);
|
this.pendentesList.push(task);
|
||||||
|
this.pendentesList = removeDuplicate( this.pendentesList)
|
||||||
},
|
},
|
||||||
(error)=>{
|
(error)=>{
|
||||||
let task = {
|
let task = {
|
||||||
@@ -114,10 +151,17 @@ export class PendentesPage implements OnInit {
|
|||||||
"Status": element.workflowInstanceDataFields.Status,
|
"Status": element.workflowInstanceDataFields.Status,
|
||||||
}
|
}
|
||||||
this.pendentesList.push(task);
|
this.pendentesList.push(task);
|
||||||
|
this.pendentesList = removeDuplicate( this.pendentesList)
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
this.showLoader = false;
|
this.showLoader = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async refreshing() {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.LoadList();
|
||||||
|
}, 1500);
|
||||||
|
}
|
||||||
|
|
||||||
doRefresh(event) {
|
doRefresh(event) {
|
||||||
this.LoadList();
|
this.LoadList();
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
import { TestBed } from '@angular/core/testing';
|
||||||
|
|
||||||
|
import { PendentesResolverService } from './pendentes-resolver.service';
|
||||||
|
|
||||||
|
describe('PendentesResolverService', () => {
|
||||||
|
let service: PendentesResolverService;
|
||||||
|
|
||||||
|
beforeEach(() => {
|
||||||
|
TestBed.configureTestingModule({});
|
||||||
|
service = TestBed.inject(PendentesResolverService);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should be created', () => {
|
||||||
|
expect(service).toBeTruthy();
|
||||||
|
});
|
||||||
|
});
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
import { Injectable } from '@angular/core';
|
||||||
|
import { ActivatedRouteSnapshot, Resolve, RouterStateSnapshot } from '@angular/router';
|
||||||
|
import { Observable } from 'rxjs';
|
||||||
|
import { ProcessesService } from '../services/processes.service';
|
||||||
|
|
||||||
|
@Injectable({
|
||||||
|
providedIn: 'root'
|
||||||
|
})
|
||||||
|
export class PendentesResolverService implements Resolve<any> {
|
||||||
|
|
||||||
|
constructor(
|
||||||
|
private processesService: ProcessesService,
|
||||||
|
) { }
|
||||||
|
|
||||||
|
async resolve(route: ActivatedRouteSnapshot, state: RouterStateSnapshot):
|
||||||
|
Promise<any> {
|
||||||
|
|
||||||
|
let despachos = await this.processesService.GetTasksList("Despacho", false).toPromise();
|
||||||
|
let pareceres = await this.processesService.GetTasksList("Pedido de Parecer", false).toPromise();
|
||||||
|
let deferimentos = await this.processesService.GetTasksList("Pedido de Deferimento", false).toPromise();
|
||||||
|
let expedientes = await this.processesService.GetTasksList("Expediente", false).toPromise();
|
||||||
|
let expedientes_pr = await this.processesService.GetTasksList("Expediente do Presidente", false).toPromise();
|
||||||
|
|
||||||
|
let pendentes = despachos.concat(pareceres, deferimentos, expedientes, expedientes_pr).filter(data => data.workflowInstanceDataFields.Status == "Pending");
|
||||||
|
|
||||||
|
return pendentes;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -200,6 +200,8 @@ export class EventsService {
|
|||||||
headers: this.headersSharedOficial,
|
headers: this.headersSharedOficial,
|
||||||
params: params
|
params: params
|
||||||
};
|
};
|
||||||
|
console.log(options);
|
||||||
|
|
||||||
return this.http.get<Event[]>(`${geturl}`, options);
|
return this.http.get<Event[]>(`${geturl}`, options);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user