|
@@ -38,6 +38,33 @@
|
|
|
<el-option v-for="item in brandList" :key="item._id" :label="item.name" :value="item.name" />
|
|
|
</el-select>
|
|
|
</template>
|
|
|
+ <template #use_type>
|
|
|
+ <el-option v-for="i in useTypeList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #type>
|
|
|
+ <el-option v-for="i in boxTypeList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #structure>
|
|
|
+ <el-option v-for="i in structureList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #emission>
|
|
|
+ <el-option v-for="i in emissionList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #energy>
|
|
|
+ <el-option v-for="i in energyList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #displacement>
|
|
|
+ <el-option v-for="i in displacementList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #set>
|
|
|
+ <el-option v-for="i in setList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #level>
|
|
|
+ <el-option v-for="i in levelList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
+ <template #drive>
|
|
|
+ <el-option v-for="i in driveList" :key="i._id" :label="i.label" :value="i.value"></el-option>
|
|
|
+ </template>
|
|
|
<template #status>
|
|
|
<el-radio v-for="i in statusList" :key="i._id" :label="i.value">{{ i.label }}</el-radio>
|
|
|
</template>
|
|
@@ -80,17 +107,54 @@ const $checkRes = inject('$checkRes') as Function;
|
|
|
const statusList: Ref<any> = ref([]);
|
|
|
const shopList: Ref<any> = ref([]);
|
|
|
const brandList: Ref<any> = ref([]);
|
|
|
+const useTypeList: Ref<any> = ref([]);
|
|
|
+const boxTypeList: Ref<any> = ref([]);
|
|
|
+const structureList: Ref<any> = ref([]);
|
|
|
+const emissionList: Ref<any> = ref([]);
|
|
|
+const energyList: Ref<any> = ref([]);
|
|
|
+const displacementList: Ref<any> = ref([]);
|
|
|
+const setList: Ref<any> = ref([]);
|
|
|
+const levelList: Ref<any> = ref([]);
|
|
|
+const driveList: Ref<any> = ref([]);
|
|
|
|
|
|
const searchOther = async () => {
|
|
|
+ let res: IQueryResult;
|
|
|
// 是否使用
|
|
|
- const statusResult: IQueryResult = await dictDataStore.query({ code: 'isUse' });
|
|
|
- if ($checkRes(statusResult)) statusList.value = statusResult.data;
|
|
|
+ res = await dictDataStore.query({ code: 'isUse', is_use: '0' });
|
|
|
+ if ($checkRes(res)) statusList.value = res.data;
|
|
|
// 店铺信息
|
|
|
- const shopResult: IQueryResult = await shopStore.query({ is_use: '0' });
|
|
|
- if ($checkRes(shopResult)) shopList.value = shopResult.data;
|
|
|
+ res = await shopStore.query({ is_use: '0' });
|
|
|
+ if ($checkRes(res)) shopList.value = res.data;
|
|
|
// 品牌
|
|
|
- const brandResult: IQueryResult = await brandStore.query({ is_use: '0' });
|
|
|
- if ($checkRes(brandResult)) brandList.value = brandResult.data;
|
|
|
+ res = await brandStore.query({ is_use: '0' });
|
|
|
+ if ($checkRes(res)) brandList.value = res.data;
|
|
|
+ // 车辆使用性质
|
|
|
+ res = await dictDataStore.query({ code: 'useType', is_use: '0' });
|
|
|
+ if ($checkRes(res)) useTypeList.value = res.data;
|
|
|
+ // 变速箱
|
|
|
+ res = await dictDataStore.query({ code: 'boxType', is_use: '0' });
|
|
|
+ if ($checkRes(res)) boxTypeList.value = res.data;
|
|
|
+ // 车身结构
|
|
|
+ res = await dictDataStore.query({ code: 'structure', is_use: '0' });
|
|
|
+ if ($checkRes(res)) structureList.value = res.data;
|
|
|
+ // 排放标准
|
|
|
+ res = await dictDataStore.query({ code: 'emission', is_use: '0' });
|
|
|
+ if ($checkRes(res)) emissionList.value = res.data;
|
|
|
+ // 能源类型
|
|
|
+ res = await dictDataStore.query({ code: 'energy', is_use: '0' });
|
|
|
+ if ($checkRes(res)) energyList.value = res.data;
|
|
|
+ // 排量
|
|
|
+ res = await dictDataStore.query({ code: 'displacement', is_use: '0' });
|
|
|
+ if ($checkRes(res)) displacementList.value = res.data;
|
|
|
+ // 座椅
|
|
|
+ res = await dictDataStore.query({ code: 'set', is_use: '0' });
|
|
|
+ if ($checkRes(res)) setList.value = res.data;
|
|
|
+ // 车辆级别
|
|
|
+ res = await dictDataStore.query({ code: 'level', is_use: '0' });
|
|
|
+ if ($checkRes(res)) levelList.value = res.data;
|
|
|
+ // 驱动方式
|
|
|
+ res = await dictDataStore.query({ code: 'drive', is_use: '0' });
|
|
|
+ if ($checkRes(res)) driveList.value = res.data;
|
|
|
};
|
|
|
// #endregion
|
|
|
|
|
@@ -223,17 +287,71 @@ const form: Ref<any> = ref({ file: [] });
|
|
|
const formFieldsForCreate = [
|
|
|
{ label: '店铺', model: 'shop', type: 'select' },
|
|
|
{ label: '品牌', model: 'brand', custom: true },
|
|
|
- { label: '车型', model: 'series' },
|
|
|
{ label: '年份', model: 'year' },
|
|
|
+ { label: '车型', model: 'series' },
|
|
|
{ label: '车款', model: 'style' },
|
|
|
+ { label: '车辆识别VIN', model: 'vin' },
|
|
|
+ { label: '首次上牌时间', model: 'f_time', type: 'date' },
|
|
|
+ { label: '车源地', model: 'place' },
|
|
|
+ { label: '车牌地', model: 'license' },
|
|
|
+ { label: '外观颜色', model: 'out_color' },
|
|
|
+ { label: '内饰颜色', model: 'in_color' },
|
|
|
+ { label: '车辆使用性质', model: 'use_type', type: 'select' },
|
|
|
+ { label: '价格', model: 'price' },
|
|
|
+ { label: '车龄', model: 'age' },
|
|
|
+ { label: '里程', model: 'mileage' },
|
|
|
+ { label: '变速箱', model: 'type', type: 'select' },
|
|
|
+ { label: '车身结构', model: 'structure', type: 'select' },
|
|
|
+ { label: '排放标准', model: 'emission', type: 'select' },
|
|
|
+ { label: '能源类型', model: 'energy', type: 'select' },
|
|
|
+ { label: '排量', model: 'displacement', type: 'select' },
|
|
|
+ { label: '座椅', model: 'set', type: 'select' },
|
|
|
+ { label: '车辆级别', model: 'level', type: 'select' },
|
|
|
+ { label: '驱动方式', model: 'drive', type: 'select' },
|
|
|
+ { label: '油耗', model: 'oil' },
|
|
|
+ { label: '年均保险费', model: 'premium' },
|
|
|
+ { label: '年均保养费', model: 'maintenance' },
|
|
|
+ { label: '百公里加速', model: 'hundred_time' },
|
|
|
+ { label: '轴距', model: 'wheelbase' },
|
|
|
+ { label: '总价', model: 'total_money' },
|
|
|
+ { label: '付款方式', model: 'pay_type' },
|
|
|
+ { label: '首付', model: 'first_pay' },
|
|
|
+ { label: '实付价格', model: 'real_pay' },
|
|
|
{ label: '图片', model: 'file', custom: true }
|
|
|
];
|
|
|
const formFieldsForUpdate = [
|
|
|
{ label: '店铺', model: 'shop', type: 'select' },
|
|
|
{ label: '品牌', model: 'brand', custom: true },
|
|
|
- { label: '车型', model: 'series' },
|
|
|
{ label: '年份', model: 'year' },
|
|
|
+ { label: '车型', model: 'series' },
|
|
|
{ label: '车款', model: 'style' },
|
|
|
+ { label: '车辆识别VIN', model: 'vin' },
|
|
|
+ { label: '首次上牌时间', model: 'f_time', type: 'date' },
|
|
|
+ { label: '车源地', model: 'place' },
|
|
|
+ { label: '车牌地', model: 'license' },
|
|
|
+ { label: '外观颜色', model: 'out_color' },
|
|
|
+ { label: '内饰颜色', model: 'in_color' },
|
|
|
+ { label: '车辆使用性质', model: 'use_type', type: 'select' },
|
|
|
+ { label: '价格', model: 'price' },
|
|
|
+ { label: '车龄', model: 'age' },
|
|
|
+ { label: '里程', model: 'mileage' },
|
|
|
+ { label: '变速箱', model: 'type', type: 'select' },
|
|
|
+ { label: '车身结构', model: 'structure', type: 'select' },
|
|
|
+ { label: '排放标准', model: 'emission', type: 'select' },
|
|
|
+ { label: '能源类型', model: 'energy', type: 'select' },
|
|
|
+ { label: '排量', model: 'displacement', type: 'select' },
|
|
|
+ { label: '座椅', model: 'set', type: 'select' },
|
|
|
+ { label: '车辆级别', model: 'level', type: 'select' },
|
|
|
+ { label: '驱动方式', model: 'drive', type: 'select' },
|
|
|
+ { label: '油耗', model: 'oil' },
|
|
|
+ { label: '年均保险费', model: 'premium' },
|
|
|
+ { label: '年均保养费', model: 'maintenance' },
|
|
|
+ { label: '百公里加速', model: 'hundred_time' },
|
|
|
+ { label: '轴距', model: 'wheelbase' },
|
|
|
+ { label: '总价', model: 'total_money' },
|
|
|
+ { label: '付款方式', model: 'pay_type' },
|
|
|
+ { label: '首付', model: 'first_pay' },
|
|
|
+ { label: '实付价格', model: 'real_pay' },
|
|
|
{ label: '图片', model: 'file', custom: true }
|
|
|
];
|
|
|
// 关闭弹框
|