mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
improve
This commit is contained in:
@@ -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