fixed the refresh button for completed order

This commit is contained in:
Mohd Arief
2018-08-17 11:00:35 +08:00
parent 117f2cdaee
commit 424097e035
2 changed files with 21 additions and 8 deletions
+9 -4
View File
@@ -1,7 +1,7 @@
<template>
<div>
<div align="right">
<el-button :loading="loading_btn" type="primary" size="mini" @click="RefreshBooking()">Refresh</el-button>
<el-button :loading="loading_btn" type="primary" size="mini" @click="RefreshBooking(); RefreshBookingCompleteTable()">Refresh</el-button>
</div>
<!-- Booking Table -->
@@ -112,9 +112,6 @@
</el-tabs>
<!-- Booking Table-end -->
</div>
</template>
@@ -176,6 +173,14 @@ export default {
})
})
},
RefreshBookingCompleteTable() {
let $this = this
this.loading_btn = true
axios.get(this.completeBookingurl).then(response => {
this.loading_btn = false;
this.bookingTableComplete = response.data.data
})
},
makePagination(data){
let pagination ={
current_page: data.current_page,
+12 -4
View File
@@ -278,7 +278,7 @@
<br>
<hr>
<div align="right">
<el-button :loading="loading_btn" type="primary" size="mini" @click="RefreshBooking()">Refresh</el-button></div>
<el-button :loading="loading_btn" type="primary" size="mini" @click="RefreshBooking(); RefreshBookingCompleteTable()">Refresh</el-button></div>
<!-- Booking Table -->
<el-tabs type="border-card" class="table-switch">
@@ -525,7 +525,7 @@ export default {
this.getBooking();
this.initBooking();
this.getRate();
this.getCompleteBooking();
this.getBookingTableComplete();
},
methods: {
getBooking(){
@@ -535,7 +535,7 @@ export default {
$this.makePagination(response.data)
})
},
getCompleteBooking(){
getBookingTableComplete(){
let $this = this
axios.get(this.completeBookingurl).then(response => {
this.bookingTableComplete = response.data.data
@@ -582,6 +582,14 @@ export default {
})
})
},
RefreshBookingCompleteTable() {
let $this = this
this.loading_btn = true
axios.get(this.completeBookingurl).then(response => {
this.loading_btn = false;
this.bookingTableComplete = response.data.data
})
},
makePagination(data){
let pagination ={
current_page: data.current_page,
@@ -608,7 +616,7 @@ export default {
},
fetchCompletePaginateBooking(url) {
this.completeBookingurl = url
this.getCompleteBooking()
this.getBookingTableComplete()
},