mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
improve
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
<div class="title">
|
||||
<div class="thetitle"><ion-label >Todas as tarefas</ion-label></div>
|
||||
|
||||
<div class="theicon d-flex">
|
||||
<div class="theicon d-flex align-center">
|
||||
<div>
|
||||
<div title="Pesquisa" *ngIf="!hideSearchBtn" class="mr-20 d-flex align-center cursor-pointer">
|
||||
<div (click)="openSearch();showSearch=true" *ngIf="!showSearch" class="d-flex">
|
||||
@@ -40,6 +40,18 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<div class="d-flex" (click)="reorderList('old')" *ngIf="ordinance == 'recent' ">
|
||||
|
||||
<ion-icon class="mr-10 font-25" src="assets/images/theme/gov/crescente.svg" ></ion-icon>
|
||||
</div>
|
||||
|
||||
<div class="d-flex" (click)="reorderList('recent')" *ngIf="ordinance != 'recent' ">
|
||||
<ion-icon class="mr-10 font-25" src="assets/images/theme/gov/decrescente.svg" ></ion-icon>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<mat-form-field class="task-filter-input" appearance="none" color="ion-color-secondary" placeholder="Selecione agenda">
|
||||
<mat-select [(value)]="filterName">
|
||||
|
||||
@@ -27,6 +27,7 @@ export class AllProcessesPage implements OnInit {
|
||||
})
|
||||
|
||||
AllProcess = []
|
||||
ordinance: string = 'old'
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
@@ -71,30 +72,40 @@ export class AllProcessesPage implements OnInit {
|
||||
}
|
||||
|
||||
openSearch() {
|
||||
this.dynamicSearch()
|
||||
// this.dynamicSearch()
|
||||
}
|
||||
async closeSearch() {
|
||||
this.searchSubject = ''
|
||||
this.dynamicSearch()
|
||||
// this.dynamicSearch()
|
||||
}
|
||||
|
||||
async basicSearch() {
|
||||
this.dynamicSearch()
|
||||
// this.dynamicSearch()
|
||||
}
|
||||
|
||||
|
||||
reorderList(orderBy: string) {
|
||||
|
||||
this.ordinance = orderBy;
|
||||
|
||||
this.dynamicSearch();
|
||||
}
|
||||
|
||||
async dynamicSearch() {
|
||||
|
||||
if(this.showSearch && this.searchSubject) {
|
||||
|
||||
this.AllProcess = this.TaskService.AllProcess.filter((task) => {
|
||||
const AllProcess = this.TaskService.AllProcess.filter((task) => {
|
||||
let subject = task.Folio || task.Subject || task.workflowInstanceDataFields.Subject
|
||||
subject = subject.toLowerCase();
|
||||
return subject.includes(this.searchSubject.toLowerCase())
|
||||
})
|
||||
} else {
|
||||
this.AllProcess = this.TaskService.AllProcess
|
||||
}
|
||||
|
||||
this.AllProcess = this.TaskService.reorderList(this.ordinance, AllProcess)
|
||||
} else {
|
||||
const AllProcess = this.TaskService.AllProcess
|
||||
this.AllProcess = this.TaskService.reorderList(this.ordinance, AllProcess)
|
||||
}
|
||||
}
|
||||
|
||||
checkFilter() {
|
||||
|
||||
Reference in New Issue
Block a user