添加技师新增字段
This commit is contained in:
parent
05fe0b3b32
commit
c0eee3e079
|
@ -121,6 +121,20 @@
|
|||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="technicianType" label="技师类型" width="150">
|
||||
<template slot-scope="scope">
|
||||
<!-- <span>{{ scope.row.technicianType }}</span> -->
|
||||
<span>{{ getVipText(scope.row.technicianType) }}</span>
|
||||
<el-button
|
||||
size="mini"
|
||||
:disabled="!isAuth('userList:updatebl')"
|
||||
style="color: #4f9dec; background: #fff; border: none"
|
||||
@click="xiugaiTecType(scope.row)"
|
||||
>
|
||||
修改</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="artificerImg" label="师傅图片">
|
||||
<template slot-scope="scope">
|
||||
<div
|
||||
|
@ -245,7 +259,26 @@
|
|||
<template slot-scope="scope">
|
||||
<el-switch
|
||||
v-model="scope.row.isHot"
|
||||
@change="changeR(scope.row.isHot, scope.row.artificerId)"
|
||||
@change="changeS(scope.row.isHot, scope.row.artificerId)"
|
||||
:active-value="openValue"
|
||||
:disabled="!isAuth('locality:update')"
|
||||
:inactive-value="closeValue"
|
||||
active-color="#13ce66"
|
||||
inactive-color="#ff4949"
|
||||
>
|
||||
</el-switch>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="isStart"
|
||||
label="是否明星技师"
|
||||
fixed="right"
|
||||
width="80"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-switch
|
||||
v-model="scope.row.isStart"
|
||||
@change="changeR(scope.row.isStart, scope.row.artificerId)"
|
||||
:active-value="openValue"
|
||||
:disabled="!isAuth('locality:update')"
|
||||
:inactive-value="closeValue"
|
||||
|
@ -1724,6 +1757,28 @@
|
|||
<el-button type="primary" @click="StairNoticeTo2()">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!-- 修改技师类型 -->
|
||||
<el-dialog title="技师类型" :visible.sync="tecTypeVisible" center>
|
||||
<div style="margin-bottom: 10px">
|
||||
<span style="width: 200px; display: inline-block; text-align: right"
|
||||
>类型:</span
|
||||
>
|
||||
<el-select v-model="tecTypeValue" style="width:150px;margin-left: 10px;" >
|
||||
<el-option v-for="item in vipTypeList" :key="item.vipNameType" :label="item.vipName" :value="item.vipNameType"></el-option>
|
||||
</el-select>
|
||||
<!-- <el-input
|
||||
style="width: 50%"
|
||||
v-model="tecTypeValue"
|
||||
type="number"
|
||||
:min="0"
|
||||
:controls="false"
|
||||
></el-input> -->
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="tecTypeVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="StairNoticeTo3()">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</el-tabs>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -1962,6 +2017,7 @@ export default {
|
|||
userId1: "",
|
||||
|
||||
classTypeList: [],
|
||||
vipTypeList: [],
|
||||
// 加钟项目
|
||||
dialogFormVisibleJz: false,
|
||||
fwData: [],
|
||||
|
@ -1978,8 +2034,10 @@ export default {
|
|||
tableDataXyf: {},
|
||||
|
||||
dialogFormVisible2: false,
|
||||
tecTypeVisible: false,
|
||||
titleBl: "抽成比例",
|
||||
proportion: "",
|
||||
tecTypeValue: "",
|
||||
phoneT: "",
|
||||
MaterialpackageStatus: false,
|
||||
MaterialpackageList: [],
|
||||
|
@ -4014,12 +4072,52 @@ export default {
|
|||
}
|
||||
});
|
||||
},
|
||||
// 是否明星技师
|
||||
changeR(val, artificerId) {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl("artificer/updateArtificers"),
|
||||
method: "post",
|
||||
// params: this.$http.adornParams({
|
||||
data: this.$http.adornData({
|
||||
artificerId: artificerId,
|
||||
isStart: val,
|
||||
}),
|
||||
}).then(({ data }) => {
|
||||
if (data.code == 0) {
|
||||
this.$message({
|
||||
message: "操作成功",
|
||||
type: "success",
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.InformationSelect();
|
||||
},
|
||||
});
|
||||
} else {
|
||||
this.$message({
|
||||
message: data.msg,
|
||||
type: "warning",
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.InformationSelect();
|
||||
},
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
//修改提成比例
|
||||
xiugai(row) {
|
||||
this.titleBl = "抽成比例";
|
||||
this.proportion = row.rate;
|
||||
this.artificerId = row.artificerId;
|
||||
this.dialogFormVisible2 = true;
|
||||
},
|
||||
//修改技师类型
|
||||
xiugaiTecType(row) {
|
||||
this.titleBl = "技师类型";
|
||||
this.tecTypeValue = row.technicianType;
|
||||
this.artificerId = row.artificerId;
|
||||
this.tecTypeVisible = true;
|
||||
},
|
||||
StairNoticeTo2() {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl("artificer/updateArtificers"),
|
||||
|
@ -4051,6 +4149,38 @@ export default {
|
|||
}
|
||||
});
|
||||
},
|
||||
//修改技师类型
|
||||
StairNoticeTo3() {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl("artificer/updateArtificers"),
|
||||
method: "post",
|
||||
// params: this.$http.adornParams({
|
||||
data: this.$http.adornData({
|
||||
artificerId: this.artificerId,
|
||||
technicianType: this.tecTypeValue,
|
||||
}),
|
||||
}).then(({ data }) => {
|
||||
console.log("data", data);
|
||||
if (data.code == 0) {
|
||||
this.$message({
|
||||
message: "修改成功",
|
||||
type: "success",
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.tecTypeVisible = false;
|
||||
this.InformationSelect();
|
||||
},
|
||||
});
|
||||
} else {
|
||||
this.$message({
|
||||
message: data.msg,
|
||||
type: "warning",
|
||||
duration: 1500,
|
||||
onClose: () => {},
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 取消师傅
|
||||
quxiaoJs(row) {
|
||||
this.$confirm(
|
||||
|
@ -4091,8 +4221,37 @@ export default {
|
|||
});
|
||||
});
|
||||
},
|
||||
getVipText(val){
|
||||
var text = "";
|
||||
var vipTypeList = this.vipTypeList;
|
||||
for(var i=0;i<vipTypeList.length;i++){
|
||||
if(vipTypeList[i].vipNameType == val){
|
||||
text = vipTypeList[i].vipName;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return text;
|
||||
},
|
||||
// 获取vip列表
|
||||
vipSelect() {
|
||||
this.tableDataLoading = true
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('vipDetails/selectVipDetailsListByType'),
|
||||
method: 'get',
|
||||
params: this.$http.adornParams({
|
||||
'page': 1,
|
||||
'limit': 999,
|
||||
'type':'1',
|
||||
})
|
||||
}).then(({
|
||||
data
|
||||
}) => {
|
||||
this.vipTypeList = data.data.list
|
||||
})
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
this.vipSelect();
|
||||
this.InformationSelect();
|
||||
this.homeSelect();
|
||||
this.fwSelect();
|
||||
|
|
Loading…
Reference in New Issue