mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
add filter
This commit is contained in:
@@ -20,6 +20,7 @@ import { removeDuplicate } from 'src/plugin/removeDuplicate.js'
|
||||
import { WaitForDomService } from 'src/app/services/dom/wait-for-dom.service';
|
||||
import { TotalDocumentStore } from 'src/app/store/total-document.service';
|
||||
import { DeplomasStore } from 'src/app/store/deplomas.service';
|
||||
import { CustomTaskPipe } from 'src/app/pipes/custom-task.pipe';
|
||||
|
||||
@Component({
|
||||
selector: 'app-gabinete-digital',
|
||||
@@ -98,6 +99,11 @@ export class GabineteDigitalPage implements OnInit, DoCheck {
|
||||
despachoprstore = DespachosprStore;
|
||||
totalDocumentStore = TotalDocumentStore
|
||||
deplomasStore = DeplomasStore
|
||||
//
|
||||
// pipe
|
||||
|
||||
|
||||
customTaskPipe = new CustomTaskPipe()
|
||||
|
||||
@ViewChild(ExpedientsPage) expedientesPage: ExpedientsPage;
|
||||
@ViewChild(PendentesPage) pendentesListPage: PendentesPage;
|
||||
@@ -184,6 +190,13 @@ export class GabineteDigitalPage implements OnInit, DoCheck {
|
||||
|
||||
async loadAllProcesses() {
|
||||
let allProcessesList = await this.processesbackend.GetTasksList("", false).toPromise();
|
||||
|
||||
if(!this.p.userRole(['PR'])) {
|
||||
allProcessesList = allProcessesList.filter( element => element.activityInstanceName != 'Assinar Diplomas')
|
||||
} else if (this.p.userRole(['PR'])) {
|
||||
allProcessesList = allProcessesList.filter( element => element.activityInstanceName != 'Diplomas Assinado')
|
||||
}
|
||||
|
||||
console.log(allProcessesList);
|
||||
|
||||
this.skeletonLoader = true;
|
||||
|
||||
@@ -6,8 +6,7 @@ import { BookMeetingModalPage } from 'src/app/pages/gabinete-digital/expediente/
|
||||
import { DeplomaService } from 'src/app/Rules/deploma.service';
|
||||
import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { BadRequestPage } from '../bad-request/bad-request.page';
|
||||
import { SuccessMessagePage } from '../success-message/success-message.page';
|
||||
import { Location } from '@angular/common';
|
||||
|
||||
@Component({
|
||||
selector: 'app-deploma-options',
|
||||
@@ -30,7 +29,8 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
private navParams: NavParams,
|
||||
private toastService: ToastService,
|
||||
private router: Router,
|
||||
private deplomaService: DeplomaService) {
|
||||
private deplomaService: DeplomaService,
|
||||
private location: Location) {
|
||||
this.serialNumber = this.navParams.get('serialNumber');
|
||||
this.task = this.navParams.get('task');
|
||||
this.fulltask = this.navParams.get('fulltask');
|
||||
@@ -216,7 +216,7 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
goBack() {
|
||||
this.router.navigate(['/home/gabinete-digital/diplomas-assinar']);
|
||||
this.location.back()
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user