|
@@ -36,13 +36,28 @@
|
|
|
<el-select
|
|
|
v-model="form.vehicleColor"
|
|
|
placeholder="请选择车牌颜色"
|
|
|
- ></el-select>
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="(item,index) in datavehicleColor"
|
|
|
+ :key="index"
|
|
|
+ :value="index"
|
|
|
+ :label="item"
|
|
|
+ ></el-option>
|
|
|
+
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="车身颜色">
|
|
|
<el-select
|
|
|
v-model="form.vehicleColors"
|
|
|
placeholder="请选择车神颜色"
|
|
|
- ></el-select>
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="(items,indexs) in datavehicleColors"
|
|
|
+ :key="indexs"
|
|
|
+ :value="indexs"
|
|
|
+ :label="items"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="车辆品牌">
|
|
|
<el-input
|
|
@@ -67,7 +82,9 @@ export default {
|
|
|
vehicleColors: '',
|
|
|
vehicleBrand: '',
|
|
|
id: ''
|
|
|
- }
|
|
|
+ },
|
|
|
+ datavehicleColor: [],
|
|
|
+ datavehicleColors: []
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
@@ -77,18 +94,31 @@ export default {
|
|
|
|
|
|
this.$emit('close');
|
|
|
},
|
|
|
- // 车牌颜色
|
|
|
- vehiColor () {
|
|
|
- debugger
|
|
|
- this.$http
|
|
|
- .get('/sc-user-center/dict/selectListByPCodes', { parentDictCodes: 'CAR_NO_COLOR' })
|
|
|
- .then(({ data, msg, status }) => {
|
|
|
- console.log('data', data);
|
|
|
- })
|
|
|
- .catch(() => { });
|
|
|
+ // 车牌颜色 CAR_NO_COLOR
|
|
|
+ async vehiColor () {
|
|
|
+ var datavehicleColors = {};
|
|
|
+
|
|
|
+ datavehicleColors = await this.$http.get('/sc-user-center/dict/selectListByPCodes', { parentDictCodes: 'LICENSE_PLATE' });
|
|
|
+ // console.log(datavehicleColor.length)
|
|
|
+ for (var k in datavehicleColors) {
|
|
|
+ this.datavehicleColors.push(datavehicleColors[k])
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
},
|
|
|
// 车身颜色
|
|
|
// LICENSE_PLATE
|
|
|
+ async vehiColors () {
|
|
|
+ var datavehicleColor = {};
|
|
|
+
|
|
|
+ datavehicleColor = await this.$http.get('/sc-user-center/dict/selectListByPCodes', { parentDictCodes: 'CAR_NO_COLOR' });
|
|
|
+ // console.log(datavehicleColor.length)
|
|
|
+ for (var k in datavehicleColor) {
|
|
|
+ this.datavehicleColor.push(datavehicleColor[k])
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ },
|
|
|
},
|
|
|
created () {
|
|
|
this.form.vehicleType = this.params.form[this.params.id].vehicleType;
|
|
@@ -98,6 +128,7 @@ export default {
|
|
|
this.form.id = this.params.id;
|
|
|
|
|
|
this.vehiColor();
|
|
|
+ this.vehiColors();
|
|
|
}
|
|
|
}
|
|
|
</script>
|