From b8cd908a5868225fcc13d8db38870fce137d7bdd Mon Sep 17 00:00:00 2001 From: omair saleh Date: Mon, 21 Jun 2021 14:39:48 +0800 Subject: [PATCH] create urgent list page --- .../sections/UrgentListSectionComponent.vue | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/resources/assets/vue/components/bookings/sections/UrgentListSectionComponent.vue b/resources/assets/vue/components/bookings/sections/UrgentListSectionComponent.vue index c7e6c174..e96550b5 100644 --- a/resources/assets/vue/components/bookings/sections/UrgentListSectionComponent.vue +++ b/resources/assets/vue/components/bookings/sections/UrgentListSectionComponent.vue @@ -22,7 +22,9 @@
- +
+ {{n}} +
@@ -32,19 +34,25 @@ export default { data(){ return { - list: [] + list: [], + pagination: { + last_page: 1 + } } }, created(){ - this.submit(route('api.transaction.list') + '?page=1&filters=' + JSON.stringify({status: 2, type: 3, per_page: 50, order_by: { - column: 'id', - DESC: true - }}), 'get', 'urgentListSection', false, true) + }, methods: { + fetchList(Page = 1){ + this.submit(route('api.transaction.list') + '?page='+ Page +'&filters=' + JSON.stringify({status: 2, type: 3, per_page: 50, order_by: { + column: 'id', + DESC: true + }}), 'get', 'urgentListSection', false, true) + }, successHandler(response){ this.list = response.payload.data; - this.$refs.pagination.makePagination(response.payload.meta, response.payload.links); + this.pagination = response.payload.meta; } } }