|
|
|
@ -178,13 +178,10 @@ |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="折扣率" align="center" min-width="110"> |
|
|
|
|
<el-table-column label="折扣率 " align="center" min-width="100"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div class="small"> |
|
|
|
|
<el-input disabled v-model="scope.row.marketValue" placeholder="" |
|
|
|
|
type="text"></el-input> |
|
|
|
|
<span style="margin-left:5px">万</span> |
|
|
|
|
</div> |
|
|
|
|
<el-input disabled v-model="scope.row.discountRate" placeholder="" |
|
|
|
|
type="text" size="small" style="width: 100%"></el-input> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="成交价" align="center" min-width="130"> |
|
|
|
@ -203,9 +200,9 @@ |
|
|
|
|
<el-table-column label="结算价" align="center" min-width="130"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div class="small"> |
|
|
|
|
<el-input :class="scope.row.finalPrice === '' && whetherSubmit?'red':''" |
|
|
|
|
<el-input :class="scope.row.settlementPrice === '' && whetherSubmit?'red':''" |
|
|
|
|
:disabled="viewDisabled" |
|
|
|
|
@input="scope.row.finalPrice = scope.row.finalPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" |
|
|
|
|
@input="scope.row.settlementPrice = scope.row.settlementPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" |
|
|
|
|
@change="[allAmount($event,scope.row),calculateDiscount($event,scope.row)]" |
|
|
|
|
v-model="scope.row.settlementPrice" |
|
|
|
|
type="text"></el-input> |
|
|
|
@ -213,12 +210,6 @@ |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="折扣率 " align="center" min-width="100"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-input disabled v-model="scope.row.discountRate" placeholder="" |
|
|
|
|
type="text" size="small" style="width: 100%"></el-input> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="端口地址 " align="center" min-width="100"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-button @click="configure(scope.row)">配置</el-button> |
|
|
|
@ -333,7 +324,7 @@ |
|
|
|
|
<el-table-column label="市场单价" align="center" min-width="160"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div class="small"> |
|
|
|
|
<el-input disabled v-model="scope.row.marketValue" placeholder="" |
|
|
|
|
<el-input disabled v-model="scope.row.marketPrice" placeholder="" |
|
|
|
|
type="text"></el-input> |
|
|
|
|
<span style="margin-left:5px">元 / 账号</span> |
|
|
|
|
</div> |
|
|
|
@ -389,9 +380,9 @@ |
|
|
|
|
<el-table-column label="结算价" align="center" min-width="130"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div class="small"> |
|
|
|
|
<el-input :class="scope.row.finalPrice === '' && whetherSubmit?'red':''" |
|
|
|
|
<el-input :class="scope.row.settlementPrice === '' && whetherSubmit?'red':''" |
|
|
|
|
:disabled="viewDisabled" |
|
|
|
|
@input="scope.row.finalPrice = scope.row.finalPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" |
|
|
|
|
@input="scope.row.settlementPrice = scope.row.settlementPrice.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" |
|
|
|
|
@change="[allAmount($event,scope.row),calculateDiscount($event,scope.row)]" |
|
|
|
|
v-model="scope.row.settlementPrice" |
|
|
|
|
type="text"></el-input> |
|
|
|
@ -1074,7 +1065,7 @@ export default { |
|
|
|
|
getCourseJurisdiction() { |
|
|
|
|
let param = { |
|
|
|
|
pageSize: 10, |
|
|
|
|
pageNum: this.platfromPage, |
|
|
|
|
pageNum: this.coursePage, |
|
|
|
|
isEnable: 0, // 只获取上架的课程 |
|
|
|
|
curriculumName: this.curriculumName |
|
|
|
|
}; |
|
|
|
@ -1121,7 +1112,8 @@ export default { |
|
|
|
|
startTime: new Date(),// 开始 |
|
|
|
|
endTime: "", // 终止 |
|
|
|
|
remainingPeriod: "",// 剩余期限 |
|
|
|
|
marketValue: e.marketPrice,// 市场价 |
|
|
|
|
marketValue: '', // 市场价 |
|
|
|
|
marketPrice: e.marketPrice, // 市场单价 |
|
|
|
|
finalPrice: orderType === 2 ? 0 : '',// 成交价 |
|
|
|
|
discountRate: "",// 折扣率 |
|
|
|
|
accountNum: "",// 账号数 |
|
|
|
@ -1130,6 +1122,9 @@ export default { |
|
|
|
|
ship: 0,// 发货否(0未发货,1已发货,默认不发货) |
|
|
|
|
authority: 1, // 区分权限 0为数据平台权限,1为课程权限 |
|
|
|
|
options: 1, |
|
|
|
|
settlementPrice: '', // 结算单价 |
|
|
|
|
settlementMethod: '', // 结算方式,0为单价,1为分成 |
|
|
|
|
businessProportion: '', // 商务占比 |
|
|
|
|
}; |
|
|
|
|
that.coursePermissions.push(obj); |
|
|
|
|
}; |
|
|
|
@ -1243,6 +1238,9 @@ export default { |
|
|
|
|
ship: 0,// 发货否(0未发货,1已发货,默认不发货) |
|
|
|
|
authority: 0,// 数据平台权限 |
|
|
|
|
options:1, |
|
|
|
|
settlementPrice: '', // 结算单价 |
|
|
|
|
settlementMethod: '', // 结算方式,0为单价,1为分成 |
|
|
|
|
businessProportion: '', // 商务占比 |
|
|
|
|
}; |
|
|
|
|
that.dataPlatformPermissions.push(obj); |
|
|
|
|
}; |
|
|
|
@ -1379,6 +1377,7 @@ export default { |
|
|
|
|
}, |
|
|
|
|
// 使用期限转换以及计算剩余天数 |
|
|
|
|
deadLine(e,row,options, isDate) { |
|
|
|
|
debugger |
|
|
|
|
let optionsData = '' |
|
|
|
|
if(e > 0){ |
|
|
|
|
if (options == 1){ |
|
|
|
@ -1400,6 +1399,18 @@ export default { |
|
|
|
|
let endYear = timestamp - time |
|
|
|
|
let endYears = endYear/1000/60/60/24 |
|
|
|
|
row.remainingPeriod = endYears |
|
|
|
|
// 计算市场价(课程才需要) |
|
|
|
|
if (row.authority) { |
|
|
|
|
const unit = row.options // 使用期限单位 |
|
|
|
|
const useUnit = row.periodOfUse // 使用期限 |
|
|
|
|
const price = row.marketPrice // 市场单价 |
|
|
|
|
// 结算单价是元/年,所以如果选择的不是年,要进行换算(日:/365,月:/12) |
|
|
|
|
row.marketValue = (!unit ? |
|
|
|
|
price / 365 * useUnit : |
|
|
|
|
unit === 1 ? |
|
|
|
|
price / 12 * useUnit : |
|
|
|
|
price * useUnit).toFixed(2) |
|
|
|
|
} |
|
|
|
|
// 只有改变了起止日期才需要调接口查询订单,该接口作用是把开始时间传过去,会返回一个提示或者时间,如果是时间,则把时间+1天,如果是提示,则无法保存 |
|
|
|
|
if (isDate) { |
|
|
|
|
const cId = row.dataOrCourseId |
|
|
|
|