Commit 098ab983 authored by lixy's avatar lixy

车型添加优惠状态及优惠价

parent 11c6454f
...@@ -57,16 +57,32 @@ ...@@ -57,16 +57,32 @@
</el-col> </el-col>
</el-row> </el-row>
<!--<el-form-item label="热门车型">-->
<!--<el-radio class="radio" v-model="form.hotSign" label="1"></el-radio>-->
<!--<el-radio class="radio" v-model="form.hotSign" label="0"></el-radio>-->
<!--</el-form-item>-->
<!--租车优惠状态 0;没有优惠;1;会员折扣;2;固定值--> <!--租车优惠状态 0;没有优惠;1;会员折扣;2;固定值-->
<!--<el-form-item label="优惠状态">--> <el-form-item label="优惠状态">
<!--<el-radio class="radio" v-model="form.rentDiscountStatus" label="0">没有优惠</el-radio>--> <el-radio-group v-model="form.rentDiscountStatus">
<!--<el-radio class="radio" v-model="form.rentDiscountStatus" label="1">会员折扣</el-radio>--> <el-radio class="radio" label="0">没有优惠</el-radio>
<!--<el-radio class="radio" v-model="form.rentDiscountStatus" label="2">固定值</el-radio>--> <el-radio class="radio" label="1">会员折扣</el-radio>
<!--</el-form-item>--> <el-radio class="radio" label="2">固定值</el-radio>
</el-radio-group>
</el-form-item>
<el-row v-if="form.rentDiscountStatus==2">
<el-col :span="4">
<el-form-item label="普通会员">
<el-input v-model="form.pPrice" type="number" min="0" placeholder="请输入普通会员价格"></el-input>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label="黄金会员">
<el-input v-model="form.hPrice" type="number" min="0" placeholder="请输入黄金会员价格"></el-input>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label="钻石会员">
<el-input v-model="form.zPrice" type="number" min="0" placeholder="请输入钻石会员价格"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item label="房车配置"></el-form-item> <el-form-item label="房车配置"></el-form-item>
<el-row> <el-row>
...@@ -218,6 +234,9 @@ ...@@ -218,6 +234,9 @@
labelList:[],//全部车型标签 labelList:[],//全部车型标签
fileList2:[], fileList2:[],
form: { form: {
pPrice:0,//普通会员
hPrice:0,//黄金会员
zPrice:0,//钻石会员
name: undefined,//房车名称 name: undefined,//房车名称
config: "",//房车配置 config: "",//房车配置
keyword: "",//房车关键标签 keyword: "",//房车关键标签
...@@ -229,7 +248,7 @@ ...@@ -229,7 +248,7 @@
vioDeposit: 0,//违章押金 vioDeposit: 0,//违章押金
hotSign: "2",//热门车型 1、热门 2、非热门 hotSign: "2",//热门车型 1、热门 2、非热门
rentDiscountStatus:"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值 rentDiscountStatus:"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
RentDiscountPrice: 0,//租车优惠价格 固定优化价格 rentDiscountPrice: 0,//租车优惠价格 固定优化价格
buyPrice: 0,//购买价格 buyPrice: 0,//购买价格
}, },
showDestinationVisible: false,//编辑目的地 showDestinationVisible: false,//编辑目的地
...@@ -385,8 +404,8 @@ ...@@ -385,8 +404,8 @@
deposit: this.form.deposit,//总押金 deposit: this.form.deposit,//总押金
vioDeposit: this.form.vioDeposit, vioDeposit: this.form.vioDeposit,
hotSign: this.form.hotSign,//热门车型 hotSign: this.form.hotSign,//热门车型
// "rentDiscountStatus":"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值 rentDiscountStatus: this.form.rentDiscountStatus,//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
// "RentDiscountPrice":"",//租车优惠价格 固定优化价格 rentDiscountPrice:this.form.pPrice+","+this.form.hPrice+","+this.form.zPrice,//租车优惠价格 固定优化价格
buyPrice: this.form.buyPrice,//购买价格 buyPrice: this.form.buyPrice,//购买价格
}; };
console.log(params); console.log(params);
...@@ -428,8 +447,8 @@ ...@@ -428,8 +447,8 @@
deposit: this.form.deposit,//总押金 deposit: this.form.deposit,//总押金
vioDeposit: this.form.vioDeposit, vioDeposit: this.form.vioDeposit,
hotSign: this.form.hotSign,//热门车型 hotSign: this.form.hotSign,//热门车型
// "rentDiscountStatus":"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值 rentDiscountStatus: this.form.rentDiscountStatus,//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
// "RentDiscountPrice":"",//租车优惠价格 固定优化价格 rentDiscountPrice:this.form.pPrice+","+this.form.hPrice+","+this.form.zPrice,//租车优惠价格 固定优化价格
buyPrice: this.form.buyPrice,//购买价格 buyPrice: this.form.buyPrice,//购买价格
}; };
console.log(params); console.log(params);
...@@ -622,6 +641,14 @@ ...@@ -622,6 +641,14 @@
fileList2.push(p); fileList2.push(p);
}); });
this.fileList2 = fileList2; this.fileList2 = fileList2;
let yhPrice = item.rentDiscountPrice?item.rentDiscountPrice.split(","):[];
if(item.rentDiscountPrice) {
item.pPrice = yhPrice.length>=1?parseInt(yhPrice[0]):0;
item.hPrice = yhPrice.length>=2?parseInt(yhPrice[1]):0;
item.zPrice = yhPrice.length>=3?parseInt(yhPrice[2]):0;
}
item.rentDiscountStatus = item.rentDiscountStatus+"";
item.hotSign = item.hotSign+"";
item.brand = item.brand*1; item.brand = item.brand*1;
item.number = item.number*1; item.number = item.number*1;
item.modelParam = JSON.parse(item.modelParam); item.modelParam = JSON.parse(item.modelParam);
...@@ -744,7 +771,7 @@ ...@@ -744,7 +771,7 @@
vioDeposit: 0,//违章押金 vioDeposit: 0,//违章押金
hotSign: "2",//热门车型 1、热门 2、非热门 hotSign: "2",//热门车型 1、热门 2、非热门
rentDiscountStatus:"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值 rentDiscountStatus:"0",//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
RentDiscountPrice: 0,//租车优惠价格 固定优化价格 rentDiscountPrice: "",//租车优惠价格 固定优化价格
buyPrice: 0,//购买价格 buyPrice: 0,//购买价格
} }
} }
......
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