Commit bc6796e1 authored by hezhen's avatar hezhen

Merge branch 'base-modify'

# Conflicts:
#	src/views/order/rentVehicleInfo/index.vue
parents 07e1e4b6 67eeab46
......@@ -191,10 +191,13 @@ export function dayList(day) {
}
// 日历价格设置
export function add_edit(params) {
export function add_edit(params, date) {
return fetch({
url: '/vehicle/admin/vehicle_model/calendar_price/add_edit',
url: '/vehicle/admin/vehicle_model/calendar_price/add_edit/' + date,
method: 'post',
headers: {
'Content-Type': 'application/json;charset=UTF-8'
},
data: params
});
}
......
......@@ -381,7 +381,7 @@ export default {
duration: 2000
})
} else {
this.returnForm.id = this.form.detailId
this.returnForm.id = this.orderDetailInfo.orderRentVehicleDetail.id
updateEndCompany(this.returnForm).then(data => {
if (data.status == 200) {
this.$notify({
......@@ -407,7 +407,7 @@ export default {
resetCar() {
this.clearFrom()
this.resetCarVisible = true
this.resetCarForm.no = this.form.no
this.resetCarForm.no = this.orderDetailInfo.no
},
cancelResetCar() {
this.resetCarVisible = false
......@@ -435,7 +435,7 @@ export default {
duration: 2000
})
this.resetCarVisible = false
this.form.vehicleNumberPlat = this.resetCarForm.numberPlate
this.orderDetailInfo.vehicleNumberPlat = this.resetCarForm.numberPlate
this.updateNumberPlat = true
} else {
this.$notify({
......
This diff is collapsed.
......@@ -58,7 +58,7 @@
</el-table-column>
<el-table-column align="center" label="收款账号">
<template scope="scope">
<span>{{scope.row.accountNumber}}</span>
<span>{{scope.row.accountName}}</span>
</template>
</el-table-column>
......@@ -111,8 +111,8 @@
<el-radio v-model="dialogFrom.status" label="1">通过</el-radio>
<el-radio v-model="dialogFrom.status" label="2">拒绝</el-radio>
</el-form-item>
<el-form-item label="订单号" v-if="dialogFrom.status==1" required>
<el-input v-model="dialogFrom.cono" placeholder="请输入订单号"></el-input>
<el-form-item label="订单号" v-if="dialogFrom.status==1 && this.activeOfflineWay == 2" required>
<el-input v-model="dialogFrom.payMentNo" placeholder="请输入订单号"></el-input>
</el-form-item>
<el-form-item label="拒绝原因" v-if="dialogFrom.status==2" required>
<el-input type="textarea" v-model="dialogFrom.reason" placeholder="拒绝原因"></el-input>
......@@ -120,7 +120,7 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancelHandel">取 消</el-button>
<el-button type="primary" @click="edit('dialogFrom')">确 定</el-button>
<el-button type="primary" @click="edit('dialogFrom')" :loading="submitBtn">确 定</el-button>
</div>
</el-dialog>
</div>
......@@ -155,6 +155,7 @@ export default {
},
data() {
return {
submitBtn:false,
time:[],//提现时间
typeOptions: [
{
......@@ -170,6 +171,7 @@ export default {
val: '1'
}
],
activeOfflineWay:null,
dialogVisible: false,
BASE_API: process.env.BASE_API,
showLoadingBody: false,
......@@ -190,7 +192,7 @@ export default {
tableKey: 0,
dialogFrom: {
status: '1',
cono: '',
payMentNo: '',
reason: ''
}
}
......@@ -254,14 +256,16 @@ export default {
},
handleUpdate(row) {
this.dialogFrom.cathId = row.id
this.activeOfflineWay = row.offlineWay
this.dialogVisible = true
},
edit(formName) {
var that = this
const set = this.$refs
set[formName].validate(valid => {
if (this.dialogFrom.status == 1) {
if (this.dialogFrom.cono == '') {
if (this.dialogFrom.status == 1 && this.activeOfflineWay == 2) {
if (this.dialogFrom.payMentNo == '') {
this.$notify({
title: '警告',
message: '请输入订单号',
......@@ -283,6 +287,7 @@ export default {
}
}
if (valid) {
this.submitBtn = true;
editObj(that.dialogFrom).then(response => {
if (response.status === 200) {
this.dialogVisible = false
......@@ -293,6 +298,7 @@ export default {
type: 'success',
duration: 2000
})
this.submitBtn = false;
} else {
this.$notify({
title: '失败',
......@@ -302,6 +308,7 @@ export default {
type: 'error',
duration: 2000
})
this.submitBtn = false;
}
})
} else {
......
This diff is collapsed.
......@@ -161,7 +161,7 @@
<vehiclePlanModal v-if="anpai" :currentItem="currentItem" v-on:anpaiDialogEvent = "anpaiDialogEvent"></vehiclePlanModal>
<!--租车详情弹框-->
<!--rentOrder-->
<rentOrderDetailModal :form="rentOrderInfo" :rentCostDetail="rentCostDetail" v-if="rentOrder" v-on:rentOrderDetailDialogEvent="rentOrderDetailDialogEvent"></rentOrderDetailModal>
<rentOrderDetailModal :orderDetailInfo="orderDetailInfo" v-if="rentOrder" v-on:rentOrderDetailDialogEvent="rentOrderDetailDialogEvent"></rentOrderDetailModal>
<!--旅游订单详情-->
<tourOrderDetailModal :tourRow="tourRow" v-if="tourDialogVisible" v-on:tourOrderDetailDialogEvent="tourOrderDetailDialogEvent"></tourOrderDetailModal>
<!--禁用弹框-->
......@@ -359,7 +359,7 @@
} from 'api/base_info/branch_company/';
import {
getAllBranchCompanyByZoneId,
page
orderDetail
} from 'api/order/rentVehicle';
import {
formatDate
......@@ -461,7 +461,7 @@
anpai: false,//安排用车弹框
jinyong: false,//禁用弹框
currentItem: {},//待操作数据
rentOrderInfo: {},//租车订单详情
orderDetailInfo: {},//租车订单详情
rentCostDetail: {},//租车订单费用明细
tourDialogVisible: false,//旅游订单弹框
tourRow: {},//旅游订单详情-当前行
......@@ -686,50 +686,58 @@
* 根据订单号获取订单详情
* */
getOneVechi: function(orderNo) {
let params = {
oneNo: orderNo
};
page(params).then(res => {
if (res.status == 200) {
let a = res.data.data[0];
let vehicleUserLicenses = {};
// if (a.status == 5) {
// vehicleUserLicenses = {
// name: a.orderVehicleCrosstownDto.licenseName,
// phone: a.orderVehicleCrosstownDto.licensePhone,
// idCard: a.orderVehicleCrosstownDto.licenseIdCard
// };
// } else {
// if (a.vehicleUserLicenses.length > 0) {
// vehicleUserLicenses = a.vehicleUserLicenses[0];
// }
// }
a.orderRentVehicleDetail.startTime = timestamp2Date(a.orderRentVehicleDetail.startTime);
a.orderRentVehicleDetail.endTime = timestamp2Date(a.orderRentVehicleDetail.endTime);
let arr = a.picture ? a.picture.split(",") : [];
a.picture = arr.length > 0 ? arr[0] : "";
a.payTime = timestamp2Date(a.payTime);
this.rentOrderInfo = a;
this.costDetail = JSON.parse(this.rentOrderInfo.orderRentVehicleDetail.costDetail);
var cost = '';
this.costDetail.children.map(function(a) {
cost += a.key + ":" +a.detail+" ";
});
this.rentCostDetail = cost;
if(this.rentOrderInfo.orderRentVehicleDetail.driverType==1) {
this.serviceCost = this.rentOrderInfo.orderRentVehicleDetail.dayNum * 600
}
this.rentOrder = true;
} else {
this.$notify({
title: '失败',
message: '操作失败!',
type: 'error',
duration: 2000
});
}
});
var param = {
"orderNo":orderNo,
"flag" : true
}
orderDetail(param).then(response => {
this.orderDetailInfo = response.data
if(this.orderDetailInfo && this.orderDetailInfo.memberLevel) {
if(this.orderDetailInfo.memberLevel == 1) {
this.orderDetailInfo.memberName = "普通会员"
}
if(this.orderDetailInfo.memberLevel == 2) {
this.orderDetailInfo.memberName = "黄金会员"
}
if(this.orderDetailInfo.memberLevel == 3) {
this.orderDetailInfo.memberName = "钻石会员"
}
if(this.orderDetailInfo.orderRentVehicleDetail.costDetail) {
this.orderDetailInfo.costDetail = JSON.parse(this.orderDetailInfo.orderRentVehicleDetail.costDetail)
}
if(this.orderDetailInfo.costDetail.paramJson) {
this.orderDetailInfo.rentVehiclePriceVO = JSON.parse(this.orderDetailInfo.costDetail.paramJson)
}
if(this.orderDetailInfo.items) {
for (var i = 0;i< this.orderDetailInfo.items.length;i++) {
if(this.orderDetailInfo.items[i].type == 104) {
this.orderDetailInfo.carArticlesJson = this.orderDetailInfo.items[i].detail
}
}
}
if (this.orderDetailInfo.status == 2) {
this.orderDetailInfo.ststusName = '取消'
}
if (this.orderDetailInfo.status == -1) {
this.orderDetailInfo.ststusName = '定损中'
}
if (this.orderDetailInfo.status == 3) {
this.orderDetailInfo.ststusName = '待付款'
}
if (this.orderDetailInfo.status == 4) {
this.orderDetailInfo.ststusName = '待出行'
}
if (this.orderDetailInfo.status == 5) {
this.orderDetailInfo.ststusName = '出行中'
}
if (this.orderDetailInfo.status == 6) {
this.orderDetailInfo.ststusName = '已完成'
}
}
this.rentOrder = true
})
},
/**
* 关闭保养弹框后逻辑处理
......
......@@ -366,15 +366,22 @@ export default {
}
})
}
if (params == '') {
this.$message.error('请设置不同车型不同价格4')
return false
add_edit('',this.activeTime).then(data => {
if (data.status == 200) {
this.$message.success('设置成功')
this.chooseData = []
this.getList()
} else {
this.$message.error(data.message)
}
})
} else {
add_edit(params).then(data => {
add_edit(params,this.activeTime).then(data => {
if (data.status == 200) {
this.$message.success('设置成功')
this.chooseData = []
this.changeIsGlobal(0)
this.getList()
} else {
this.$message.error(data.message)
......@@ -398,8 +405,8 @@ export default {
data.data.forEach(element => {
element.multiple = element.multiple || ''
element.price = element.price || ''
element.level = element.level||''
element.freeDays = element.freeDays||''
element.level = element.level || ''
element.freeDays = element.freeDays || ''
})
this.dayListData = data.data
this.setMultiplePop = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment