出行配置,套餐加等级

This commit is contained in:
曹磊 2024-07-16 09:46:48 +08:00
parent 9b38be4697
commit 835a1615ce
2 changed files with 69 additions and 17 deletions

View File

@ -30,13 +30,25 @@
</el-select>&nbsp;&nbsp; </el-select>&nbsp;&nbsp;
</div> </div>
<div style="position: relative; display: inline-block"> <div style="position: relative; display: inline-block">
<span>城市</span> <span>状态</span>
<el-input <el-select
style="width: 200px" clearable
placeholder="请输入城市" v-model="status"
v-model="city" style="width: 150px; margin-left: 10px">
> <el-option value="1" label="上线"></el-option>
</el-input> <el-option value="2" label="下线"></el-option>
</el-select>&nbsp;&nbsp;
</div>
<div style="position: relative; display: inline-block">
<span>等级</span>
<el-select
clearable
v-model="level"
style="width: 150px; margin-left: 10px">
<el-option value="3" label="新手"></el-option>
<el-option value="4" label="专家"></el-option>
<el-option value="5" label="资深"></el-option>
</el-select>&nbsp;&nbsp;
</div> </div>
<div style="position: relative; display: inline-block"> <div style="position: relative; display: inline-block">
<span>项目名称</span> <span>项目名称</span>
@ -47,14 +59,13 @@
</el-input> </el-input>
</div> </div>
<div style="position: relative; display: inline-block"> <div style="position: relative; display: inline-block">
<span>状态</span> <span>城市</span>
<el-select <el-input
clearable style="width: 200px"
v-model="status" placeholder="请输入城市"
style="width: 150px; margin-left: 10px"> v-model="city"
<el-option value="1" label="上线"></el-option> >
<el-option value="2" label="下线"></el-option> </el-input>
</el-select>&nbsp;&nbsp;
</div> </div>
<el-button <el-button
style="margin: 10px" style="margin: 10px"
@ -101,6 +112,11 @@
{{ showDictValue(scope.row.classifyId, fwData) }} {{ showDictValue(scope.row.classifyId, fwData) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="等级" fixed="left" prop="level">
<template slot-scope="scope">
{{ showLevelValue(scope.row.level, levelData) }}
</template>
</el-table-column>
<el-table-column <el-table-column
prop="title" prop="title"
label="名称" label="名称"
@ -343,6 +359,21 @@
</el-select </el-select
> >
</div> </div>
<div style="margin-bottom: 10px">
<span style="width: 200px; display: inline-block; text-align: right"
>套餐等级</span
>
<el-select clearable v-model="level" style="width: 50%">
<el-option
v-for="item in levelData"
:key="item.id"
:label="item.value"
:value="item.id"
>
</el-option>
</el-select
>
</div>
<div style="margin-bottom: 10px"> <div style="margin-bottom: 10px">
<span style="width: 200px; display: inline-block; text-align: right" <span style="width: 200px; display: inline-block; text-align: right"
>名称</span >名称</span
@ -1171,6 +1202,7 @@ export default {
tableDataLoading: false, tableDataLoading: false,
tableData: {}, tableData: {},
typeDictData: [], typeDictData: [],
levelData:[{id:3,value:'新手'},{id:4,value:'专家'},{id:5,value:'资深'}],
id: "",// id: "",//
title: "",// title: "",//
type: "",// type: "",//
@ -1188,6 +1220,7 @@ export default {
city: "",// city: "",//
createTime: "",// createTime: "",//
fwxmtype:"",// 104 fwxmtype:"",// 104
level:"",
page: 1, page: 1,
limit: 10, limit: 10,
dialogFormVisibleSales: false, dialogFormVisibleSales: false,
@ -1258,6 +1291,10 @@ export default {
const dictItem = datas.find(item => data === item.id); const dictItem = datas.find(item => data === item.id);
return dictItem ? dictItem.value : ''; return dictItem ? dictItem.value : '';
}, },
showLevelValue(data, datas){
const dictItem = datas.find(item => data === item.id);
return dictItem ? dictItem.value : '';
},
// //
typeDictSelect() { typeDictSelect() {
this.$http({ this.$http({
@ -1297,7 +1334,8 @@ export default {
classifyId: this.classifyId, classifyId: this.classifyId,
city: this.city, city: this.city,
title: this.title, title: this.title,
status: this.status status: this.status,
level: this.level,
}), }),
}).then(({data}) => { }).then(({data}) => {
if (data.code == 0) { if (data.code == 0) {
@ -1327,6 +1365,7 @@ export default {
this.city = ""; this.city = "";
this.title = ""; this.title = "";
this.status = ""; this.status = "";
this.level = "";
this.page = 1; this.page = 1;
this.handleSelect(); this.handleSelect();
}, },
@ -1587,6 +1626,7 @@ export default {
this.sales = row.sales; this.sales = row.sales;
this.labels = row.labels; this.labels = row.labels;
this.city = row.city; this.city = row.city;
this.level = row.level;
this.createTime = row.createTime; this.createTime = row.createTime;
if (row.city != "" && row.city != "不限") { if (row.city != "" && row.city != "不限") {
this.city = row.city; this.city = row.city;
@ -1646,6 +1686,15 @@ export default {
}); });
return; return;
} }
if (this.level == "") {
this.$notify({
title: "提示",
duration: 1800,
message: "请设置套餐等级",
type: "warning",
});
return;
}
if (this.title == "") { if (this.title == "") {
this.$notify({ this.$notify({
title: "提示", title: "提示",
@ -1728,6 +1777,7 @@ export default {
sales: this.sales, sales: this.sales,
labels: this.labelsArr.toString(), labels: this.labelsArr.toString(),
city: this.city, city: this.city,
level: this.level,
}), }),
}).then(({data}) => { }).then(({data}) => {
if (data.code == 0) { if (data.code == 0) {
@ -1788,6 +1838,7 @@ export default {
this.labels= "";// this.labels= "";//
this.city= "";// this.city= "";//
this.createTime= "";// this.createTime= "";//
this.level= "";
this.page= 1; this.page= 1;
this.limit= 10; this.limit= 10;
this.dialogFormVisibleSales= false; this.dialogFormVisibleSales= false;
@ -2083,6 +2134,7 @@ export default {
this.storeAddre = "请选择城市"; this.storeAddre = "请选择城市";
this.type = ""; this.type = "";
this.jianjie = ""; this.jianjie = "";
this.level = "";
this.serviceCount = 1; this.serviceCount = 1;
this.intervalDays = 0; this.intervalDays = 0;
this.dialogFormVisibleAddMassage = true; this.dialogFormVisibleAddMassage = true;

View File

@ -36,7 +36,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12" v-if="dataForm.pricingType == 2"> <el-col :span="12">
<el-form-item label="夜间出行费(元)" prop="nightTravelExpenses"> <el-form-item label="夜间出行费(元)" prop="nightTravelExpenses">
<el-input-number v-model="dataForm.nightTravelExpenses" controls-position="right" :precision="2" :min="0" :step="1"/> <el-input-number v-model="dataForm.nightTravelExpenses" controls-position="right" :precision="2" :min="0" :step="1"/>
</el-form-item> </el-form-item>