|
|
@ -77,7 +77,7 @@ |
|
|
|
<el-form-item label="电话"> |
|
|
|
<el-form-item label="电话"> |
|
|
|
<el-input disabled v-model="form.phone" placeholder="请输入电话号码" maxlength="11"></el-input> |
|
|
|
<el-input disabled v-model="form.phone" placeholder="请输入电话号码" maxlength="11"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="订单金额(万)" prop="orderAmount"> |
|
|
|
<el-form-item label="订单金额(元)" prop="orderAmount"> |
|
|
|
<el-input disabled oninput="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" type="number" v-model="form.orderAmount" placeholder="请输入订单金额"></el-input> |
|
|
|
<el-input disabled oninput="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" type="number" v-model="form.orderAmount" placeholder="请输入订单金额"></el-input> |
|
|
|
</el-form-item> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-col> |
|
|
@ -238,7 +238,7 @@ |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table-column> |
|
|
|
<!-- 金额自动计算,计算方式:账号数*成交价,且可以手动修改,保留两位小数 --> |
|
|
|
<!-- 金额自动计算,计算方式:账号数*成交价,且可以手动修改,保留两位小数 --> |
|
|
|
<el-table-column label="总金额(万)" align="center"> |
|
|
|
<el-table-column label="总金额(元)" align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<div class="small"> |
|
|
|
<div class="small"> |
|
|
|
<el-input :disabled="disabled||editDisabled" @change="[allAmount($event,scope.row),allAmountChange($event,scope.row)]" oninput="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" v-model="scope.row.totalAmount" placeholder="请输入"type="text"></el-input> |
|
|
|
<el-input :disabled="disabled||editDisabled" @change="[allAmount($event,scope.row),allAmountChange($event,scope.row)]" oninput="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" v-model="scope.row.totalAmount" placeholder="请输入"type="text"></el-input> |
|
|
@ -670,10 +670,12 @@ export default { |
|
|
|
contract = res.orderDetails.contractInformation?res.orderDetails.contractInformation:{},// 合同 |
|
|
|
contract = res.orderDetails.contractInformation?res.orderDetails.contractInformation:{},// 合同 |
|
|
|
list = res.orderDetails.orderOther// 俩列表 |
|
|
|
list = res.orderDetails.orderOther// 俩列表 |
|
|
|
list.map(e=>{ |
|
|
|
list.map(e=>{ |
|
|
|
e.ship?e.ship=true:e.ship = false |
|
|
|
e.ship===1?e.ship=true:e.ship = false |
|
|
|
e.isEnable?e.isEnable=false:e.isEnable=true |
|
|
|
e.isEnable?e.isEnable=false:e.isEnable=true |
|
|
|
}) |
|
|
|
}) |
|
|
|
let dataArr = list.filter(e=>{// 数据平台 |
|
|
|
let dataArr = list.filter(e=>{// 数据平台 |
|
|
|
|
|
|
|
e.startTime = e.startTime.split(" ")[0] |
|
|
|
|
|
|
|
e.endTime = e.endTime.split(" ")[0] |
|
|
|
return e.authority===0 |
|
|
|
return e.authority===0 |
|
|
|
}), |
|
|
|
}), |
|
|
|
classArr = list.filter(e=>{// 课程权限 |
|
|
|
classArr = list.filter(e=>{// 课程权限 |
|
|
@ -708,13 +710,17 @@ export default { |
|
|
|
this.contractTime = [contract.startTime,contract.endTime] |
|
|
|
this.contractTime = [contract.startTime,contract.endTime] |
|
|
|
} |
|
|
|
} |
|
|
|
this.dataPlatform = dataArr |
|
|
|
this.dataPlatform = dataArr |
|
|
|
|
|
|
|
console.log(this.dataPlatform,'当前的值'); |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 新增订单 |
|
|
|
// 新增订单 |
|
|
|
addOrder(){ |
|
|
|
addOrder(){ |
|
|
|
|
|
|
|
if(this.dataPlatform.length===0){ |
|
|
|
|
|
|
|
return this.$message.error('请选择产品后再确认订单!') |
|
|
|
|
|
|
|
} |
|
|
|
let verify = |
|
|
|
let verify = |
|
|
|
this.dataPlatform.some(e=>{ |
|
|
|
this.dataPlatform.some(e=>{ |
|
|
|
if(!e.periodOfUse||!e.finalPrice||!e.accountNum||!totalAmount){ |
|
|
|
if(!e.periodOfUse||!e.finalPrice||!e.accountNum||!e.totalAmount){ |
|
|
|
return false |
|
|
|
return false |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
return true |
|
|
|
return true |
|
|
@ -960,7 +966,7 @@ export default { |
|
|
|
console.log(year,'当前年'); |
|
|
|
console.log(year,'当前年'); |
|
|
|
console.log(+year + parseInt((+month+(+e))/12) ,'处理过的年',parseInt((+month+(+e))%12)===0,'处理的值'); |
|
|
|
console.log(+year + parseInt((+month+(+e))/12) ,'处理过的年',parseInt((+month+(+e))%12)===0,'处理的值'); |
|
|
|
console.log((+month+(+e))%12,'月份%12'); |
|
|
|
console.log((+month+(+e))%12,'月份%12'); |
|
|
|
let endYear = year + (parseInt((+month+(+e))/12)?0:parseInt((+month+(+e))/12)) + char + completeDate((+month+(+e))%12) + char +completeDate(day); |
|
|
|
let endYear = year + (parseInt((+month+(+e))/12)===0?0:parseInt((+month+(+e))/12)) + char + completeDate((+month+(+e))%12) + char +completeDate(day); |
|
|
|
console.log(endYear,'endYear'); |
|
|
|
console.log(endYear,'endYear'); |
|
|
|
|
|
|
|
|
|
|
|
// 得出起始年月日 |
|
|
|
// 得出起始年月日 |
|
|
@ -979,7 +985,7 @@ export default { |
|
|
|
// 计算成交总额 |
|
|
|
// 计算成交总额 |
|
|
|
dealComputers(e,row){ |
|
|
|
dealComputers(e,row){ |
|
|
|
if(row.finalPrice&&row.accountNum){ |
|
|
|
if(row.finalPrice&&row.accountNum){ |
|
|
|
row.totalAmount = (row.finalPrice*row.accountNum/10000).toFixed(2); |
|
|
|
row.totalAmount = (((row.finalPrice*100)*(row.accountNum*100))/100).toFixed(2); |
|
|
|
} |
|
|
|
} |
|
|
|
this.allAmount() |
|
|
|
this.allAmount() |
|
|
|
}, |
|
|
|
}, |
|
|
|