feat(jxpz): 奖衔配置分红考核字段可配置
This commit is contained in:
parent
101296b269
commit
c44cca9243
|
@ -2,36 +2,38 @@
|
|||
<div class="page">
|
||||
<topBar
|
||||
v-if="topList.length > 0"
|
||||
:topList="topList"
|
||||
:top-list="topList"
|
||||
:moren="moren"
|
||||
></topBar>
|
||||
/>
|
||||
<div class="main">
|
||||
<div class="maintop">
|
||||
<div class="mainbtn">
|
||||
<el-button size="small" class="thebtn1" @click="adddate()"
|
||||
>{{'添加'}}</el-button
|
||||
>
|
||||
<el-button
|
||||
size="small"
|
||||
class="thebtn1"
|
||||
@click="adddate()"
|
||||
>{{ '添加' }}</el-button>
|
||||
<el-button size="small" class="thebtn2"> {{ '导出' }}</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="maintable">
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
height="750px"
|
||||
:data="tableData"
|
||||
v-loading="loading"
|
||||
style="width: 100%"
|
||||
:header-cell-style="{ background: '#EEEEEE' }"
|
||||
:row-class-name="tableRowClassName"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="55"> </el-table-column>
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column align="center" prop="" :label="'图片'" width="180">
|
||||
<template slot-scope="scope">
|
||||
<img
|
||||
style="width: 44px; height: 44px"
|
||||
:src="scope.row.image"
|
||||
alt=""
|
||||
/>
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
|
@ -39,8 +41,7 @@
|
|||
prop="awardsName"
|
||||
:label="'真实奖衔'"
|
||||
width="180"
|
||||
>
|
||||
</el-table-column>
|
||||
/>
|
||||
<!-- <el-table-column
|
||||
align="center"
|
||||
prop="awardsValue"
|
||||
|
@ -54,9 +55,9 @@
|
|||
:label="'小区考核开始'+`(${isLocals()})`"
|
||||
width="180"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.communityCheck|numberToCurrency }}
|
||||
</template>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.communityCheck|numberToCurrency }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
|
@ -64,26 +65,24 @@
|
|||
:label="'小区考核结束'+`(${isLocals()})`"
|
||||
width="180"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.communityCheckEnd|numberToCurrency }}
|
||||
</template>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.communityCheckEnd|numberToCurrency }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="purchaseCheck"
|
||||
:label="'复购考核'+`(${isLocals()})`"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.purchaseCheck|numberToCurrency }}
|
||||
</template>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.purchaseCheck|numberToCurrency }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="shareCheck"
|
||||
:label="'分红考核'+'(BV)'"
|
||||
>
|
||||
|
||||
</el-table-column>
|
||||
/>
|
||||
<!-- <el-table-column
|
||||
align="center"
|
||||
prop="globalDividend"
|
||||
|
@ -94,20 +93,18 @@
|
|||
align="center"
|
||||
prop="pkCheckAwardsLeftVal"
|
||||
:label="'左区奖衔'"
|
||||
>
|
||||
|
||||
</el-table-column>
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="pkCheckAwardsRightVal"
|
||||
:label="'右区奖衔'"
|
||||
></el-table-column>
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="relationType"
|
||||
:label="'考核'"
|
||||
:formatter="checkRelation"
|
||||
></el-table-column>
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="time"
|
||||
|
@ -116,21 +113,20 @@
|
|||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
@click.native.prevent="update(scope.row, tableData)"
|
||||
type="text"
|
||||
size="small"
|
||||
class="button-s"
|
||||
style="color: #4391FD"
|
||||
@click.native.prevent="update(scope.row, tableData)"
|
||||
>
|
||||
{{'修改'}}
|
||||
修改
|
||||
</el-button>
|
||||
<el-button
|
||||
@click.native.prevent="updateState(scope.row, tableData)"
|
||||
type="text"
|
||||
size="small"
|
||||
class="button-s"
|
||||
style="color: #c73030"
|
||||
|
||||
@click.native.prevent="updateState(scope.row, tableData)"
|
||||
>
|
||||
<!-- 0启用1禁用 -->
|
||||
{{ scope.row.enableState == 1 ? '启用' : '禁用' }}
|
||||
|
@ -159,110 +155,109 @@
|
|||
<el-dialog
|
||||
:title="dialogTitle"
|
||||
:visible.sync="updateShow"
|
||||
width="37%"
|
||||
width="45%"
|
||||
center
|
||||
:close-on-click-modal="false"
|
||||
:before-close="handleClose"
|
||||
>
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="auto">
|
||||
<el-row style="display: flex;justify-content: space-between;" >
|
||||
<el-col :span="11" style="margin-left: -20px">
|
||||
<el-row :gutter="10" style="display: flex;justify-content: space-between;">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="奖衔名称" prop="awardsName">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.awardsName"
|
||||
clearable
|
||||
placeholder=""
|
||||
></el-input>
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="11">
|
||||
<el-form-item :label="'小区考核开始'+`(${isLocals()})`" prop="communityCheck">
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'小区考核开始'+`(${isLocals()})`" prop="communityCheck">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.communityCheck"
|
||||
clearable
|
||||
placeholder=""
|
||||
></el-input>
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row style="display: flex;justify-content: space-between;" >
|
||||
<el-col :span="11" style="margin-left: -20px">
|
||||
<el-row :gutter="10" style="display: flex;justify-content: space-between;">
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'复购考核'+`(${isLocals()})`" prop="purchaseCheck">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.purchaseCheck"
|
||||
clearable
|
||||
placeholder=""
|
||||
></el-input>
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="11">
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'小区考核结束'+`(${isLocals()})`" prop="communityCheckEnd">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.communityCheckEnd"
|
||||
placeholder=""
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row style="display: flex;justify-content: space-between;" >
|
||||
<!-- <el-col :span="11" style="margin-left: -20px">
|
||||
<el-form-item label="全球分红(%)" prop="globalDividend">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.globalDividend"
|
||||
placeholder=""
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col> -->
|
||||
<el-col :span="11" style="margin-left: -20px">
|
||||
<el-form-item :label="'左区奖衔'" prop="pkCheckAwardsLeft">
|
||||
<el-select clearable v-model="form.pkCheckAwardsLeft" placeholder="">
|
||||
<el-option
|
||||
v-for="item in awardsListChiose"
|
||||
:key="item.pkId"
|
||||
:label="item.awardsName"
|
||||
:value="item.pkId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="11" >
|
||||
<el-form-item :label="'右区奖衔'" prop="pkCheckAwardsRight">
|
||||
<el-select clearable v-model="form.pkCheckAwardsRight" placeholder="">
|
||||
<el-option
|
||||
v-for="item in awardsListChiose"
|
||||
:key="item.pkId"
|
||||
:label="item.awardsName"
|
||||
:value="item.pkId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row >
|
||||
|
||||
<el-col :span="11">
|
||||
<el-row :gutter="10" style="">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="分红考核(BV)" prop="shareCheck">
|
||||
<el-input
|
||||
v-model="form.shareCheck"
|
||||
clearable
|
||||
placeholder=""
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'左区奖衔'" prop="pkCheckAwardsLeft">
|
||||
<el-select v-model="form.pkCheckAwardsLeft" clearable placeholder="">
|
||||
<el-option
|
||||
v-for="item in awardsListChiose"
|
||||
:key="item.pkId"
|
||||
:label="item.awardsName"
|
||||
:value="item.pkId"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'右区奖衔'" prop="pkCheckAwardsRight">
|
||||
<el-select v-model="form.pkCheckAwardsRight" clearable placeholder="">
|
||||
<el-option
|
||||
v-for="item in awardsListChiose"
|
||||
:key="item.pkId"
|
||||
:label="item.awardsName"
|
||||
:value="item.pkId"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item :label="'考核'" prop="relationType">
|
||||
<el-select clearable v-model="form.relationType" placeholder="">
|
||||
<el-select v-model="form.relationType" clearable placeholder="">
|
||||
<el-option
|
||||
v-for="item in relationList"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="11" style="margin-left:30px">
|
||||
</el-row>
|
||||
<el-row :gutter="10">
|
||||
<el-col :span="12">
|
||||
<el-form-item required label="奖衔属性" prop="awardsValue">
|
||||
<el-select clearable v-model="form.awardsValue" placeholder="">
|
||||
<el-select v-model="form.awardsValue" clearable placeholder="">
|
||||
<el-option
|
||||
v-for="item in awardsSxList"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
@ -275,35 +270,34 @@
|
|||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="颜色" prop="color">
|
||||
<el-color-picker v-model="form.color"></el-color-picker>
|
||||
<el-color-picker v-model="form.color" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="11" style="margin-left: -20px">
|
||||
<el-col :span="12" style="margin-left: -20px">
|
||||
<el-form-item label="文字内容" prop="textContent">
|
||||
<el-input
|
||||
clearable
|
||||
v-model="form.textContent"
|
||||
clearable
|
||||
placeholder=""
|
||||
></el-input>
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button class="cancels" @click="handleClose"> {{ '取消' }}</el-button>
|
||||
<el-button class="submit" type="primary" @click="onSubmit('form')">{{'确定'}}</el-button>
|
||||
<el-button class="submit" type="primary" @click="onSubmit('form')">{{ '确定' }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import topBar from "@/components/topBar";
|
||||
import ImageUpload from "@/components/ImageUpload";
|
||||
import topBar from '@/components/topBar'
|
||||
import ImageUpload from '@/components/ImageUpload'
|
||||
import {
|
||||
getAwardsList,
|
||||
getAwardsListChiose,
|
||||
|
@ -314,71 +308,71 @@ import {
|
|||
updateAwards,
|
||||
updateStatusAwards,
|
||||
getAwardsValueList
|
||||
} from "@/api/level";
|
||||
import {isLocals} from "@/utils/numberToCurrency";
|
||||
} from '@/api/level'
|
||||
import { isLocals } from '@/utils/numberToCurrency'
|
||||
export default {
|
||||
name: "Jxpz",
|
||||
name: 'Jxpz',
|
||||
components: {
|
||||
topBar,
|
||||
ImageUpload,
|
||||
ImageUpload
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
moren: "jxpz",
|
||||
moren: 'jxpz',
|
||||
topList: [
|
||||
{
|
||||
name: '等级配置',
|
||||
path: "level",
|
||||
path: 'level'
|
||||
},
|
||||
{
|
||||
name: '奖衔配置',
|
||||
path: "jxpz",
|
||||
path: 'jxpz'
|
||||
},
|
||||
{
|
||||
name: '复购极差',
|
||||
path: "fgjc",
|
||||
path: 'fgjc'
|
||||
},
|
||||
{
|
||||
name: '配送中心',
|
||||
path: "pszx",
|
||||
},
|
||||
path: 'pszx'
|
||||
}
|
||||
],
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 50,
|
||||
pageSize: 50
|
||||
},
|
||||
total: 0,
|
||||
multipleSelection: [],
|
||||
tableData: [],
|
||||
loading:false,
|
||||
loading: false,
|
||||
updateShow: false,
|
||||
awardsListChiose: [], //奖衔选择列表
|
||||
relationList: [], //考核选择列表
|
||||
awardsListChiose: [], // 奖衔选择列表
|
||||
relationList: [], // 考核选择列表
|
||||
form: {
|
||||
awardsName: "", //奖衔名称
|
||||
communityCheck: "", //小区考核
|
||||
purchaseCheck: "", //复购考核
|
||||
communityCheckEnd: "", //分红考核
|
||||
awardsName: '', // 奖衔名称
|
||||
communityCheck: '', // 小区考核
|
||||
purchaseCheck: '', // 复购考核
|
||||
communityCheckEnd: '', // 分红考核
|
||||
// globalDividend: "", //全球分红
|
||||
pkCheckAwardsLeft: "", //左区奖衔
|
||||
pkCheckAwardsRight: "", //右区奖衔
|
||||
relationType: "", //考核
|
||||
awardsValue:"",//奖衔属性
|
||||
color:"",
|
||||
image:"",
|
||||
textContent:""
|
||||
pkCheckAwardsLeft: '', // 左区奖衔
|
||||
pkCheckAwardsRight: '', // 右区奖衔
|
||||
relationType: '', // 考核
|
||||
awardsValue: '', // 奖衔属性
|
||||
color: '',
|
||||
image: '',
|
||||
textContent: ''
|
||||
},
|
||||
rules: {
|
||||
awardsName: [
|
||||
{ required: true, message: "请输入奖衔名称", trigger: "blur" },
|
||||
{ required: true, message: '请输入奖衔名称', trigger: 'blur' }
|
||||
],
|
||||
communityCheck: [
|
||||
{ required: true, message: "请输入", trigger: "blur" },
|
||||
{ required: true, message: '请输入', trigger: 'blur' }
|
||||
],
|
||||
purchaseCheck: [
|
||||
{ required: true, message: "请输入PV", trigger: "blur" },
|
||||
{ required: true, message: '请输入PV', trigger: 'blur' }
|
||||
],
|
||||
communityCheckEnd: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||
communityCheckEnd: [{ required: true, message: '请输入', trigger: 'blur' }],
|
||||
// globalDividend: [
|
||||
// { required: true, message: "请输入全球分红", trigger: "blur" },
|
||||
// ],
|
||||
|
@ -392,198 +386,197 @@ export default {
|
|||
// { required: true, message: "请选择考核", trigger: "change" },
|
||||
// ],
|
||||
color: [
|
||||
{ required: true, message: "请选择颜色", trigger: "change" },
|
||||
],
|
||||
{ required: true, message: '请选择颜色', trigger: 'change' }
|
||||
]
|
||||
// image: [
|
||||
// { required: true, message: "请选择图片", trigger: "change" },
|
||||
// ],
|
||||
},
|
||||
dialogTitle: "",
|
||||
addEdit: "",
|
||||
awardsSxList:[],//奖衔属性
|
||||
};
|
||||
dialogTitle: '',
|
||||
addEdit: '',
|
||||
awardsSxList: []// 奖衔属性
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getAwardsList();
|
||||
this.getAwardsListChiose();
|
||||
this.getRelationList();
|
||||
this.getAwardsList()
|
||||
this.getAwardsListChiose()
|
||||
this.getRelationList()
|
||||
this.getAwardsValueList()
|
||||
},
|
||||
methods: {
|
||||
isLocals,
|
||||
//奖衔属性
|
||||
getAwardsValueList(){
|
||||
getAwardsValueList().then(res=>{
|
||||
// 奖衔属性
|
||||
getAwardsValueList() {
|
||||
getAwardsValueList().then(res => {
|
||||
this.awardsSxList = res.data
|
||||
})
|
||||
},
|
||||
|
||||
//启用/禁用
|
||||
updateState(row) {
|
||||
// 启用/禁用
|
||||
updateState(row) {
|
||||
this.$confirm('确认更改状态?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: "warning",
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
var thestate = "";
|
||||
var thestate = ''
|
||||
if (row.enableState == 0) {
|
||||
thestate = 1;
|
||||
thestate = 1
|
||||
} else if (row.enableState == 1) {
|
||||
thestate = 0;
|
||||
thestate = 0
|
||||
}
|
||||
updateStatusAwards({pkId:row.pkId, enableState:thestate}).then((res) => {
|
||||
updateStatusAwards({ pkId: row.pkId, enableState: thestate }).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success",
|
||||
});
|
||||
type: 'success'
|
||||
})
|
||||
// 获取列表
|
||||
this.getAwardsList();
|
||||
this.getAwardsList()
|
||||
}
|
||||
|
||||
});
|
||||
});
|
||||
})
|
||||
})
|
||||
},
|
||||
onSubmit(formName) {
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
let url = "";
|
||||
let url = ''
|
||||
if (this.addEdit == 1) {
|
||||
//添加
|
||||
url = scGenerate;
|
||||
// 添加
|
||||
url = scGenerate
|
||||
} else {
|
||||
//修改
|
||||
url = updateAwards;
|
||||
// 修改
|
||||
url = updateAwards
|
||||
}
|
||||
//修改
|
||||
// 修改
|
||||
url(this.form).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.updateShow = false;
|
||||
this.updateShow = false
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success",
|
||||
});
|
||||
this.getAwardsList();
|
||||
this.addEdit = "";
|
||||
type: 'success'
|
||||
})
|
||||
this.getAwardsList()
|
||||
this.addEdit = ''
|
||||
}
|
||||
});
|
||||
})
|
||||
} else {
|
||||
return false;
|
||||
return false
|
||||
}
|
||||
});
|
||||
})
|
||||
},
|
||||
//点击添加
|
||||
// 点击添加
|
||||
adddate() {
|
||||
this.dialogTitle = '添加';
|
||||
this.updateShow = true;
|
||||
this.addEdit = 1;
|
||||
this.$refs["form"].clearValidate();
|
||||
this.$refs["form"].resetFields();
|
||||
this.dialogTitle = '添加'
|
||||
this.updateShow = true
|
||||
this.addEdit = 1
|
||||
this.$refs['form'].clearValidate()
|
||||
this.$refs['form'].resetFields()
|
||||
// scGenerate({}).then(res=>{
|
||||
// if(res.code==200){
|
||||
// this.getAwardsList()
|
||||
// }
|
||||
// })
|
||||
},
|
||||
//修改
|
||||
// 修改
|
||||
update(row, item) {
|
||||
this.addEdit = 2;
|
||||
this.updateShow = true;
|
||||
this.dialogTitle = '修改';
|
||||
this.addEdit = 2
|
||||
this.updateShow = true
|
||||
this.dialogTitle = '修改'
|
||||
getOneAwards(row.pkId).then((res) => {
|
||||
this.form = res.data;
|
||||
});
|
||||
this.form = res.data
|
||||
})
|
||||
},
|
||||
getAwardsListChiose() {
|
||||
//奖衔配置下拉选
|
||||
// 奖衔配置下拉选
|
||||
getAwardsListChiose().then((res) => {
|
||||
this.awardsListChiose = res.rows;
|
||||
});
|
||||
this.awardsListChiose = res.rows
|
||||
})
|
||||
},
|
||||
//奖衔列表
|
||||
// 奖衔列表
|
||||
getAwardsList() {
|
||||
this.loading = true
|
||||
getAwardsList(this.queryParams).then((res) => {
|
||||
this.tableData = res.rows;
|
||||
this.total = res.total;
|
||||
this.tableData = res.rows
|
||||
this.total = res.total
|
||||
this.loading = false
|
||||
});
|
||||
})
|
||||
},
|
||||
//关闭弹窗
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.updateShow = false;
|
||||
this.$refs["form"].clearValidate();
|
||||
this.$refs["form"].resetFields();
|
||||
this.updateShow = false
|
||||
this.$refs['form'].clearValidate()
|
||||
this.$refs['form'].resetFields()
|
||||
},
|
||||
//考核类型枚举列表下拉
|
||||
// 考核类型枚举列表下拉
|
||||
getRelationList() {
|
||||
getRelationList().then((res) => {
|
||||
this.relationList = res.data;
|
||||
});
|
||||
this.relationList = res.data
|
||||
})
|
||||
},
|
||||
//列表展示考核
|
||||
// 列表展示考核
|
||||
checkRelation(row) {
|
||||
let kaohe = "";
|
||||
let kaohe = ''
|
||||
if (this.relationList) {
|
||||
this.relationList.map((item) => {
|
||||
if (row.relationType == item.value) {
|
||||
kaohe = item.label;
|
||||
kaohe = item.label
|
||||
}
|
||||
});
|
||||
})
|
||||
}
|
||||
return kaohe;
|
||||
return kaohe
|
||||
},
|
||||
//列表展示左右区奖衔
|
||||
// 列表展示左右区奖衔
|
||||
checkAwards(row) {
|
||||
let state = "";
|
||||
let state = ''
|
||||
if (this.awardsListChiose) {
|
||||
this.awardsListChiose.map((element) => {
|
||||
if (row.pkCheckAwardsLeft == element.awardsValue) {
|
||||
state = element.awardsName;
|
||||
state = element.awardsName
|
||||
}
|
||||
});
|
||||
})
|
||||
}
|
||||
return state;
|
||||
return state
|
||||
},
|
||||
checkAwards2(row) {
|
||||
let state2 = "";
|
||||
let state2 = ''
|
||||
if (this.awardsListChiose) {
|
||||
this.awardsListChiose.map((element) => {
|
||||
if (row.pkCheckAwardsRight == element.awardsValue) {
|
||||
state2 = element.awardsName;
|
||||
state2 = element.awardsName
|
||||
}
|
||||
});
|
||||
})
|
||||
}
|
||||
return state2;
|
||||
return state2
|
||||
},
|
||||
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val;
|
||||
this.multipleSelection = val
|
||||
},
|
||||
//删除
|
||||
// 删除
|
||||
deleteRow(row, item) {
|
||||
this.$confirm('确定删除?').then((_) => {
|
||||
deleteAwards(row.pkId).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
type: "success",
|
||||
});
|
||||
this.getAwardsList();
|
||||
type: 'success'
|
||||
})
|
||||
this.getAwardsList()
|
||||
}
|
||||
});
|
||||
});
|
||||
})
|
||||
})
|
||||
},
|
||||
tableRowClassName({ row, rowIndex }) {
|
||||
if (rowIndex % 2 == 1) {
|
||||
return "warning-row";
|
||||
return 'warning-row'
|
||||
} else if (rowIndex % 2 == 0) {
|
||||
return "success-row";
|
||||
return 'success-row'
|
||||
}
|
||||
return "";
|
||||
},
|
||||
},
|
||||
};
|
||||
return ''
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
|
Loading…
Reference in New Issue