|
|
@@ -6,88 +6,102 @@ |
|
|
|
@export="exportData($event)" |
|
|
|
:show-export="true" |
|
|
|
/> |
|
|
|
<el-table |
|
|
|
border |
|
|
|
highlight-current-row |
|
|
|
:data="dataList" |
|
|
|
:height="tableHeight" |
|
|
|
v-loading="loading" |
|
|
|
:span-method="arraySpanMethod" |
|
|
|
ref="table" |
|
|
|
> |
|
|
|
<el-table-column |
|
|
|
type="index" |
|
|
|
width="50" |
|
|
|
align="center" |
|
|
|
label="序号" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="产业链名称" |
|
|
|
align="center" |
|
|
|
min-width="200" |
|
|
|
prop="name" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="类型" |
|
|
|
align="center" |
|
|
|
min-width="200" |
|
|
|
prop="industryType" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="指标名称" |
|
|
|
align="center" |
|
|
|
min-width="200" |
|
|
|
prop="content" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="分值" |
|
|
|
align="center" |
|
|
|
width="100" |
|
|
|
prop="points" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="第一牵头部门" |
|
|
|
align="center" |
|
|
|
width="180" |
|
|
|
prop="leaderDeptName" |
|
|
|
> |
|
|
|
<template slot-scope="{ row }"> |
|
|
|
<pre>{{ row.leaderDeptList | formatList }}</pre> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="其它牵头部门" |
|
|
|
align="center" |
|
|
|
width="180" |
|
|
|
prop="otherDeptName" |
|
|
|
> |
|
|
|
<template slot-scope="{ row }"> |
|
|
|
<pre>{{ row.otherDeptList | formatList }}</pre> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
label="配合部门" |
|
|
|
align="center" |
|
|
|
width="180" |
|
|
|
prop="cooperateDeptName" |
|
|
|
> |
|
|
|
<template slot-scope="{ row }"> |
|
|
|
<pre>{{ row.cooperateDeptList | formatList }}</pre> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="操作" align="center" width="160"> |
|
|
|
<template slot-scope="{ row }"> |
|
|
|
<el-link |
|
|
|
@click="edit(row)" |
|
|
|
icon="el-icon-edit" |
|
|
|
type="primary" |
|
|
|
:underline="false" |
|
|
|
:disabled="row.isApply || !row.id" |
|
|
|
>申请成为配合部门</el-link |
|
|
|
<div class="table" v-loading="loading"> |
|
|
|
<div class="header"> |
|
|
|
<el-row type="flex"> |
|
|
|
<el-col :span="2" align="center" class="thead td" |
|
|
|
><span class="cell">编号</span></el-col |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<el-col :span="5" align="center" class="thead td" |
|
|
|
><span class="cell">指标名称与全年目标</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="2" align="center" class="thead td" |
|
|
|
><span class="cell">分值</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="2" align="center" class="thead td" |
|
|
|
><span class="cell">得分</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="thead td" |
|
|
|
><span class="cell">第一牵头部门</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="thead td" |
|
|
|
><span class="cell">其他牵头部门</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="thead td" |
|
|
|
><span class="cell">配合部门</span></el-col |
|
|
|
> |
|
|
|
<!-- <el-col :span="3" align="center" class="thead td" |
|
|
|
><span class="cell">打分操作记录</span></el-col |
|
|
|
> --> |
|
|
|
<el-col :span="4" align="center" class="thead td" |
|
|
|
><span class="cell">操作</span></el-col |
|
|
|
> |
|
|
|
</el-row> |
|
|
|
</div> |
|
|
|
<div class="body" :style="{ height: tableHeight + 'px' }" ref="body"> |
|
|
|
<div v-for="(data, index) of dataList" :key="index"> |
|
|
|
<template v-if="isEmpty(data)"> |
|
|
|
<div class="type title">{{ index + 1 }}、{{ data.name }}</div> |
|
|
|
<div v-for="(item, ind) of data.children" :key="ind"> |
|
|
|
<template v-if="item.children.length > 0"> |
|
|
|
<div class="title">{{ item.name }}</div> |
|
|
|
<el-row |
|
|
|
type="flex" |
|
|
|
style="border-left: 1px solid rgb(237, 237, 237)" |
|
|
|
v-for="(detail, i) of item.children" |
|
|
|
:key="i" |
|
|
|
> |
|
|
|
<el-col :span="2" align="center" class="td" |
|
|
|
><span class="cell">{{ i + 1 }}</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="5" align="center" class="td" |
|
|
|
><span class="cell">{{ detail.content }}</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="2" align="center" class="td" |
|
|
|
><span class="cell">{{ detail.points }}</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="2" align="center" class="td" |
|
|
|
><span class="cell">{{ detail.score }}</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="td" |
|
|
|
><span class="cell"> |
|
|
|
<pre>{{ detail.leaderDeptList | formatList }}</pre> |
|
|
|
</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="td" |
|
|
|
><span class="cell"> |
|
|
|
<pre>{{ detail.otherDeptList | formatList }}</pre> |
|
|
|
</span></el-col |
|
|
|
> |
|
|
|
<el-col :span="3" align="center" class="td" |
|
|
|
><span class="cell"> |
|
|
|
<pre>{{ detail.cooperateDeptList | formatList }}</pre> |
|
|
|
</span></el-col |
|
|
|
> |
|
|
|
<!-- <el-col :span="3" align="center" class="td" |
|
|
|
><span class="cell">打分操作记录</span></el-col |
|
|
|
> --> |
|
|
|
<el-col :span="4" align="center" class="td" |
|
|
|
><span class="cell" |
|
|
|
> <el-link |
|
|
|
@click="edit(detail)" |
|
|
|
icon="el-icon-edit" |
|
|
|
type="primary" |
|
|
|
:underline="false" |
|
|
|
:disabled="detail.isApply || !detail.id" |
|
|
|
>申请成为配合部门</el-link |
|
|
|
> |
|
|
|
</el-popconfirm></span |
|
|
|
></el-col |
|
|
|
> |
|
|
|
</el-row> |
|
|
|
</template> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="line"></div> |
|
|
|
</div> |
|
|
|
<!-- <el-pagination |
|
|
|
:current-page.sync="page.page" |
|
|
|
:page-size="page.limit" |
|
|
@@ -98,6 +112,18 @@ |
|
|
|
class="ele-pagination-circle" |
|
|
|
@current-change="getDataList()" |
|
|
|
/> --> |
|
|
|
<!-- <el-table-column label="操作" align="center" width="160"> |
|
|
|
<template slot-scope="{ row }"> |
|
|
|
<el-link |
|
|
|
@click="edit(row)" |
|
|
|
icon="el-icon-edit" |
|
|
|
type="primary" |
|
|
|
:underline="false" |
|
|
|
:disabled="row.isApply || !row.id" |
|
|
|
>申请成为配合部门</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> --> |
|
|
|
<el-dialog |
|
|
|
title="申请成为配合部门" |
|
|
|
:visible.sync="showEdit" |
|
|
@@ -176,6 +202,14 @@ export default { |
|
|
|
this.getDataList(); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
isEmpty(data) { |
|
|
|
for (let item of data.children) { |
|
|
|
if(item.children.length>0){ |
|
|
|
return true |
|
|
|
} |
|
|
|
} |
|
|
|
return false; |
|
|
|
}, |
|
|
|
exportData(data){ |
|
|
|
this.loading=true; |
|
|
|
applyApi.exportList(Object.assign({sheetName:"链长制配合申请列表", isApply: 1},data)).then(res=>{ |
|
|
@@ -221,26 +255,27 @@ export default { |
|
|
|
.then((res) => { |
|
|
|
this.startList = res.data.data; |
|
|
|
let data = res.data.data; |
|
|
|
let list = []; |
|
|
|
let obj = {}; |
|
|
|
let name = ""; |
|
|
|
data.forEach((item, index) => { |
|
|
|
let name = item.name; |
|
|
|
let industryType = ""; |
|
|
|
item.children.forEach((item, $index) => { |
|
|
|
industryType = item.name; |
|
|
|
item.children.forEach((item, $index) => { |
|
|
|
obj = item; |
|
|
|
obj.name = name; |
|
|
|
obj.industryType = industryType; |
|
|
|
list.push(obj); |
|
|
|
}); |
|
|
|
}); |
|
|
|
}); |
|
|
|
list = list.filter((item) => { |
|
|
|
// let list = []; |
|
|
|
// let obj = {}; |
|
|
|
// let name = ""; |
|
|
|
// data.forEach((item, index) => { |
|
|
|
// let name = item.name; |
|
|
|
// let industryType = ""; |
|
|
|
// item.children.forEach((item, $index) => { |
|
|
|
// industryType = item.name; |
|
|
|
// item.children.forEach((item, $index) => { |
|
|
|
// obj = item; |
|
|
|
// obj.name = name; |
|
|
|
// obj.industryType = industryType; |
|
|
|
// list.push(obj); |
|
|
|
// }); |
|
|
|
// }); |
|
|
|
// }); |
|
|
|
data = data.filter((item) => { |
|
|
|
return !this.judge(item); |
|
|
|
}); |
|
|
|
this.dataList = this.reduceData(list); |
|
|
|
// this.dataList = this.reduceData(list); |
|
|
|
this.dataList = data |
|
|
|
}) |
|
|
|
.catch((e) => { |
|
|
|
// this.dataList=[]; |
|
|
@@ -251,6 +286,14 @@ export default { |
|
|
|
}, |
|
|
|
edit(row) { |
|
|
|
this.showEdit = true; |
|
|
|
detail = JSON.parse(JSON.stringify(detail)); |
|
|
|
detail.otherDept = detail.otherDept |
|
|
|
? detail.otherDept.split(",").map((item) => parseInt(item)) |
|
|
|
: []; |
|
|
|
detail.cooperateDept = detail.cooperateDept |
|
|
|
? detail.cooperateDept.split(",").map((item) => parseInt(item)) |
|
|
|
: []; |
|
|
|
this.form = detail; |
|
|
|
this.form.chainIndustryId = row.id; |
|
|
|
this.form.isApply = 2; |
|
|
|
}, |
|
|
@@ -291,5 +334,71 @@ export default { |
|
|
|
}; |
|
|
|
</script> |
|
|
|
|
|
|
|
<style> |
|
|
|
<style scoped> |
|
|
|
.el-row { |
|
|
|
align-items: stretch; |
|
|
|
} |
|
|
|
.header { |
|
|
|
border-top: 1px solid rgb(237, 237, 237); |
|
|
|
border-left: 1px solid rgb(237, 237, 237); |
|
|
|
margin-right: 8px; |
|
|
|
} |
|
|
|
.title { |
|
|
|
padding: 10px; |
|
|
|
font-size: 16px; |
|
|
|
} |
|
|
|
.type { |
|
|
|
font-weight: 700; |
|
|
|
font-size: 17px; |
|
|
|
} |
|
|
|
.td { |
|
|
|
padding: 10px; |
|
|
|
font-size: 14px; |
|
|
|
font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", |
|
|
|
"Microsoft YaHei", "微软雅黑", Arial, sans-serif; |
|
|
|
border-bottom: 1px solid rgb(237, 237, 237); |
|
|
|
border-right: 1px solid rgb(237, 237, 237); |
|
|
|
vertical-align: middle; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
justify-content: center; |
|
|
|
} |
|
|
|
.thead { |
|
|
|
font-weight: 700; |
|
|
|
color: #262626; |
|
|
|
background-color: #fafafa; |
|
|
|
} |
|
|
|
.cell { |
|
|
|
cursor: default; |
|
|
|
} |
|
|
|
.title { |
|
|
|
border-bottom: 1px solid rgb(237, 237, 237); |
|
|
|
border-right: 1px solid rgb(237, 237, 237); |
|
|
|
border-left: 1px solid rgb(237, 237, 237); |
|
|
|
} |
|
|
|
.body { |
|
|
|
overflow-y: scroll; |
|
|
|
overflow-x: hidden; |
|
|
|
position: relative; |
|
|
|
width: calc(100%+16px); |
|
|
|
box-sizing: border-box; |
|
|
|
} |
|
|
|
.body::-webkit-scrollbar { |
|
|
|
position: absolute; |
|
|
|
top: 0; |
|
|
|
right: 0; |
|
|
|
} |
|
|
|
.line { |
|
|
|
height: 1px; |
|
|
|
background: rgb(237, 237, 237); |
|
|
|
margin-top: -1px; |
|
|
|
margin-right: 8px; |
|
|
|
} |
|
|
|
/deep/ .vue-treeselect__multi-value-label, |
|
|
|
/deep/ .vue-treeselect__input { |
|
|
|
line-height: 25px; |
|
|
|
} |
|
|
|
/deep/ .vue-treeselect__multi-value { |
|
|
|
margin-bottom: 0; |
|
|
|
} |
|
|
|
</style> |