fix 404 not found for upload user bankslip

added display term on booking table
This commit is contained in:
Jack Goh
2018-06-21 14:31:53 +08:00
parent 23b024c2fb
commit 3c263b56ea
2 changed files with 16 additions and 80 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ class BookingController extends Controller
{
public function index(){
$bookings = Booking::select('id', 'created_at', 'status', 'rate', 'amount', 'bia', 'verification_status')
$bookings = Booking::select('id', 'created_at', 'status', 'rate', 'term', 'amount', 'bia', 'verification_status')
->where('user_id',Auth::user()->id)
->get();
+15 -79
View File
@@ -239,17 +239,17 @@
<el-row :gutter="20">
<div>
<el-table :data="bookingTable">
<el-table-column label="No." width="50">
<el-table-column label="No." width="100">
<el-button size="mini" @click="handleEdit(scope.$index, scope.row)">Update</el-button>
<el-button type="text" slot-scope="scope" @click="(event) => { BookingStatus(scope.row.status, scope.row.id) }"> {{scope.row.id}}</el-button>
</el-table-column>
<el-table-column label="DateTime" prop="created_at" width="180" sortable/>
<!-- <el-table-column label="Term" :filters="[{text: 'X1', value: 'X1'}, {text: 'X2', value: 'X2'}]" :filter-method="filterHandler">
<el-table-column label="Term" prop="term" :filters="[{text: 'X1', value: 'X1'}, {text: 'X2', value: 'X2'}]" width="100" :filter-method="filterHandler">
</el-table-column> -->
<el-table-column label="Rate" width="74" prop="rate" />
<el-table-column label="Amount" prop="amount" justify="center" width="110" />
<el-table-column :filters="[{text: 'RMB', value: 'RMB'}, {text: 'USD', value: 'USD'}]" :filter-method="filterHandler" label="Transfer Amount"
prop="transfer_amount" width="150" />
prop="transfer_amount" width="170" />
<!-- <el-table-column label="ETA" sortable width="100"/> -->
<!-- <el-table-column label="Payment Method" :filters="[{text: 'Cash', value: 'Cash'}, {text: 'Cheque', value: 'Cheque'}, {text: 'BA', value: 'BA'}]" :filter-method="filterHandler">
</el-table-column> -->
@@ -268,10 +268,11 @@
<!-- <el-table-column prop="timeout" label="Bankin Timeout" /> -->
<el-table-column :filters="[{ text: 'Success', value: 'Success' }, { text: 'Pending', value: 'Pending' }]" :filter-method="filterTag"
label="" width="180" filter-placement="bottom-end">
<template slot-scope="scope">
<el-button size="mini" @click="handleEdit(scope.$index, scope.row)">Update</el-button>
<el-button type="text" slot-scope="scope" @click="(event) => { BookingStatus(scope.row.status, scope.row.id) }"> View Status </el-button>
<!-- <template slot-scope="scope">
<el-button size="mini" @click="handleEdit(scope.$index, scope.row)">View Status</el-button>
<el-button size="mini" type="danger" @click="BookingStatus(scope.$index, scope.row)">Cancel</el-button>
</template>
</template> -->
</el-table-column>
</el-table>
</div>
@@ -353,72 +354,7 @@
dialogFormVisible: false,
dialogFormVisible1: false,
formLabelWidth: '0px',
bookingTable: [{
created_at: '12/1/2018',
id: '12',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(1/6)',
status_desc: 'Waiting for payment',
timeout: '56:00:00',
status: 2
},
{
created_at: '12/1/2018',
id: '13',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(2/6)',
status_desc: 'Waiting verification',
timeout: '56:00:00',
status: 3
},
{
created_at: '12/1/2018',
id: '14',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(3/6)',
status_desc: 'Processing transfer',
timeout: '56:00:00',
status: 4
},
{
created_at: '12/1/2018',
id: '15',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(4/6)',
status_desc: 'Transfer Complete, please upload your PO',
timeout: '56:00:00',
status: 5
},
{
created_at: '12/1/2018',
id: '16',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(5/6)',
status_desc: 'Processing invoice',
timeout: '56:00:00',
status: 6
},
{
created_at: '12/1/2018',
id: '17',
rate: '1.23',
amount: 'RM 1000',
transfer_amount: 'RMB 10000',
track_status: '(6/6)',
status_desc: 'Order Completed',
timeout: '56:00:00',
status: 6
}
bookingTable: [
],
bookingConfirmTable: {
date: 'undefined',
@@ -544,7 +480,7 @@
return
})
},
BookingStatus(status, row) {
BookingStatus(status, booking_id) {
console.log(status)
// TODO : Get booking status from server
this.status = status
@@ -553,39 +489,39 @@
case 1:
this.$router.push({
name: 'booking.user.upload',
params: {id: "12" }
params: {id: booking_id }
})
case 2:
this.$router.push({
name: 'booking.user.upload',
params: {id: "12" }
params: {id: booking_id }
})
break;
case 3:
this.$router.push({
name: 'booking.confirmation',
params: {id: "1" }
params: {id: booking_id }
})
break;
case 4:
this.$router.push({
name: 'booking.transfer',
params: {id: "1" }
params: {id: booking_id }
})
break;
case 5:
this.$router.push({
name: 'booking.user.uploadpo',
params: {id: "1" }
params: {id: booking_id }
})
break;
case 6:
this.$router.push({
name: 'booking.complete',
params: {id: "1" }
params: {id: booking_id }
})
break;
default: