布局政策征求意见流程

This commit is contained in:
范强强
2023-10-17 17:27:06 +08:00
parent cb4f422f6f
commit cd4d9c4c8d
6 changed files with 670 additions and 297 deletions
+161 -135
View File
@@ -1,12 +1,13 @@
<template> <template>
<div class="roleTree"> <div class="roleTree">
<el-drawer <el-drawer
:title="isTitle" :title="isTitle"
:visible.sync="visible" v-if="visible"
:wrapperClosable="false" :visible.sync="visible"
@close="handleTreeDrawerCancel" :wrapperClosable="false"
append-to-body @close="handleTreeDrawerCancel"
size="460px"> append-to-body
size="460px">
<el-form <el-form
ref="attributeEO" ref="attributeEO"
class="label-input-form" class="label-input-form"
@@ -15,16 +16,16 @@
> >
<el-form-item class="form-item-disabled" style="margin: 10px;"> <el-form-item class="form-item-disabled" style="margin: 10px;">
<el-input <el-input
v-model="filterText" v-model="filterText"
placeholder="请输入姓名" placeholder="请输入姓名"
@keyup.enter.native="searchChange" @keyup.enter.native="searchChange"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item class="form-item-disabled" style="margin-top: 10px;"> <el-form-item class="form-item-disabled" style="margin-top: 10px;">
<el-button size="medium " type="primary" @click="searchChange"> <el-button size="medium " type="primary" @click="searchChange">
查询 查询
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="divTree"> <div class="divTree">
<!-- 当前tree展示全部人员 --> <!-- 当前tree展示全部人员 -->
@@ -72,7 +73,7 @@
ref="tree" ref="tree"
:lazy="false" :lazy="false"
:key="treeKey" :key="treeKey"
> >
<span class="custom-tree-node" slot-scope="{ node, data }"> <span class="custom-tree-node" slot-scope="{ node, data }">
<span :class="node.disabled ? 'is-show' : 'is-leaf-none'"></span> <span :class="node.disabled ? 'is-show' : 'is-leaf-none'"></span>
<span> {{ node.label }} </span> <span> {{ node.label }} </span>
@@ -90,13 +91,19 @@
closable> closable>
{{tag.name}} {{tag.name}}
</el-tag> </el-tag>
<el-tag v-show="delList.length > 0 && !checkBox" type="danger" closable size="mini" @close="handleCloseAll()">全部删除</el-tag> <el-tag v-show="delList.length > 0 && !checkBox" type="danger" closable size="mini"
@close="handleCloseAll()">全部删除
</el-tag>
</div> </div>
</div> </div>
<div id="roleFormButton" class="demo-drawer-footer"> <div id="roleFormButton" class="demo-drawer-footer">
<el-button class="common-button-primary" size="mini" icon="el-icon-check" type="primary" :loading="subLoading" @click="saveUserInfo">确定</el-button> <el-button class="common-button-primary" size="mini" icon="el-icon-check" type="primary"
:loading="subLoading" @click="saveUserInfo">确定
</el-button>
<el-button class="common-button-default" size="mini" icon="el-icon-close" :loading="subLoading" @click="handleTreeDrawerCancel">取消</el-button> <el-button class="common-button-default" size="mini" icon="el-icon-close" :loading="subLoading"
@click="handleTreeDrawerCancel">取消
</el-button>
</div> </div>
<loading style="z-index: 2099;" :loading="treeLoading">导入中...</loading> <loading style="z-index: 2099;" :loading="treeLoading">导入中...</loading>
</el-drawer> </el-drawer>
@@ -104,15 +111,16 @@
</template> </template>
<script> <script>
function debounce(func, wait = 500){ function debounce(func, wait = 500) {
let timeout; let timeout;
return function(event){ return function (event) {
clearTimeout(timeout) clearTimeout(timeout)
timeout = setTimeout(()=>{ timeout = setTimeout(() => {
func.call(this, event) func.call(this, event)
},wait) }, wait)
} }
} }
export default { export default {
name: "roleTree", name: "roleTree",
props: { props: {
@@ -134,13 +142,13 @@
} }
}, },
type: { type: {
type: Number, type: Number,
default: 0 default: 0
} }
}, },
data () { data() {
return { return {
treeKey:1, treeKey: 1,
defaultKey: [],//默认展开的节点的 key 的数组 defaultKey: [],//默认展开的节点的 key 的数组
visible: false, visible: false,
selectList: [], selectList: [],
@@ -161,13 +169,13 @@
} }
}, },
methods: { methods: {
nameJoinAccount(treeData1){ nameJoinAccount(treeData1) {
treeData1.forEach(item=>{ treeData1.forEach(item => {
if(item.account) item.name = `${item.name}(${item.account})` if (item.account) item.name = `${item.name}(${item.account})`
if(item.children) this.nameJoinAccount(item.children) if (item.children) this.nameJoinAccount(item.children)
}) })
}, },
handleClose (tag) { handleClose(tag) {
let arr = [] let arr = []
for (let a = 0; a < this.delList.length; a++) { for (let a = 0; a < this.delList.length; a++) {
if (tag.id === this.delList[a].id) { if (tag.id === this.delList[a].id) {
@@ -189,7 +197,7 @@
} }
} }
}, },
handleCloseAll () { handleCloseAll() {
this.$msgbox({ this.$msgbox({
title: '提示', title: '提示',
message: '是否删除当前选中人员', message: '是否删除当前选中人员',
@@ -209,41 +217,41 @@
} }
) )
}, },
searchChange(){ searchChange() {
// 查询 // 查询
if (this.filterText.length) { if (this.filterText.length) {
this.open1 = false // 显示第二个tree this.open1 = false // 显示第二个tree
this.treeLoading = true this.treeLoading = true
this.defaultKey = [] this.defaultKey = []
this.$http.get('SarInstitution/institution/getNextTwo', { this.$http.get('SarInstitution/institution/getNextTwo', {
userName: this.filterText userName: this.filterText
}, {}, res => { }, {}, res => {
this.treeData1 = res this.treeData1 = res
this.treeData1.forEach(item => { this.treeData1.forEach(item => {
this.defaultKey.push(item.id) this.defaultKey.push(item.id)
}) })
this.nameJoinAccount(this.treeData1) this.nameJoinAccount(this.treeData1)
this.treeLoading = false this.treeLoading = false
}) })
// this.treeKey++ // this.treeKey++
// this.$http.get('SarInstitution/institution/institutionAndUser', { // this.$http.get('SarInstitution/institution/institutionAndUser', {
// userName: this.filterText // userName: this.filterText
// }, {}, res => { // }, {}, res => {
// this.treeData1 = res.data // this.treeData1 = res.data
// this.treeData1.forEach(item => { // this.treeData1.forEach(item => {
// this.defaultKey.push(item.id) // this.defaultKey.push(item.id)
// }) // })
// console.log(1); // console.log(1);
// this.getChildren() // this.getChildren()
// this.treeLoading = false // this.treeLoading = false
// }) // })
} else { } else {
this.open1 = true this.open1 = true
} }
}, },
changeInput:debounce(function (val) { changeInput: debounce(function (val) {
if (val.length) { if (val.length) {
this.open1 = false this.open1 = false
this.treeLoading = true this.treeLoading = true
@@ -257,28 +265,7 @@
this.open1 = true this.open1 = true
} }
}), }),
checkChange2 (row, type, c) { checkChange2(row, type, c) {
if (this.checkBox) {
} else {
if (type) {
this.nodeList2.push(row.id)
this.delList.push(row)
} else {
for (let a = 0; a < this.nodeList2.length; a ++) {
if (row.id === this.nodeList2[a]) {
this.nodeList2.splice(a, 1)
}
}
for (let b = 0; b < this.delList.length; b++) {
if (row.id === this.delList[b].id) {
this.delList.splice(b, 1)
}
}
}
}
},
checkChange (row, type, c) {
//节点选中状态发生变化时的回调(传递给 data 属性的数组中该节点所对应的对象、节点本身是否被选中、节点的子树中是否有被选中的节点)
if (this.checkBox) { if (this.checkBox) {
} else { } else {
if (type) { if (type) {
@@ -298,14 +285,35 @@
} }
} }
}, },
handleTreeDrawerCancel () { checkChange(row, type, c) {
//节点选中状态发生变化时的回调(传递给 data 属性的数组中该节点所对应的对象、节点本身是否被选中、节点的子树中是否有被选中的节点)
if (this.checkBox) {
} else {
if (type) {
this.nodeList2.push(row.id)
this.delList.push(row)
} else {
for (let a = 0; a < this.nodeList2.length; a++) {
if (row.id === this.nodeList2[a]) {
this.nodeList2.splice(a, 1)
}
}
for (let b = 0; b < this.delList.length; b++) {
if (row.id === this.delList[b].id) {
this.delList.splice(b, 1)
}
}
}
}
},
handleTreeDrawerCancel() {
this.filterText = '' this.filterText = ''
this.open1 = true this.open1 = true
this.visible = false this.visible = false
}, },
saveUserInfo () { saveUserInfo() {
if(this.roleList.length === 0){ if (this.roleList.length === 0) {
this.roleList.push({id:"",name:""}); this.roleList.push({id: "", name: ""});
} }
if (this.checkBox) { if (this.checkBox) {
this.$emit('checkedRole', this.roleList) this.$emit('checkedRole', this.roleList)
@@ -342,9 +350,9 @@
} }
this.open1 = true this.open1 = true
}, },
drawerCheck (data) { drawerCheck(data) {
//当复选框被点击的时候触发 //当复选框被点击的时候触发
//共两个参数,依次为:传递给 data 属性的数组中该节点所对应的对象、树目前的选中状态对象,包含 checkedNodes、checkedKeys、halfCheckedNodes、halfCheckedKeys 四个属性 //共两个参数,依次为:传递给 data 属性的数组中该节点所对应的对象、树目前的选中状态对象,包含 checkedNodes、checkedKeys、halfCheckedNodes、halfCheckedKeys 四个属性
if (this.checkBox) { // 单选 if (this.checkBox) { // 单选
// 单选判断 // 单选判断
let getlist = this.$refs.tree.getCheckedNodes() let getlist = this.$refs.tree.getCheckedNodes()
@@ -361,31 +369,31 @@
this.delList = [data] this.delList = [data]
} }
} else { // 多选 } else { // 多选
if (this.roleList.length === 0) { if (this.roleList.length === 0) {
this.roleList.push(data) this.roleList.push(data)
} else { } else {
let delFlag = true let delFlag = true
this.roleList.forEach((item, index) => { this.roleList.forEach((item, index) => {
if (item.id === data.id) { if (item.id === data.id) {
this.roleList.splice(index, 1) this.roleList.splice(index, 1)
delFlag = false delFlag = false
} }
}) })
if (delFlag) { if (delFlag) {
this.roleList.push(data) this.roleList.push(data)
}
} }
} // this.roleList = this.$refs.tree.getCheckedNodes().concat(this.$refs.tree.getHalfCheckedNodes())
// this.roleList = this.$refs.tree.getCheckedNodes().concat(this.$refs.tree.getHalfCheckedNodes())
} }
}, },
loadNode(node, resolve) { loadNode(node, resolve) {
//加载子树数据的方法,仅当 lazy 属性为true 时生效 //加载子树数据的方法,仅当 lazy 属性为true 时生效
if (node.level === 0) { if (node.level === 0) {
return resolve(this.treeData); return resolve(this.treeData);
} }
this.getChildren(node, resolve) this.getChildren(node, resolve)
}, },
getChildren (node, resolve) { getChildren(node, resolve) {
this.$http.get('SarInstitution/institution/getNext', { this.$http.get('SarInstitution/institution/getNext', {
institutionId: node.key, institutionId: node.key,
userName: this.filterText userName: this.filterText
@@ -393,18 +401,19 @@
resolve(res) resolve(res)
}) })
}, },
getTree () { getTree() {
this.treeLoading = true this.treeLoading = true
this.$http.get('SarInstitution/institution/getFirstInstitution', {}, {}, res=> { this.$http.get('SarInstitution/institution/getFirstInstitution', {}, {}, res => {
this.treeData = res this.treeData = res
this.treeLoading = false this.treeLoading = false
}) })
} }
}, },
watch: { watch: {
isVisible (val) { isVisible(val) {
this.visible = val this.visible = val
if (val) { if (val) {
this.roleList = []
this.nodeList2 = this.nodeList this.nodeList2 = this.nodeList
if (this.nodeList2.length && this.nodeList2[0].length) { if (this.nodeList2.length && this.nodeList2[0].length) {
let ids = '' let ids = ''
@@ -434,7 +443,7 @@
this.$emit('update:isVisible', val) this.$emit('update:isVisible', val)
} }
}, },
mounted () { mounted() {
this.getTree() this.getTree()
} }
} }
@@ -445,12 +454,15 @@
overflow: auto; overflow: auto;
height: calc(~'100% - 300px'); height: calc(~'100% - 300px');
} }
.divDel { .divDel {
border-top: 1px solid #000; border-top: 1px solid #000;
height: 300px; height: 300px;
.divDel_title { .divDel_title {
margin: 10px; margin: 10px;
} }
.divDel_box { .divDel_box {
height: 266px; height: 266px;
padding: 0px 0 10px; padding: 0px 0 10px;
@@ -458,50 +470,59 @@
flex-wrap: wrap; flex-wrap: wrap;
overflow: auto; overflow: auto;
margin: 10px; margin: 10px;
align-content: flex-start; align-content: flex-start;
span { span {
margin: 0px 5px 5px 0; margin: 0px 5px 5px 0;
} }
} }
} }
/deep/ .icon-tree { /deep/ .icon-tree {
margin: 0 5px 0 10px; margin: 0 5px 0 10px;
position: relative; position: relative;
background: url('~@/assets/images/shangqi/img/tree-add.png'); background: url('~@/assets/images/shangqi/img/tree-add.png');
background-size: 100% 100%; background-size: 100% 100%;
} }
/deep/.el-tree-node__content {
/deep/ .el-tree-node__content {
padding-left: 0px !important; padding-left: 0px !important;
} }
/deep/ .is-leaf{
background-image:none; /deep/ .is-leaf {
background-size:100% 100%; background-image: none;
background-size: 100% 100%;
} }
/deep/ .is-leaf-none{
/deep/ .is-leaf-none {
position: relative; position: relative;
display: inline-block; display: inline-block;
width: 15px; width: 15px;
height: 15px; height: 15px;
background:url('~@/assets/images/shangqi/img/personnel.png'); background: url('~@/assets/images/shangqi/img/personnel.png');
background-size:100% 100%; background-size: 100% 100%;
} }
/deep/ .is-show{
/deep/ .is-show {
position: relative; position: relative;
display: inline-block; display: inline-block;
width: 15px; width: 15px;
height: 15px; height: 15px;
background:url('~@/assets/images/shangqi/img/mechanism.png'); background: url('~@/assets/images/shangqi/img/mechanism.png');
background-size:100% 100%; background-size: 100% 100%;
} }
/deep/.tree-line{
/deep/ .tree-line {
.el-tree-node { .el-tree-node {
position: relative; position: relative;
padding-left: 0px; // 缩进量 padding-left: 0px; // 缩进量
line-height: 30px; line-height: 30px;
} }
.el-tree-node__children { .el-tree-node__children {
padding-left: 16px; // 缩进量 padding-left: 16px; // 缩进量
} }
// 竖线 // 竖线
.el-tree-node::before { .el-tree-node::before {
content: ""; content: "";
@@ -513,10 +534,12 @@
border-width: 1px; border-width: 1px;
border-left: 1px dashed #858990e0; border-left: 1px dashed #858990e0;
} }
// 当前层最后一个节点的竖线高度固定 // 当前层最后一个节点的竖线高度固定
.el-tree-node:last-child::before { .el-tree-node:last-child::before {
height: 38px; // 可以自己调节到合适数值 height: 38px; // 可以自己调节到合适数值
} }
// 横线 // 横线
.el-tree-node::after { .el-tree-node::after {
content: ""; content: "";
@@ -528,18 +551,21 @@
border-width: 1px; border-width: 1px;
border-top: 1px dashed #858990e0; border-top: 1px dashed #858990e0;
} }
// 去掉最顶层的虚线,放最下面样式才不会被上面的覆盖了 // 去掉最顶层的虚线,放最下面样式才不会被上面的覆盖了
& > .el-tree-node::after { & > .el-tree-node::after {
border-top: none; border-top: none;
} }
& > .el-tree-node::before { & > .el-tree-node::before {
border-left: none; border-left: none;
} }
// 展开关闭的icon // 展开关闭的icon
.el-tree-node__expand-icon{ .el-tree-node__expand-icon {
font-size: 16px; font-size: 16px;
// 叶子节点(无子节点) // 叶子节点(无子节点)
&.is-leaf{ &.is-leaf {
color: transparent; color: transparent;
// display: none; // 也可以去掉 // display: none; // 也可以去掉
} }
@@ -115,6 +115,15 @@
:loading="submitLoading" :loading="submitLoading"
v-if="showOver2" v-if="showOver2"
>驳回</el-button> >驳回</el-button>
<el-button
type="danger"
size="small"
class="common-button-danger"
icon="el-icon-close"
@click="rejectClick"
:loading="rejectLoading"
v-if="showReject"
>驳回</el-button>
<el-button <el-button
type="primary" type="primary"
size="mini" size="mini"
@@ -351,6 +360,14 @@ export default {
type: Boolean, type: Boolean,
default: false default: false
}, },
rejectLoading:{
type: Boolean,
default: false
},
showReject:{
type: Boolean,
default: false
},
backBTNTexts: { backBTNTexts: {
type: String type: String
}, },
@@ -372,6 +389,9 @@ export default {
} }
}, },
methods: { methods: {
rejectClick(){
this.$emit('reject')
},
handleOver() { handleOver() {
this.$emit('over') this.$emit('over')
}, },
@@ -73,12 +73,16 @@
</el-button> </el-button>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="处理意见" prop="handlingSuggestion" label-width="150px" class="add-form-item"> <el-form-item label="处理意见"
v-if="isHandlingSuggestion"
prop="handlingSuggestion" label-width="150px" class="add-form-item">
<el-input v-model.trim="sarStandardsInfoEO.handlingSuggestion" <el-input v-model.trim="sarStandardsInfoEO.handlingSuggestion"
placeholder="请输入处理意见" placeholder="请输入处理意见"
clearable></el-input> clearable></el-input>
</el-form-item> </el-form-item>
<el-form-item label="原因" prop="reason" label-width="150px" class="add-form-item"> <el-form-item label="原因" prop="reason"
v-if="isHandlingSuggestion"
label-width="150px" class="add-form-item">
<el-input v-model.trim="sarStandardsInfoEO.reason" <el-input v-model.trim="sarStandardsInfoEO.reason"
placeholder="请输入原因" placeholder="请输入原因"
clearable></el-input> clearable></el-input>
@@ -177,8 +181,19 @@
fileName: '', fileName: '',
accept: '', accept: '',
fileMax_M: 0, fileMax_M: 0,
taskKey: this.$route.query.taskKey,
} }
}, },
computed: {
isHandlingSuggestion() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey12') {
return true
}
return false
},
},
methods: { methods: {
handlePreview(file) { handlePreview(file) {
let attId = "" let attId = ""
@@ -23,151 +23,149 @@
<el-timeline-item timestamp="审核" placement="top" <el-timeline-item timestamp="审核" placement="top"
:color="roleForm.responseDockerId ? '#66b1ff' : ''"> :color="roleForm.responseDockerId ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="responseDockerName" style="margin-bottom: 0"> <el-form-item prop="shr1UserNames" style="margin-bottom: 0">
<h4>审核</h4> <h4>审核</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.responseDockerId" <el-input :disabled="disabledXX" v-model="roleForm.shr1UserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.responseDockerName" readonly <el-input :disabled="disabledXX" v-model="roleForm.shr1UserNames" readonly
placeholder="选择审核人" placeholder="选择审核人"
@click.native="choicePeoPle('responseDockerId', '选择审核人', roleForm.responseDockerId,true)"></el-input> @click.native="choicePeoPle('shr1UserIds', '选择审核人', roleForm.shr1UserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="审定" placement="top" <el-timeline-item timestamp="审定" placement="top"
:color="roleForm.lawsProveEngineerId ? '#66b1ff' : ''"> :color="roleForm.sdr1UserIds ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveEngineerName" style="margin-bottom: 0"> <el-form-item prop="sdr1UserNames" style="margin-bottom: 0">
<h4>审定</h4> <h4>审定</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveEngineerId" <el-input :disabled="disabledXX" v-model="roleForm.sdr1UserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveEngineerName" readonly <el-input :disabled="disabledXX" v-model="roleForm.sdr1UserNames" readonly
placeholder="选择审定人" placeholder="选择审定人"
@click.native="choicePeoPle('lawsProveEngineerId', '选择审定人', roleForm.lawsProveEngineerId,true)"></el-input> @click.native="choicePeoPle('sdr1UserIds', '选择审定人', roleForm.sdr1UserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="批准" placement="top" <el-timeline-item timestamp="批准" placement="top"
:color="roleForm.lawsProveMinisterId ? '#66b1ff' : ''"> :color="roleForm.pzr1UserId ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveMinisterName" style="margin-bottom: 0"> <el-form-item prop="pzr1UserName" style="margin-bottom: 0">
<h4>批准</h4> <h4>批准</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveMinisterId" <el-input :disabled="disabledXX" v-model="roleForm.pzr1UserId"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveMinisterName" readonly <el-input :disabled="disabledXX" v-model="roleForm.pzr1UserName" readonly
placeholder="选择批准人" placeholder="选择批准人"
@click.native="choicePeoPle('lawsProveMinisterId', '选择批准人', roleForm.lawsProveMinisterId,false)"></el-input> @click.native="choicePeoPle('pzr1UserId', '选择批准人', roleForm.pzr1UserId,true)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="责任对接人分配任务" placement="top" <el-timeline-item timestamp="责任对接人分配任务" placement="top"
:color="roleForm.lawsProveViceChiefId ? '#66b1ff' : ''"> :color="roleForm.djrUserIds ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveViceChiefName" style="margin-bottom: 0"> <el-form-item prop="djrUserNames" style="margin-bottom: 0">
<h4>责任对接人分配任务</h4> <h4>责任对接人分配任务</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveViceChiefId" <el-input :disabled="disabledXX" v-model="roleForm.djrUserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveViceChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.djrUserNames" readonly
placeholder="责任对接人分配任务" placeholder="责任对接人分配任务"
@click.native="choicePeoPle('lawsProveViceChiefId', '责任对接人分配任务', roleForm.lawsProveViceChiefId,true)"></el-input> @click.native="choicePeoPle('djrUserIds', '责任对接人分配任务', roleForm.djrUserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="管理员" placement="top" <el-timeline-item timestamp="管理员" placement="top"
:color="roleForm.lawsProveChiefId ? '#66b1ff' : ''"> :color="roleForm.glyUserId ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveChiefName" style="margin-bottom: 0"> <el-form-item prop="glyUserName" style="margin-bottom: 0">
<h4>管理员</h4> <h4>管理员</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefId" <el-input :disabled="disabledXX" v-model="roleForm.glyUserId"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.glyUserName" readonly
placeholder="管理员" placeholder="管理员"
@click.native="choicePeoPle('lawsProveChiefId', '管理员', roleForm.lawsProveChiefId,false)"></el-input> @click.native="choicePeoPle('glyUserId', '管理员', roleForm.glyUserId,true)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="审核" placement="top" <el-timeline-item timestamp="审核" placement="top"
:color="roleForm.lawsProveChiefId ? '#66b1ff' : ''"> :color="roleForm.shr2UserIds ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveChiefName" style="margin-bottom: 0"> <el-form-item prop="shr2UserNames" style="margin-bottom: 0">
<h4>审核</h4> <h4>审核</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefId" <el-input :disabled="disabledXX" v-model="roleForm.shr2UserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.shr2UserNames" readonly
placeholder="审核" placeholder="审核"
@click.native="choicePeoPle('lawsProveChiefId', '审核', roleForm.lawsProveChiefId,true)"></el-input> @click.native="choicePeoPle('shr2UserIds', '审核', roleForm.shr2UserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="审定" placement="top" <el-timeline-item timestamp="审定" placement="top"
:color="roleForm.lawsProveChiefId ? '#66b1ff' : ''"> :color="roleForm.sdr2UserIds ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveChiefName" style="margin-bottom: 0"> <el-form-item prop="sdr2UserNames" style="margin-bottom: 0">
<h4>审定</h4> <h4>审定</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefId" <el-input :disabled="disabledXX" v-model="roleForm.sdr2UserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.sdr2UserNames" readonly
placeholder="审定" placeholder="审定"
@click.native="choicePeoPle('lawsProveChiefId', '审定', roleForm.lawsProveChiefId,true)"></el-input> @click.native="choicePeoPle('sdr2UserIds', '审定', roleForm.sdr2UserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="批准" placement="top" <el-timeline-item timestamp="批准" placement="top"
:color="roleForm.lawsProveChiefId ? '#66b1ff' : ''"> :color="roleForm.pzr2UserId ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveChiefName" style="margin-bottom: 0"> <el-form-item prop="pzr2UserName" style="margin-bottom: 0">
<h4>批准</h4> <h4>批准</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefId" <el-input :disabled="disabledXX" v-model="roleForm.pzr2UserId"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.pzr2UserName" readonly
placeholder="批准" placeholder="批准"
@click.native="choicePeoPle('lawsProveChiefId', '批准', roleForm.lawsProveChiefId,false)"></el-input> @click.native="choicePeoPle('pzr2UserId', '批准', roleForm.pzr2UserId,true)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
<el-timeline-item timestamp="抄送" placement="top" <el-timeline-item timestamp="抄送" placement="top"
:color="roleForm.lawsProveChiefId ? '#66b1ff' : ''"> :color="roleForm.csrUserIds ? '#66b1ff' : ''">
<el-card> <el-card>
<el-form-item prop="lawsProveChiefName" style="margin-bottom: 0"> <el-form-item prop="csrUserNames" style="margin-bottom: 0">
<h4>抄送</h4> <h4>抄送</h4>
<div style="margin-top: 10px;width: 300px;"> <div style="margin-top: 10px;width: 300px;">
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefId" <el-input :disabled="disabledXX" v-model="roleForm.csrUserIds"
style="display: none;"></el-input> style="display: none;"></el-input>
<el-input :disabled="disabledXX" v-model="roleForm.lawsProveChiefName" readonly <el-input :disabled="disabledXX" v-model="roleForm.csrUserNames" readonly
placeholder="抄送" placeholder="抄送"
@click.native="choicePeoPle('lawsProveChiefId', '抄送', roleForm.lawsProveChiefId,true)"></el-input> @click.native="choicePeoPle('csrUserIds', '抄送', roleForm.csrUserIds,false)"></el-input>
</div> </div>
</el-form-item> </el-form-item>
</el-card> </el-card>
</el-timeline-item> </el-timeline-item>
</el-form> </el-form>
</el-timeline> </el-timeline>
<Role-tree v-if="!disabledXX" <Role-tree :is-title="drawerTitle"
check-box
:is-title="drawerTitle"
:is-visible.sync="modalshowflag" :is-visible.sync="modalshowflag"
@checkedRole="checkedRole" @checkedRole="checkedRole"
:nodeList="nodeList" :nodeList="nodeList"
@@ -184,23 +182,32 @@
roleForm: {}, roleForm: {},
// 角色验证 // 角色验证
roleFormRules: { roleFormRules: {
responseDockerName: [ shr1UserNames: [
{required: true, message: "请选择责任对接人", trigger: "change"} {required: true, message: "请选择审核人", trigger: "change"}
], ],
responseUserName: [ sdr1UserNames: [
{required: true, message: "请选择责任人", trigger: "change"} {required: true, message: "请选择审定人", trigger: "change"}
], ],
lawsProveEngineerName: [ pzr1UserName: [
{required: true, message: "请选择法规认证工程师", trigger: "change"} {required: true, message: "请选择批准人", trigger: "change"}
], ],
lawsProveMinisterName: [ djrUserNames: [
{required: true, message: "请选择法规认证部部长", trigger: "change"} {required: true, message: "请选择责任对接人分配任务", trigger: "change"}
], ],
lawsProveViceChiefName: [ glyUserName: [
{required: true, message: "请选择法规认证部副总监", trigger: "change"} {required: true, message: "请选择管理员", trigger: "change"}
], ],
lawsProveChiefName: [ shr2UserNames: [
{required: true, message: "请选择法规认证部总监", trigger: "change"} {required: true, message: "请选择审核人", trigger: "change"}
],
sdr2UserNames: [
{required: true, message: "请选择审定人", trigger: "change"}
],
pzr2UserName: [
{required: true, message: "请选择批准人", trigger: "change"}
],
csrUserNames: [
{required: true, message: "请选择抄送人", trigger: "change"}
], ],
}, },
disabledXX: false, disabledXX: false,
@@ -219,32 +226,52 @@
//选择人 //选择人
choicePeoPle(type, title, id, isTrue) { choicePeoPle(type, title, id, isTrue) {
this.nodeList = []; this.nodeList = [];
this.nodeList.push(id); let ids = id ? id.split(',') : []
this.nodeList = ids;
this.type = type; this.type = type;
this.drawerTitle = title; this.drawerTitle = title;
this.checkBox = isTrue this.checkBox = isTrue
console.log(this.nodeList);
this.modalshowflag = true; this.modalshowflag = true;
}, },
//选择人 //选择人
checkedRole(data) { checkedRole(data) {
if (this.type === "responseDockerId") { console.log(data);
this.roleForm.responseDockerId = data[0].id; let ids = []
this.roleForm.responseDockerName = data[0].name; let names = []
} else if (this.type === "responseUserId") { if (data && data.length > 0) {
this.roleForm.responseUserId = data[0].id; for (let i = 0; i < data.length; i++) {
this.roleForm.responseUserName = data[0].name; ids.push(data[i].id)
} else if (this.type === "lawsProveEngineerId") { names.push(data[i].name)
this.roleForm.lawsProveEngineerId = data[0].id; }
this.roleForm.lawsProveEngineerName = data[0].name; }
} else if (this.type === "lawsProveMinisterId") { if (this.type === "shr1UserIds") {
this.roleForm.lawsProveMinisterId = data[0].id; this.roleForm.shr1UserIds = ids.join(',')
this.roleForm.lawsProveMinisterName = data[0].name; this.roleForm.shr1UserNames = names.join(',');
} else if (this.type === "lawsProveViceChiefId") { } else if (this.type === "sdr1UserIds") {
this.roleForm.lawsProveViceChiefId = data[0].id; this.roleForm.sdr1UserIds = ids.join(',');
this.roleForm.lawsProveViceChiefName = data[0].name; this.roleForm.sdr1UserNames = names.join(',');
} else if (this.type === "lawsProveChiefId") { } else if (this.type === "pzr1UserId") {
this.roleForm.lawsProveChiefId = data[0].id; this.roleForm.pzr1UserId = ids.join(',');
this.roleForm.lawsProveChiefName = data[0].name; this.roleForm.pzr1UserName = names.join(',');
} else if (this.type === "djrUserIds") {
this.roleForm.djrUserIds = ids.join(',');
this.roleForm.djrUserNames = names.join(',');
} else if (this.type === "glyUserId") {
this.roleForm.glyUserId = ids.join(',');
this.roleForm.glyUserName = names.join(',');
} else if (this.type === "shr2UserIds") {
this.roleForm.shr2UserIds = ids.join(',');
this.roleForm.shr2UserNames = names.join(',');
} else if (this.type === "sdr2UserIds") {
this.roleForm.sdr2UserIds = ids.join(',');
this.roleForm.sdr2UserNames = names.join(',');
} else if (this.type === "pzr2UserId") {
this.roleForm.pzr2UserId = ids.join(',');
this.roleForm.pzr2UserName = names.join(',');
} else if (this.type === "csrUserIds") {
this.roleForm.csrUserIds = ids.join(',');
this.roleForm.csrUserNames = names.join(',');
} }
this.roleForm = {...this.roleForm} this.roleForm = {...this.roleForm}
this.modalshowflag = false; this.modalshowflag = false;
@@ -8,27 +8,32 @@
type="primary" type="primary"
class="common-button-primary add-button" class="common-button-primary add-button"
@click="addModel" @click="addModel"
v-if="isNodeDisplay"
><i class="el-icon-plus"></i>新增 ><i class="el-icon-plus"></i>新增
</el-button> </el-button>
<el-button <el-button
class="common-button-primary add-button" class="common-button-primary add-button"
@click="batchDeleteModel" @click="batchDeleteModel"
v-if="isNodeDisplay"
><i class="iconfont">&#xe61b;</i>批量删除 ><i class="iconfont">&#xe61b;</i>批量删除
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
v-if="isGenerateSummary"
class="common-button-primary add-button" class="common-button-primary add-button"
@click="generateSummary" @click="generateSummary"
>生成汇总单 >生成汇总单
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
v-if="isGenerateSummary"
class="common-button-primary add-button" class="common-button-primary add-button"
@click="generateReportComments" @click="generateReportComments"
>生成上报意见 >生成上报意见
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
v-if="isExport"
class="common-button-primary add-button" class="common-button-primary add-button"
@click="exportModel" @click="exportModel"
>导出 >导出
@@ -47,6 +52,7 @@
<el-table-column <el-table-column
type="selection" type="selection"
width="55" width="55"
v-if="showSelection"
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@@ -92,25 +98,30 @@
label="附件" label="附件"
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
v-if="isPersonInCharge"
prop="personInCharge" prop="personInCharge"
label="责任人" label="责任人"
show-overflow-tooltip show-overflow-tooltip
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
v-if="isCompleteFlag"
prop="completeFlag" prop="completeFlag"
label="提出部门" label="提出部门"
show-overflow-tooltip show-overflow-tooltip
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
v-if="isCompleteFlag"
prop="proposingDepartment" prop="proposingDepartment"
label="提出人" label="提出人"
show-overflow-tooltip show-overflow-tooltip
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
v-if="isCompleteFlag"
prop="handlingSuggestion" prop="handlingSuggestion"
label="处理意见" label="处理意见"
show-overflow-tooltip show-overflow-tooltip
@@ -119,12 +130,14 @@
<el-table-column <el-table-column
prop="reason" prop="reason"
label="原因" label="原因"
v-if="isCompleteFlag"
show-overflow-tooltip show-overflow-tooltip
align="center"> align="center">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
label="操作" label="操作"
width="70" width="70"
v-if="isOperate"
align="center"> align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div @click.stop style="display: inline-block"> <div @click.stop style="display: inline-block">
@@ -162,18 +175,75 @@
addOrEdit: 'add', addOrEdit: 'add',
editNum: 0, editNum: 0,
selectList: [], selectList: [],
taskKey: this.$route.query.taskKey,
} }
}, },
computed: {
isNodeDisplay() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey8' ||
this.taskKey == 'PolicySolicitOpinionProcessKey9') {
return true
}
return false
},
isGenerateSummary() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey13' ||
this.taskKey == 'PolicySolicitOpinionProcessKey14' ||
this.taskKey == 'PolicySolicitOpinionProcessKey15') {
return true
}
return false
},
isExport() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey12') {
return true
}
return false
},
isPersonInCharge() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey9' ||
this.taskKey == 'PolicySolicitOpinionProcessKey10' ||
this.taskKey == 'PolicySolicitOpinionProcessKey11') {
return true
}
return false
},
isCompleteFlag() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey12' ||
this.taskKey == 'PolicySolicitOpinionProcessKey13' ||
this.taskKey == 'PolicySolicitOpinionProcessKey14' ||
this.taskKey == 'PolicySolicitOpinionProcessKey15' ||
this.taskKey == 'PolicySolicitOpinionProcessKey16') {
return true
}
return false
},
isOperate() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey8' ||
this.taskKey == 'PolicySolicitOpinionProcessKey9' ||
this.taskKey == 'PolicySolicitOpinionProcessKey12') {
return true
}
return false
},
showSelection() {
if (this.taskKey == 'PolicySolicitOpinionProcessKey8' ||
this.taskKey == 'PolicySolicitOpinionProcessKey9') {
return true
}
return false
},
},
mounted() { mounted() {
}, },
methods: { methods: {
generateSummary(){ generateSummary() {
}, },
generateReportComments(){ generateReportComments() {
}, },
exportModel(){ exportModel() {
}, },
addModel() { addModel() {
@@ -6,8 +6,12 @@
</ProcessHeader> </ProcessHeader>
<div class="headerTabs"> <div class="headerTabs">
<div class="headerTabsItem" :class="active === '1' ? 'active' : ''" @click="handleTabs('1')">基础信息</div> <div class="headerTabsItem" :class="active === '1' ? 'active' : ''" @click="handleTabs('1')">基础信息</div>
<div class="headerTabsItem" :class="active === '2' ? 'active' : ''" @click="handleTabs('2')">人员信息</div> <div class="headerTabsItem" v-if="showPersonnel" :class="active === '2' ? 'active' : ''"
<div class="headerTabsItem" :class="active === '3' ? 'active' : ''" @click="handleTabs('3')">审批历史</div> @click="handleTabs('2')">人员信息
</div>
<div class="headerTabsItem" v-if="showApprovalHistory"
:class="active === '3' ? 'active' : ''" @click="handleTabs('3')">审批历史
</div>
</div> </div>
<div class="content" v-show="active === '1'"> <div class="content" v-show="active === '1'">
<div style="flex: auto; overflow: auto;"> <div style="flex: auto; overflow: auto;">
@@ -24,14 +28,16 @@
<div class="prc-content-border"> <div class="prc-content-border">
<el-row :gutter="24"> <el-row :gutter="24">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="政策编号" prop="lawsNumber" class="add-form-item form-item-disabled"> <el-form-item label="政策编号"
:prop="!disabledXX ? 'lawsNumber':''"
class="add-form-item form-item-disabled">
<el-input :disabled="true" <el-input :disabled="true"
class="formInput" class="formInput"
v-model="dataForm.lawsNumber" v-model="dataForm.lawsNumber"
placeholder="请输入政策编号" placeholder="请输入政策编号"
clearable clearable
/> />
<div class="addButton" style="padding-left: 10px"> <div v-if="!disabledXX" class="addButton" style="padding-left: 10px">
<el-button :disabled="disabledXX" size="small" type="primary" <el-button :disabled="disabledXX" size="small" type="primary"
@click="handleSearchStandard">选择征求意见政策 @click="handleSearchStandard">选择征求意见政策
</el-button> </el-button>
@@ -39,7 +45,9 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="政策名称" prop="lawsName" class="add-form-item form-item-disabled"> <el-form-item label="政策名称"
:prop="!disabledXX ? 'lawsName':''"
class="add-form-item form-item-disabled">
<el-input :disabled="true" <el-input :disabled="true"
v-model="dataForm.lawsName" v-model="dataForm.lawsName"
placeholder="请输入政策名称" placeholder="请输入政策名称"
@@ -51,7 +59,9 @@
<el-row :gutter="24"> <el-row :gutter="24">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="截止时间" prop="endTime" class="add-form-item form-item-disabled"> <el-form-item label="截止时间"
:prop="!disabledXX ? 'endTime':''"
class="add-form-item form-item-disabled">
<el-date-picker :disabled="disabledXX" <el-date-picker :disabled="disabledXX"
v-model="dataForm.endTime" v-model="dataForm.endTime"
type="date" type="date"
@@ -61,7 +71,8 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="责任单位截止时间" prop="responsibleUnitDeadline" <el-form-item label="责任单位截止时间"
:prop="!disabledXX ? 'responsibleUnitDeadline':''"
class="add-form-item form-item-disabled"> class="add-form-item form-item-disabled">
<el-date-picker :disabled="disabledXX" <el-date-picker :disabled="disabledXX"
v-model="dataForm.responsibleUnitDeadline" v-model="dataForm.responsibleUnitDeadline"
@@ -72,9 +83,11 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="24"> <el-row :gutter="24">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="政策征求意见周期" prop="cycleTime" <el-form-item label="政策征求意见周期"
:prop="!disabledXX ? 'cycleTime':''"
class="add-form-item form-item-disabled"> class="add-form-item form-item-disabled">
<el-date-picker :disabled="disabledXX" <el-date-picker :disabled="disabledXX"
v-model="dataForm.cycleTime" v-model="dataForm.cycleTime"
@@ -103,8 +116,7 @@
style="margin-right: 5px;padding-left: 10px"> style="margin-right: 5px;padding-left: 10px">
<div class="fileClass"> <div class="fileClass">
<span @click="handlePreview(item)">{{ item.name }}</span> <span @click="handlePreview(item)">{{ item.name }}</span>
<el-button :disabled="disabledXX" <el-button size="small"
size="small"
@click="clickButtonToUpload(item)" @click="clickButtonToUpload(item)"
icon="el-icon-download" icon="el-icon-download"
style="height: 32px; margin-left: 5px;" style="height: 32px; margin-left: 5px;"
@@ -113,7 +125,7 @@
</div> </div>
</div> </div>
<div> <div>
<el-button :disabled="disabledXX" <el-button v-if="!disabledXX"
type="primary" type="primary"
class="common-button-primary" class="common-button-primary"
@click="fileUpload('templateFileList','templateFileId','.zip,.docx,.doc,.xls,.xlsx',200)" @click="fileUpload('templateFileList','templateFileId','.zip,.docx,.doc,.xls,.xlsx',200)"
@@ -124,15 +136,86 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="24" v-if="taskKey == 'PolicySolicitOpinionProcessKey7'">
<el-col :span="12">
<el-form-item label="责任人" prop="zrrUserNames"
class="add-form-item form-item-disabled">
<el-input @click.native="selectOperation('责任人',dataForm.zrrUserIds,false)"
v-model="dataForm.zrrUserNames"
readonly
placeholder="请选择责任人"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24" v-if="taskKey == 'PolicySolicitOpinionProcessKey9'">
<el-col :span="12">
<el-form-item label="内部评审" prop="internalReviewFlag"
class="add-form-item form-item-disabled">
<el-select v-model="dataForm.internalReviewFlag"
@change="internalReviewFlagChange"
placeholder="请选择内部评审" clearable>
<el-option :value="'0'"
label="是">
</el-option>
<el-option :value="'1'"
label="否">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="本单位审批人" prop="zrdwUserName"
v-if="dataForm.internalReviewFlag == '0'"
class="add-form-item form-item-disabled">
<el-input @click.native="selectOperation('审批人',dataForm.zrdwUserId,true)"
v-model="dataForm.zrdwUserName"
readonly
placeholder="请选择本单位审批人"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24" v-if="taskKey == 'PolicySolicitOpinionProcessKey12'">
<el-col :span="12">
<el-form-item label="会签人" prop="hqrUserNames"
class="add-form-item form-item-disabled">
<el-input @click.native="selectOperation('会签人',dataForm.hqrUserIds,false)"
v-model="dataForm.hqrUserNames"
readonly
placeholder="请选择会签人"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24" v-if="taskKey == 'PolicySolicitOpinionProcessKey16'">
<el-col :span="12">
<el-form-item label="抄送人" prop="csr2UserNames"
class="add-form-item form-item-disabled">
<el-input @click.native="selectOperation('抄送人',dataForm.csr2UserIds,false)"
v-model="dataForm.csr2UserNames"
readonly
placeholder="请选择抄送人"
clearable
></el-input>
</el-form-item>
</el-col>
</el-row>
</div> </div>
</el-form> </el-form>
<solicitationList ref="solicitationListRef"/> <solicitationList v-if="showSolicitation" ref="solicitationListRef"/>
</div> </div>
<el-collapse accordion> <el-collapse accordion>
<el-collapse-item title="意见填写"> <el-collapse-item title="意见填写">
<div style="margin: 10px 0;"> <div style="margin: 10px 0;">
<el-input :disabled="disabledXX" <el-input type="textarea"
type="textarea"
:rows="3" :rows="3"
resize="none" resize="none"
placeholder="请输入意见" placeholder="请输入意见"
@@ -142,26 +225,31 @@
</el-collapse-item> </el-collapse-item>
</el-collapse> </el-collapse>
</div> </div>
<div class="content" v-show="active === '2'"> <div class="content" v-if="showPersonnel && active === '2'">
<personnelInformation ref="personnelInformationRef"/> <personnelInformation ref="personnelInformationRef"/>
</div> </div>
<div class="content" style="padding-top: 20px" v-show="active === '3'"> <div class="content" v-if="showApprovalHistory && active === '3'"
style="padding-top: 20px">
<approvalHistory/> <approvalHistory/>
</div> </div>
<ProcessFooter show-submit <ProcessFooter show-submit
:show-save="showSave" :show-save="showSave"
:submitLoading="isSubmit" :submitLoading="isSubmit"
:rejectLoading="isReject"
:saveLoading="saveLoading" :saveLoading="saveLoading"
:show-transfer="showTransfer" :show-transfer="showTransfer"
:showReject="showReject"
@save="handleSave" @save="handleSave"
@transfer="handleTransfer" @transfer="handleTransfer"
@submit="handleSubmit" @submit="handleSubmit"
@reject="handleReject"
> >
</ProcessFooter> </ProcessFooter>
<Role-tree <Role-tree
check-box :check-box="checkBox"
is-title="转办处理人" :is-title="title"
:is-visible.sync="drawerModal" :is-visible.sync="drawerModal"
:nodeList="nodeList"
@checkedRole="checkedRole" @checkedRole="checkedRole"
></Role-tree> ></Role-tree>
<policySolicitingOpinions ref="policySolicitingOpinionsRef" <policySolicitingOpinions ref="policySolicitingOpinionsRef"
@@ -203,8 +291,8 @@
active: '1', active: '1',
accept: '', accept: '',
fileMax_M: 0, fileMax_M: 0,
disabledXX: false,
drawerModal: false, drawerModal: false,
nodeList: [],
formRules: { formRules: {
lawsNumber: [ lawsNumber: [
{required: true, message: '请输入政策编号', trigger: 'change'}, {required: true, message: '请输入政策编号', trigger: 'change'},
@@ -221,22 +309,99 @@
responsibleUnitDeadline: [ responsibleUnitDeadline: [
{required: true, message: '请选择责任单位截止时间', trigger: 'change'}, {required: true, message: '请选择责任单位截止时间', trigger: 'change'},
], ],
zrrUserNames: [
{required: true, message: '请选择责任人', trigger: 'change'},
],
internalReviewFlag: [
{required: true, message: '请选择内部评审', trigger: 'change'},
],
zrdwUserName: [
{required: true, message: '请选择本单位审批人', trigger: 'change'},
],
hqrUserNames: [
{required: true, message: '请选择会签人', trigger: 'change'},
],
csr2UserNames: [
{required: true, message: '请选择抄送人', trigger: 'change'},
],
}, },
dataForm: {}, dataForm: {},
saveLoading: false, saveLoading: false,
isSubmit: false, isSubmit: false,
isReject: false,
commentText: '', commentText: '',
fileListName: '', fileListName: '',
fileName: '', fileName: '',
taskKey: this.$route.query.taskKey,
title: '',
checkBox: false,
selectType: '',
} }
}, },
computed: { computed: {
showSave() { showSave() { //是否展示保存
if (!this.taskKey || this.taskKey == 'PolicySolicitOpinionProcessKey1' ||
this.taskKey == 'PolicySolicitOpinionProcessKey3' || this.taskKey == 'PolicySolicitOpinionProcessKey7' ||
this.taskKey == 'PolicySolicitOpinionProcessKey8' || this.taskKey == 'PolicySolicitOpinionProcessKey9' ||
this.taskKey == 'PolicySolicitOpinionProcessKey16') {
return true
}
return false
},
showTransfer() {//是否展示转办
if (!this.taskKey) {
return false
}
return true return true
}, },
showTransfer() { showReject() {//是否展示驳回
if (this.taskKey == 'PolicySolicitOpinionProcessKey2' ||
this.taskKey == 'PolicySolicitOpinionProcessKey4' ||
this.taskKey == 'PolicySolicitOpinionProcessKey5' ||
this.taskKey == 'PolicySolicitOpinionProcessKey10' ||
this.taskKey == 'PolicySolicitOpinionProcessKey11' ||
this.taskKey == 'PolicySolicitOpinionProcessKey12' ||
this.taskKey == 'PolicySolicitOpinionProcessKey13' ||
this.taskKey == 'PolicySolicitOpinionProcessKey14' ||
this.taskKey == 'PolicySolicitOpinionProcessKey15') {
return true
}
return false
},
showApprovalHistory() { //是否展示历史信息
if (!this.taskKey) {
return false
}
return true return true
} },
showPersonnel() { //是否展示人员信息
if (!this.taskKey || this.taskKey == 'PolicySolicitOpinionProcessKey1' ||
this.taskKey == 'PolicySolicitOpinionProcessKey3') {
return true
}
return false
},
showSolicitation() { //是否展示征求意见列表
if (this.taskKey == 'PolicySolicitOpinionProcessKey8' ||
this.taskKey == 'PolicySolicitOpinionProcessKey9' ||
this.taskKey == 'PolicySolicitOpinionProcessKey10' ||
this.taskKey == 'PolicySolicitOpinionProcessKey11' ||
this.taskKey == 'PolicySolicitOpinionProcessKey12' ||
this.taskKey == 'PolicySolicitOpinionProcessKey13' ||
this.taskKey == 'PolicySolicitOpinionProcessKey14' ||
this.taskKey == 'PolicySolicitOpinionProcessKey15' ||
this.taskKey == 'PolicySolicitOpinionProcessKey16') {
return true
}
return false
},
disabledXX() {
if (!this.taskKey || this.taskKey == 'PolicySolicitOpinionProcessKey1' ||
this.taskKey == 'PolicySolicitOpinionProcessKey3') {
return false
}
return true
},
}, },
methods: { methods: {
handlePreview(file) { handlePreview(file) {
@@ -288,8 +453,6 @@
let _formData = new FormData(); let _formData = new FormData();
let json = this.form let json = this.form
json.commentText = this.commentText json.commentText = this.commentText
json.filesId = this.addFjList
json.filesName = this.form.fjListName
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
_formData.append("createUser", this.$store.getters.userInfo.userId); _formData.append("createUser", this.$store.getters.userInfo.userId);
_formData.append("createUserName", this.$store.getters.userInfo.userName); _formData.append("createUserName", this.$store.getters.userInfo.userName);
@@ -313,49 +476,8 @@
if (valid) { if (valid) {
this.$refs['Form'].validate((valid) => { this.$refs['Form'].validate((valid) => {
if (valid) { if (valid) {
const json = Object.assign(this.form, this.roleForm);
json.commentText = this.commentText
json.filesId = this.addFjList
json.filesName = this.form.fjListName
this.isSubmit = true this.isSubmit = true
this.saveLoading = true; this.saveLoading = true;
this.$http.post('lawss/activiti/startProcessRollBack', {
createUser: this.$store.getters.userInfo.userId,
createUserName: this.$store.getters.userInfo.userName,
type: 'laws2',
json: JSON.stringify({
form: json,
roleForm: this.roleForm,
commentText: this.commentText
})
}, {_this: this}, res => {
if (res.ok) {
this.$http.post('lawss/activiti/completeTask', {
json: JSON.stringify(json),
taskId: res.data,
userId: this.$store.getters.userInfo.userId
}, {_this: this}, res => {
if (res.success) {
this.$message.success(res.message);
if (this.bpnId !== '') {
let taskId = {
id: this.bpnId
}
taskDel(taskId).then(res => {
return res
})
}
this.$router.push("/processCenter");
}
this.isSubmit = false;
this.saveLoading = false;
})
} else {
this.$message.warning('流程启动失败')
this.isSubmit = false
this.saveLoading = false;
}
})
} else { } else {
return this.$message.warning('请完善人员信息') return this.$message.warning('请完善人员信息')
} }
@@ -365,25 +487,104 @@
} }
}) })
}, },
handleReject() {
},
startProcessRollBack() {
const json = Object.assign(this.form, this.roleForm);
json.commentText = this.commentText
this.$http.post('lawss/activiti/startProcessRollBack', {
createUser: this.$store.getters.userInfo.userId,
createUserName: this.$store.getters.userInfo.userName,
type: 'laws2',
json: JSON.stringify({
form: json,
roleForm: this.roleForm,
commentText: this.commentText
})
}, {_this: this}, res => {
if (res.ok) {
this.completeTask(res.data)
} else {
this.$message.warning('流程启动失败')
this.isSubmit = false
this.saveLoading = false;
}
})
},
completeTask(taskId) {
const json = Object.assign(this.form, this.roleForm);
json.commentText = this.commentText
this.$http.post('lawss/activiti/completeTask', {
json: JSON.stringify(json),
taskId: taskId || this.taskId,
userId: this.$store.getters.userInfo.userId
}, {_this: this}, res => {
if (res.success) {
this.$message.success(res.message);
if (this.bpnId !== '') {
let taskId = {
id: this.bpnId
}
taskDel(taskId).then(res => {
return res
})
}
this.$router.push("/processCenter");
}
this.isSubmit = false;
this.saveLoading = false;
})
},
handleTransfer() { handleTransfer() {
this.title = '转办处理人'
this.checkBox = true
this.selectType = '转办处理人'
this.nodeList = []
this.drawerModal = true this.drawerModal = true
}, },
checkedRole(data) { checkedRole(data) {
changeAssigneeNew({ let ids = []
taskId: this.$route.query.taskIds, // 任务id let names = []
userId: this.$store.getters.userInfo.userId, // 委托人 if (data && data.length > 0) {
assignee: data[0].id, // 被委托人 for (let i = 0; i < data.length; i++) {
pId: this.$route.query.prcId, // 流程实例 ids.push(data[i].id)
}).then(res => { names.push(data[i].name)
if (res.success) {
this.drawerModal = false
this.$message.success('调整成功')
this.processNum()
this.$router.push({path: '/processCenter?tabsName=ProcessCenter'})
} else {
this.$message.warning(res.message)
} }
}) }
if (this.selectType == '转办处理人') {
changeAssigneeNew({
taskId: this.$route.query.taskIds, // 任务id
userId: this.$store.getters.userInfo.userId, // 委托人
assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例
}).then(res => {
if (res.success) {
this.drawerModal = false
this.$message.success('调整成功')
this.processNum()
this.$router.push({path: '/processCenter?tabsName=ProcessCenter'})
} else {
this.$message.warning(res.message)
}
})
} else if (this.selectType == '责任人') {
this.dataForm.zrrUserIds = ids.join(',')
this.dataForm.zrrUserNames = names.join(',')
this.dataForm = {...this.dataForm}
} else if (this.selectType == '审批人') {
this.dataForm.zrdwUserId = ids.join(',')
this.dataForm.zrdwUserName = names.join(',')
this.dataForm = {...this.dataForm}
} else if (this.selectType == '会签人') {
this.dataForm.hqrUserIds = ids.join(',')
this.dataForm.hqrUserNames = names.join(',')
this.dataForm = {...this.dataForm}
} else if (this.selectType == '抄送人') {
this.dataForm.csr2UserIds = ids.join(',')
this.dataForm.csr2UserNames = names.join(',')
this.dataForm = {...this.dataForm}
}
}, },
// 请求转换流程图 // 请求转换流程图
processNum(row) { processNum(row) {
@@ -398,6 +599,20 @@
this.processStep = window.URL.createObjectURL(res.data) this.processStep = window.URL.createObjectURL(res.data)
}) })
}, },
selectOperation(title, id, isTrue) {
this.title = title
this.checkBox = isTrue
this.selectType = title
let ids = id && id.length > 0 ? id.split(',') : []
this.nodeList = ids
this.drawerModal = true
},
internalReviewFlagChange() {
this.dataForm.zrdwUserId = ''
this.dataForm.zrdwUserName = ''
this.dataForm = {...this.dataForm}
},
} }
} }
</script> </script>