mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
order by date
This commit is contained in:
@@ -9,6 +9,7 @@ import { AlertService } from 'src/app/services/alert.service';
|
||||
import { PedidoPage } from 'src/app/pages/gabinete-digital/pedidos/pedido/pedido.page';
|
||||
import { PedidosStore } from 'src/app/store/pedidos-store.service';
|
||||
import { CustomTaskPipe } from 'src/app/pipes/custom-task.pipe';
|
||||
import { SortService } from 'src/app/services/functions/sort.service';
|
||||
@Component({
|
||||
selector: 'app-pedidos',
|
||||
templateUrl: './pedidos.page.html',
|
||||
@@ -43,6 +44,7 @@ export class PedidosPage implements OnInit {
|
||||
private processes:ProcessesService,
|
||||
private modalController: ModalController,
|
||||
private alertService: AlertService,
|
||||
private sortService: SortService,
|
||||
) {
|
||||
this.profile = 'mdgpr';
|
||||
}
|
||||
@@ -70,7 +72,7 @@ export class PedidosPage implements OnInit {
|
||||
segmentChanged(ev: any) {
|
||||
this.LoadList();
|
||||
}
|
||||
|
||||
|
||||
async LoadList() {
|
||||
|
||||
this.skeletonLoader = true;
|
||||
@@ -92,7 +94,7 @@ export class PedidosPage implements OnInit {
|
||||
let task: customTask = this.customTaskPipe.transform(element);
|
||||
this.parecerList.push(task);
|
||||
});
|
||||
this.pedidosstore.resetparecer(this.parecerList);
|
||||
this.pedidosstore.resetparecer(this.sortService.sortArrayByDate(this.parecerList));
|
||||
|
||||
}
|
||||
else if(this.segment == 'deferimento') {
|
||||
@@ -108,7 +110,7 @@ export class PedidosPage implements OnInit {
|
||||
let task: customTask = this.customTaskPipe.transform(element);
|
||||
this.deferimentoList.push(task);
|
||||
});
|
||||
this.pedidosstore.resetdeferimento(this.deferimentoList);
|
||||
this.pedidosstore.resetdeferimento(this.sortService.sortArrayByDate(this.deferimentoList));
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user