|
@ -30,12 +30,12 @@ |
|
|
</el-select> |
|
|
</el-select> |
|
|
<el-select |
|
|
<el-select |
|
|
v-model="listQuery.bglx" |
|
|
v-model="listQuery.bglx" |
|
|
placeholder="请选择报告类型" |
|
|
placeholder="请选择流程模式" |
|
|
style="width: 200px" |
|
|
style="width: 200px" |
|
|
clearable |
|
|
clearable |
|
|
> |
|
|
> |
|
|
<el-option |
|
|
<el-option |
|
|
v-for="item in bglxList" |
|
|
v-for="item in modeList" |
|
|
:key="item.value" |
|
|
:key="item.value" |
|
|
:label="item.name" |
|
|
:label="item.name" |
|
|
:value="item.value" |
|
|
:value="item.value" |
|
@ -64,10 +64,10 @@ |
|
|
<el-table-column type="selection" width="50" /> |
|
|
<el-table-column type="selection" width="50" /> |
|
|
<el-table-column type="index" align="center" label="序号" width="50" /> |
|
|
<el-table-column type="index" align="center" label="序号" width="50" /> |
|
|
<el-table-column |
|
|
<el-table-column |
|
|
:formatter="formatterBglx" |
|
|
:formatter="formatterMode" |
|
|
align="center" |
|
|
align="center" |
|
|
label="报告类型" |
|
|
label="流程模式" |
|
|
prop="bglx" |
|
|
prop="mode" |
|
|
width="100" |
|
|
width="100" |
|
|
/> |
|
|
/> |
|
|
<el-table-column align="center" label="归属部门" prop="departmentName" /> |
|
|
<el-table-column align="center" label="归属部门" prop="departmentName" /> |
|
@ -93,7 +93,7 @@ |
|
|
<el-table-column align="center" label="环节处理人" prop="nickname" /> |
|
|
<el-table-column align="center" label="环节处理人" prop="nickname" /> |
|
|
<el-table-column align="center" fixed="right" label="管理" width="150px"> |
|
|
<el-table-column align="center" fixed="right" label="管理" width="150px"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-dropdown trigger="click"> |
|
|
<el-dropdown trigger="hover"> |
|
|
<el-button |
|
|
<el-button |
|
|
type="text" |
|
|
type="text" |
|
|
round |
|
|
round |
|
@ -109,12 +109,12 @@ |
|
|
修改 |
|
|
修改 |
|
|
</el-button> |
|
|
</el-button> |
|
|
</el-dropdown-item> |
|
|
</el-dropdown-item> |
|
|
<el-dropdown-item v-for="link in linkList" :key="link.value"> |
|
|
<el-dropdown-item v-for="link in linkList" v-show="link.mode === scope.row.mode" :key="link.id"> |
|
|
<el-button |
|
|
<el-button |
|
|
type="text" |
|
|
type="text" |
|
|
@click="showUpdateMember(scope.$index, link.value, scope.row)" |
|
|
@click="showUpdateMember(scope.$index, link.id)" |
|
|
> |
|
|
> |
|
|
{{ link.name }} |
|
|
{{ getLinkName(link) }} |
|
|
</el-button> |
|
|
</el-button> |
|
|
</el-dropdown-item> |
|
|
</el-dropdown-item> |
|
|
</el-dropdown-menu> |
|
|
</el-dropdown-menu> |
|
@ -202,10 +202,10 @@ |
|
|
/> |
|
|
/> |
|
|
</el-select> |
|
|
</el-select> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="报告类型" required> |
|
|
<el-form-item label="流程模式" required> |
|
|
<el-select v-model="formDefinition.bglx" clearable> |
|
|
<el-select v-model="formDefinition.mode" clearable> |
|
|
<el-option |
|
|
<el-option |
|
|
v-for="item in bglxList" |
|
|
v-for="item in modeList" |
|
|
:key="item.value" |
|
|
:key="item.value" |
|
|
:label="item.name" |
|
|
:label="item.name" |
|
|
:value="item.value" |
|
|
:value="item.value" |
|
@ -231,31 +231,32 @@ |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
<!-- 添加人员 --> |
|
|
<!-- 添加人员 --> |
|
|
<el-dialog |
|
|
<el-dialog |
|
|
:title="textMapMember[dialogStatus]" |
|
|
:title="memerTitle" |
|
|
:visible.sync="dialogFormMemberVisible" |
|
|
:visible.sync="dialogFormMemberVisible" |
|
|
> |
|
|
> |
|
|
<!-- <el-row> |
|
|
<el-row :gutter="20"> |
|
|
<el-col :span="3"> |
|
|
<el-col :span="3"> |
|
|
<el-button type="primary" icon="el-icon-plus"> |
|
|
<el-button type="primary" icon="el-icon-plus" @click="tableJs.addRow($refs.tableData, { definitionId: definitionId, linkId: linkId })"> |
|
|
新建 |
|
|
新建 |
|
|
</el-button> |
|
|
</el-button> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="3"> |
|
|
<el-col :offset="1" :span="3"> |
|
|
<el-button type="danger" icon="el-icon-delete"> |
|
|
<el-button type="danger" icon="el-icon-delete" @click="deleteLink"> |
|
|
删除 |
|
|
删除 - TODO |
|
|
</el-button> |
|
|
</el-button> |
|
|
</el-col> |
|
|
</el-col> |
|
|
</el-row> --> |
|
|
</el-row> |
|
|
<el-table |
|
|
<el-table |
|
|
|
|
|
ref="tableData" |
|
|
:data="tableData" |
|
|
:data="tableData" |
|
|
|
|
|
border |
|
|
style="width: 100%" |
|
|
style="width: 100%" |
|
|
@selection-change="handleSelectionChange" |
|
|
|
|
|
> |
|
|
> |
|
|
<el-table-column type="selection" width="55" /> |
|
|
<el-table-column type="selection" width="55" /> |
|
|
<el-table-column type="index" label="序号" width="50" /> |
|
|
<el-table-column type="index" label="序号" width="50" /> |
|
|
<el-table-column prop="userId" label="环节人员" width="180"> |
|
|
<el-table-column prop="nickname" label="环节人员" width="180"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-select v-model="scope.row.nickname" placeholder="请选择"> |
|
|
<el-select v-model="scope.row.userId" filterable clearable placeholder="请选择"> |
|
|
<el-option |
|
|
<el-option |
|
|
v-for="item in options" |
|
|
v-for="item in options" |
|
|
:key="item.id" |
|
|
:key="item.id" |
|
@ -311,7 +312,7 @@ export default { |
|
|
create: '添加人员', |
|
|
create: '添加人员', |
|
|
update: '编辑人员' |
|
|
update: '编辑人员' |
|
|
}, |
|
|
}, |
|
|
bglx: 1, |
|
|
mode: 1, |
|
|
sbzlList: [], |
|
|
sbzlList: [], |
|
|
listDepartment: [], |
|
|
listDepartment: [], |
|
|
listLink: [], |
|
|
listLink: [], |
|
@ -323,16 +324,8 @@ export default { |
|
|
formMember: {}, |
|
|
formMember: {}, |
|
|
jylbList: [], |
|
|
jylbList: [], |
|
|
nblbList: [], |
|
|
nblbList: [], |
|
|
bglxList: [], |
|
|
modeList: [], |
|
|
linkList: [ |
|
|
linkList: [], |
|
|
{ name: '审核', value: 2 }, |
|
|
|
|
|
{ name: '审批', value: 3 }, |
|
|
|
|
|
{ name: '重启质检', value: 5 }, |
|
|
|
|
|
{ name: '重启技检', value: 6 }, |
|
|
|
|
|
{ name: '重启审批', value: 7 }, |
|
|
|
|
|
{ name: '收费审核', value: 8 }, |
|
|
|
|
|
{ name: '收费审批', value: 9 } |
|
|
|
|
|
], |
|
|
|
|
|
multipleSelection: [], |
|
|
multipleSelection: [], |
|
|
dialogFormVisible: false, |
|
|
dialogFormVisible: false, |
|
|
dialogFormMemberVisible: false, |
|
|
dialogFormMemberVisible: false, |
|
@ -340,18 +333,61 @@ export default { |
|
|
neibuleibie: [], |
|
|
neibuleibie: [], |
|
|
spanArr: [], |
|
|
spanArr: [], |
|
|
tableData: [], |
|
|
tableData: [], |
|
|
options: [] |
|
|
options: [], |
|
|
|
|
|
memerTitle: '', |
|
|
|
|
|
definitionId: 0, |
|
|
|
|
|
linkId: 0, |
|
|
|
|
|
linkLabelList: [] |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
created() { |
|
|
created() { |
|
|
this.getList() |
|
|
this.getList() |
|
|
this.getAllDepartment() |
|
|
this.getAllDepartment() |
|
|
this.getSbList() |
|
|
this.getSbList() |
|
|
this.getBglxList() |
|
|
this.getDicDataList('REPORT_CLASS') |
|
|
|
|
|
this.getDicDataList('FLOW_LINK') |
|
|
this.getJylbList() |
|
|
this.getJylbList() |
|
|
this.getUserList() |
|
|
this.getUserList() |
|
|
|
|
|
this.getLinkListAll() |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
deleteLink() { |
|
|
|
|
|
const linkIds = [] |
|
|
|
|
|
console.log(this.$refs.tableData.selection) |
|
|
|
|
|
this.$refs.tableData.selection.forEach(row => { |
|
|
|
|
|
if (row.id) { |
|
|
|
|
|
linkIds.push(row.id) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
this.api({ |
|
|
|
|
|
url: '/definition', |
|
|
|
|
|
method: 'delete', |
|
|
|
|
|
params: { |
|
|
|
|
|
ids: linkIds |
|
|
|
|
|
} |
|
|
|
|
|
}).then(data => { |
|
|
|
|
|
this.$notify.sucess('操作成功') |
|
|
|
|
|
this.$refs.tableData.selection.forEach(row => this.tableData.splice(this.tableData.indexOf(row), 1)) |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
getLinkName(link) { |
|
|
|
|
|
if (!this.linkLabelList.length) { |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
const linkLabel = this.linkLabelList.filter(row => row.value === link.nextName)[0] |
|
|
|
|
|
if (!linkLabel) { |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
return linkLabel.name |
|
|
|
|
|
}, |
|
|
|
|
|
getLinkListAll() { |
|
|
|
|
|
this.api({ |
|
|
|
|
|
url: '/link/all', |
|
|
|
|
|
method: 'get' |
|
|
|
|
|
}).then(data => { |
|
|
|
|
|
this.linkList = data |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
// 获取所有用户 |
|
|
// 获取所有用户 |
|
|
getUserList() { |
|
|
getUserList() { |
|
|
this.api({ |
|
|
this.api({ |
|
@ -398,15 +434,24 @@ export default { |
|
|
this.sbzlList = data |
|
|
this.sbzlList = data |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
getBglxList() { |
|
|
getDicDataList(typeCode) { |
|
|
this.api({ |
|
|
this.api({ |
|
|
url: '/dicData/getDicDataByTypeCode', |
|
|
url: '/dicData/getDicDataByTypeCode', |
|
|
method: 'get', |
|
|
method: 'get', |
|
|
params: { |
|
|
params: { |
|
|
typeCode: 'REPORT_CLASS' |
|
|
typeCode: typeCode |
|
|
} |
|
|
} |
|
|
}).then((data) => { |
|
|
}).then((data) => { |
|
|
this.bglxList = data |
|
|
switch (typeCode) { |
|
|
|
|
|
case 'REPORT_CLASS': |
|
|
|
|
|
this.modeList = data |
|
|
|
|
|
break |
|
|
|
|
|
case 'FLOW_LINK': |
|
|
|
|
|
this.linkLabelList = data |
|
|
|
|
|
break |
|
|
|
|
|
default: |
|
|
|
|
|
break |
|
|
|
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
getJylbList() { |
|
|
getJylbList() { |
|
@ -445,7 +490,7 @@ export default { |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
showCreate() { |
|
|
showCreate() { |
|
|
this.$set(this.formDefinition, 'bglx', 1) |
|
|
this.$set(this.formDefinition, 'mode', 1) |
|
|
this.dialogStatus = 'create' |
|
|
this.dialogStatus = 'create' |
|
|
this.dialogFormVisible = true |
|
|
this.dialogFormVisible = true |
|
|
}, |
|
|
}, |
|
@ -460,40 +505,23 @@ export default { |
|
|
this.dialogStatus = 'update' |
|
|
this.dialogStatus = 'update' |
|
|
this.dialogFormVisible = true |
|
|
this.dialogFormVisible = true |
|
|
}, |
|
|
}, |
|
|
showUpdateMember($index, $link, row) { |
|
|
showUpdateMember($index, linkId) { |
|
|
this.listLink = [] |
|
|
this.tableData = [] |
|
|
this.bglx = this.list[$index].bglx |
|
|
const row = this.list[$index] |
|
|
this.formMember.definitionId = this.list[$index].id |
|
|
this.memerTitle = row.name |
|
|
this.formMember.linkId = $link - 1 |
|
|
this.definitionId = row.id |
|
|
let userIdArray = [] |
|
|
this.linkId = linkId |
|
|
try { |
|
|
this.api({ |
|
|
if ($link === '2') { |
|
|
url: '/member/all', |
|
|
userIdArray = this.list[$index].userId.split(',') |
|
|
method: 'get', |
|
|
} else { |
|
|
params: { |
|
|
if (this.list[$index].id === this.list[$index + 1].id) { |
|
|
definitionId: row.id, |
|
|
userIdArray = this.list[$index + 1].userId.split(',') |
|
|
linkId: linkId |
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} catch (e) { |
|
|
|
|
|
// |
|
|
|
|
|
} |
|
|
|
|
|
const userId = [] |
|
|
|
|
|
for (let i = 0; i < userIdArray.length; i++) { |
|
|
|
|
|
userId.push(parseInt(userIdArray[i])) |
|
|
|
|
|
} |
|
|
} |
|
|
this.listMemberUser = userId |
|
|
}).then(data => { |
|
|
this.dialogStatus = 'update' |
|
|
this.tableData = data |
|
|
console.log(row) |
|
|
|
|
|
const arr = [] |
|
|
|
|
|
arr.push(row) |
|
|
|
|
|
this.tableData = arr |
|
|
|
|
|
this.tableData.map((item) => { |
|
|
|
|
|
item.nickname = item.nickname.split(',') |
|
|
|
|
|
item.userId = item.userId.split(',') |
|
|
|
|
|
}) |
|
|
|
|
|
console.log(this.tableData[0].userId, arr) |
|
|
|
|
|
|
|
|
|
|
|
this.dialogFormMemberVisible = true |
|
|
this.dialogFormMemberVisible = true |
|
|
|
|
|
}) |
|
|
}, |
|
|
}, |
|
|
handleFilter() { |
|
|
handleFilter() { |
|
|
// 查询事件 |
|
|
// 查询事件 |
|
@ -555,12 +583,14 @@ export default { |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
updateLink() { |
|
|
updateLink() { |
|
|
this.formMember.userIds = this.listMemberUser |
|
|
console.log(this.tableData) |
|
|
const _vue = this |
|
|
const _vue = this |
|
|
this.api({ |
|
|
this.api({ |
|
|
url: '/definition/updateGroupMember', |
|
|
url: '/member/updateGroupMembers', |
|
|
method: 'post', |
|
|
method: 'post', |
|
|
data: this.formMember |
|
|
data: { |
|
|
|
|
|
groupMembers: this.tableData |
|
|
|
|
|
} |
|
|
}).then(() => { |
|
|
}).then(() => { |
|
|
this.dialogFormMemberVisible = false |
|
|
this.dialogFormMemberVisible = false |
|
|
this.$message({ |
|
|
this.$message({ |
|
@ -614,10 +644,10 @@ export default { |
|
|
this.formDefinition = {} |
|
|
this.formDefinition = {} |
|
|
this.neibuleibie = [] |
|
|
this.neibuleibie = [] |
|
|
}, |
|
|
}, |
|
|
formatterBglx(row) { |
|
|
formatterMode(row) { |
|
|
const bglx = this.bglxList.filter((bglx) => bglx.value === row.bglx) |
|
|
const mode = this.modeList.filter((mode) => mode.value === row.mode) |
|
|
if (bglx && bglx.length) { |
|
|
if (mode && mode.length) { |
|
|
return bglx[0].name |
|
|
return mode[0].name |
|
|
} else { |
|
|
} else { |
|
|
return '未知' |
|
|
return '未知' |
|
|
} |
|
|
} |
|
@ -657,7 +687,7 @@ export default { |
|
|
// 判断当前元素与上一个元素是否相同 |
|
|
// 判断当前元素与上一个元素是否相同 |
|
|
if ( |
|
|
if ( |
|
|
data[i].departmentId === data[i - 1].departmentId && |
|
|
data[i].departmentId === data[i - 1].departmentId && |
|
|
data[i].bglx === data[i - 1].bglx && |
|
|
data[i].mode === data[i - 1].mode && |
|
|
data[i].shebeizhongleidaima === data[i - 1].shebeizhongleidaima && |
|
|
data[i].shebeizhongleidaima === data[i - 1].shebeizhongleidaima && |
|
|
data[i].neibuleibie === data[i - 1].neibuleibie |
|
|
data[i].neibuleibie === data[i - 1].neibuleibie |
|
|
) { |
|
|
) { |
|
|