mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
merge developer to feature/search
This commit is contained in:
@@ -61,13 +61,21 @@ export class SearchPage implements OnInit {
|
||||
|
||||
ngOnInit() {
|
||||
}
|
||||
|
||||
close(){
|
||||
this.modalController.dismiss();
|
||||
}
|
||||
|
||||
|
||||
changeOrder(order: string){
|
||||
this.ordinance = order;
|
||||
reorderList(orderBy: string){
|
||||
|
||||
this.ordinance = orderBy;
|
||||
|
||||
if(this.ordinance == 'recent'){
|
||||
this.showSearchDocuments = this.sortArrayISODate(this.searchDocuments);
|
||||
} else {
|
||||
this.showSearchDocuments = this.sortArrayISODate(this.searchDocuments).reverse();
|
||||
}
|
||||
}
|
||||
|
||||
sortArrayISODate(myArray: any){
|
||||
@@ -82,15 +90,17 @@ export class SearchPage implements OnInit {
|
||||
*/
|
||||
basicSearch(){
|
||||
|
||||
console.log(this.searchDocumentDate);
|
||||
|
||||
this.search.basicSearch(this.searchSubject, this.searchDocumentDate, this.searchSender
|
||||
,this.searchOrganicEntiry, this.searchDocTypeId).subscribe(res=>{
|
||||
|
||||
res.Categories.forEach( e => {
|
||||
e['Active'] = false;
|
||||
});
|
||||
|
||||
// bind respose
|
||||
this.searchCategories = res.Categories;
|
||||
|
||||
this.searchDocuments = this.sortArrayISODate(res.Documents);
|
||||
this.showSearchDocuments = this.sortArrayISODate(this.searchDocuments);
|
||||
|
||||
// hide show document
|
||||
if(this.searchDocuments.length >= 1){
|
||||
|
||||
Reference in New Issue
Block a user