Commit 4da93ae0 authored by 黄奎's avatar 黄奎

页面修改

parent c8630f49
<style>
.coursePrice_table th{
.coursePrice_table th {
height: 40px;
background-color: rgb(238, 238, 239);
}
.coursePrice_table tr{
height:45px;
.coursePrice_table tr {
height: 45px;
}
.course_Line{
.course_Line {
width: 3px;
height: 10px;
display: inline-block;
......@@ -32,8 +34,8 @@
卖价
</td>
<td colspan="2">
<q-input filled stack-label maxlength="8" style="padding-bottom:0;width:390px;margin-left:10px;" dense v-model="priceObj.courseObj.SellPrice"
ref="SellPrice" label="卖价"
<q-input filled stack-label maxlength="8" style="padding-bottom:0;width:390px;margin-left:10px;" dense
v-model="priceObj.courseObj.SellPrice" ref="SellPrice" label="卖价"
@keyup.native="checkPrice(priceObj.courseObj, 'SellPrice')" :rules="[val => !!val || '请填写卖价']" />
</td>
</tr>
......@@ -103,8 +105,8 @@
一般同行
</td>
<td>
<q-input filled stack-label dense v-model="priceObj.courseObj.B2BRebateRatio"
ref="B2BRebateRatio" @keyup.native="checkPrice(priceObj.courseObj, 'B2BRebateRatio'),getShouBAO(3)" suffix="%" />
<q-input filled stack-label dense v-model="priceObj.courseObj.B2BRebateRatio" ref="B2BRebateRatio"
@keyup.native="checkPrice(priceObj.courseObj, 'B2BRebateRatio'),getShouBAO(3)" suffix="%" />
</td>
<td style="text-align:center;width:100px;">
{{getShouBAO(3)}}
......@@ -122,16 +124,15 @@
校代
</td>
<td>
<q-input filled stack-label dense v-model="priceObj.courseObj.SchoolRebateRatio"
ref="SchoolRebateRatio" @keyup.native="checkPrice(priceObj.courseObj, 'SchoolRebateRatio'),getShouBAO(5)"
suffix="%" />
<q-input filled stack-label dense v-model="priceObj.courseObj.SchoolRebateRatio" ref="SchoolRebateRatio"
@keyup.native="checkPrice(priceObj.courseObj, 'SchoolRebateRatio'),getShouBAO(5)" suffix="%" />
</td>
<td style="text-align:center;">
{{getShouBAO(5)}}
</td>
<td>
<q-input filled stack-label dense v-model="priceObj.courseObj.SchoolReNewRatio"
ref="SchoolReNewRatio" @keyup.native="checkPrice(priceObj.courseObj, 'SchoolReNewRatio'),getShouBAO(6)" suffix="%" />
<q-input filled stack-label dense v-model="priceObj.courseObj.SchoolReNewRatio" ref="SchoolReNewRatio"
@keyup.native="checkPrice(priceObj.courseObj, 'SchoolReNewRatio'),getShouBAO(6)" suffix="%" />
</td>
<td style="text-align:center;">
{{getShouBAO(6)}}
......@@ -143,8 +144,8 @@
</td>
<td>
<q-input filled stack-label dense v-model="priceObj.courseObj.TransIntroductceRatio"
ref="TransIntroductceRatio" @keyup.native="checkPrice(priceObj.courseObj, 'TransIntroductceRatio'),getShouBAO(7)"
suffix="%" />
ref="TransIntroductceRatio"
@keyup.native="checkPrice(priceObj.courseObj, 'TransIntroductceRatio'),getShouBAO(7)" suffix="%" />
</td>
<td style="text-align:center">
{{getShouBAO(7)}}
......@@ -164,8 +165,8 @@
</td>
<td>
<q-input filled stack-label dense v-model="priceObj.courseObj.InnerRecommendRatio"
ref="InnerRecommendRatio" @keyup.native="checkPrice(priceObj.courseObj, 'InnerRecommendRatio'),getShouBAO(9)"
suffix="%" />
ref="InnerRecommendRatio"
@keyup.native="checkPrice(priceObj.courseObj, 'InnerRecommendRatio'),getShouBAO(9)" suffix="%" />
</td>
<td style="text-align:center">
{{getShouBAO(9)}}
......@@ -359,85 +360,85 @@
}
},
//获取首次报名优惠
getPrePrice(type){
getPrePrice(type) {
//首次优惠
var Count = ''
if(type==1){
if(this.priceObj.courseObj.B2CRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 1) {
if (this.priceObj.courseObj.B2CRatio) {
let num = Number(100 - this.priceObj.courseObj.B2CRatio) / 100;
Count = (num * this.priceObj.courseObj.SellPrice).toFixed(2);
}
}
if(type==2){
if(this.priceObj.courseObj.B2CReNewRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CReNewRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 2) {
if (this.priceObj.courseObj.B2CReNewRatio) {
let num = Number(100 - this.priceObj.courseObj.B2CReNewRatio) / 100;
Count = (num * this.priceObj.courseObj.SellPrice).toFixed(2);
}
}
return Count;
},
//获取首报返佣比例
getShouBAO(type){
getShouBAO(type) {
//首次优惠
var Count = ''
if(type==3){
if(this.priceObj.courseObj.B2BRebateRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CRatio-this.priceObj.courseObj.B2BRebateRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
var currentPrice = Number(100 - this.priceObj.courseObj.B2CRatio) * this.priceObj.courseObj.SellPrice/100;
if (type == 3) {
if (this.priceObj.courseObj.B2BRebateRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.B2BRebateRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==4){
if(this.priceObj.courseObj.B2BReNewRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CReNewRatio-this.priceObj.courseObj.B2BReNewRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 4) {
if (this.priceObj.courseObj.B2BReNewRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.B2BReNewRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==5){
if(this.priceObj.courseObj.SchoolRebateRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CRatio-this.priceObj.courseObj.SchoolRebateRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 5) {
if (this.priceObj.courseObj.SchoolRebateRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.SchoolRebateRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==6){
if(this.priceObj.courseObj.SchoolReNewRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CReNewRatio-this.priceObj.courseObj.SchoolReNewRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 6) {
if (this.priceObj.courseObj.SchoolReNewRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.SchoolReNewRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==7){
if(this.priceObj.courseObj.TransIntroductceRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CRatio-this.priceObj.courseObj.TransIntroductceRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 7) {
if (this.priceObj.courseObj.TransIntroductceRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.TransIntroductceRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==8){
if(this.priceObj.courseObj.TransIntroductceReNewRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CReNewRatio-this.priceObj.courseObj.TransIntroductceReNewRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 8) {
if (this.priceObj.courseObj.TransIntroductceReNewRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.TransIntroductceReNewRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==9){
if(this.priceObj.courseObj.InnerRecommendRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CRatio-this.priceObj.courseObj.InnerRecommendRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 9) {
if (this.priceObj.courseObj.InnerRecommendRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.InnerRecommendRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
if(type==10){
if(this.priceObj.courseObj.InnerRecommendReNewRatio){
let num = parseInt(100-this.priceObj.courseObj.B2CReNewRatio-this.priceObj.courseObj.InnerRecommendReNewRatio)/100;
Count = (num*this.priceObj.courseObj.SellPrice).toFixed(2);
if (type == 10) {
if (this.priceObj.courseObj.InnerRecommendReNewRatio) {
let num = currentPrice * Number(100 - this.priceObj.courseObj.InnerRecommendReNewRatio) / 100;
Count = num.toFixed(2);
return Count;
}
}
}
}
};
</script>
\ No newline at end of file
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