拆分结果左侧树形菜单调整

This commit is contained in:
shenyanpei
2021-09-13 16:20:22 +08:00
parent a9b18b12f9
commit db2dde533b
6 changed files with 190 additions and 31 deletions
@@ -47,6 +47,16 @@
:loading="transferLoading"
v-if="showTransfer"
>转办</el-button>
<el-button
type="primary"
size="mini"
class="common-button-primary"
@click="handleTurnTo"
:loading="turnToLoading"
v-if="showTurnTo">
<i class="iconfont">&#xe608;</i>
转办
</el-button>
<el-button
type="primary"
size="mini"
@@ -134,6 +144,16 @@ export default {
type: Boolean,
default: false
},
// 是否显示转办按钮
showTurnTo: {
type: Boolean,
default: false
},
// 转办按钮loading
turnToLoading: {
type: Boolean,
default: false
},
// 是否显示发送邮件按钮
showSendEmail: {
type: Boolean,
@@ -240,6 +260,9 @@ export default {
handleSave() {
this.$emit('save')
},
handleTurnTo() {
this.$emit('turnTo')
},
handleSubmit() {
this.$emit('submit')
},
@@ -213,14 +213,17 @@
<ProcessFooter
show-save
show-submit
show-turn-to
:submitLoading="isSubmit"
:saveLoading="saveLoading"
:turnToLoading="turnLoading"
@turnTo="handleTurnTo"
@save="handleSave"
@submit="handleSubmit"
>
</ProcessFooter>
<Role-tree
is-title="选择人员信息"
:is-title="drawerTitle"
check-box
:is-visible.sync="modalshowflag"
:nodeList="nodeList"
@@ -234,7 +237,7 @@ import ProcessHeader from '../../components/ProcessHeader'
import ProcessFooter from '../../components/ProcessFooter'
import ProcessTitle from '../../components/ProcessTitle'
import { roleTreeData } from "@/api/unqualProcess.js"
import {completeTask, inboundLiaisonDetail, saveinboundTask, saveTaskForPub} from "@/api/process.js"
import {completeTask, inboundLiaisonDetail, saveinboundTask, saveTaskForPub, changeAssigneeNew} from "@/api/process.js"
export default {
name: "wfhxzgStep2",
@@ -248,6 +251,7 @@ export default {
ListModel: false, // 新增编辑抽屉开关
taskIds: this.$route.query.taskIds,
pId: this.$route.query.prcId,
userId: this.$route.query.taskAssignee,
nonSearch: {
standSerialNumber: '',
standId: '', // 标准号/名称
@@ -257,6 +261,7 @@ export default {
active: '1', // 默认显示
isSubmit: false,
saveLoading: false,
turnLoading: false,
dataList: [],
endDataList: [],
lastDataList: [],
@@ -370,6 +375,11 @@ export default {
this.active = name
},
// 转办按钮
handleTurnTo() {
this.modalshowflag = true
this.drawerTitle = '转办处理人'
},
// 保存按钮
handleSave() {
this.saveLoading = true
@@ -444,21 +454,39 @@ export default {
this.modalshowflag = true
},
drawerCheck (data) {
this.roleRow = data[0]
// 选取负责人时的操作
if (this.multipleSelection.length === 0) {
this.rowDutyPeople.dutyPeopleInfo = this.roleRow.name
this.rowDutyPeople.dutyPeopleInfoId = this.roleRow.id
}else {
this.multipleSelection.forEach(item => {
item.dutyPeopleInfo = this.roleRow.name
item.dutyPeopleInfoId = this.roleRow.id
if (this.drawerTitle === '转办处理人') {
this.turnLoading = true
changeAssigneeNew({
taskId: this.taskIds, // 任务id
assignee: data[0].id, // 被委托人
userId: this.userId, // 委托人
pId: this.pId // 流程实例
}).then(res =>{
if (res.success) {
this.turnLoading = false
this.$message.success('调整成功')
this.$router.push("/processCenter")
} else {
this.$message.warning(res.message)
}
})
this.$refs.multipleTable.clearSelection()
} else {
this.roleRow = data[0]
// 选取负责人时的操作
if (this.multipleSelection.length === 0) {
this.rowDutyPeople.dutyPeopleInfo = this.roleRow.name
this.rowDutyPeople.dutyPeopleInfoId = this.roleRow.id
}else {
this.multipleSelection.forEach(item => {
item.dutyPeopleInfo = this.roleRow.name
item.dutyPeopleInfoId = this.roleRow.id
})
this.$refs.multipleTable.clearSelection()
}
this.lastDataList = this.dataList
// 选取流程信息完成
// this.roleForm.dutyUserInfoName = this.roleRow.name
}
this.lastDataList = this.dataList
// 选取流程信息完成
// this.roleForm.dutyUserInfoName = this.roleRow.name
this.modalshowflag = false
},
//查询按钮
@@ -220,8 +220,11 @@
show-save
show-submit
show-back
show-turn-to
:submitLoading="isSubmit"
:saveLoading="saveLoading"
:turnToLoading="turnLoading"
@turnTo="handleTurnTo"
@back="handleSubmitNo"
@save="handleSave"
@submit="handleSubmit"
@@ -229,7 +232,7 @@
</ProcessFooter>
<Role-tree
check-box
is-title="选择人员信息"
:is-title="drawerTitle"
:is-visible.sync="modalshowflag"
:nodeList="nodeList"
@checkedRole="drawerCheck"
@@ -241,7 +244,7 @@
import ProcessHeader from '../../components/ProcessHeader'
import ProcessFooter from '../../components/ProcessFooter'
import ProcessTitle from '../../components/ProcessTitle'
import {completeTask, inboundLiaisonDetail, saveTaskForPub} from "@/api/process.js";
import {changeAssigneeNew, completeTask, inboundLiaisonDetail, saveTaskForPub} from "@/api/process.js";
export default {
name: "wfhxzgStep3",
@@ -261,8 +264,10 @@ export default {
active: '1', // 默认显示
isSubmit: false,
saveLoading: false,
turnLoading: false,
taskIds: this.$route.query.taskIds,
pId: this.$route.query.prcId,
userId: this.$route.query.taskAssignee,
dataList: [],
newDataList: {},
// 批量选择负责人table数组
@@ -339,6 +344,7 @@ export default {
this.newDataList = val
this.nodeList = []
this.modalshowflag = true
this.drawerTitle = '选择人员信息'
},
// 批量选择负责人按钮
dutyPeopleList(id) {
@@ -357,6 +363,11 @@ export default {
handleTabs(name) {
this.active = name
},
// 转办按钮
handleTurnTo() {
this.modalshowflag = true
this.drawerTitle = '转办处理人'
},
// 退回按钮
handleSubmitNo() {
if (this.commentText) {
@@ -478,18 +489,36 @@ export default {
},
drawerCheck (data) {
this.roleForm = data[0]
// 选择责任人时input框内值
if (this.selectTableMore.length ===0) {
this.newDataList.dutyPeople = this.roleForm.name
this.newDataList.dutyPeopleId = this.roleForm.id
}else {
this.selectTableMore.forEach(item => {
item.dutyPeople = this.roleForm.name
item.dutyPeopleId = this.roleForm.id
if (this.drawerTitle === '转办处理人') {
this.turnLoading = true
changeAssigneeNew({
taskId: this.taskIds, // 任务id
assignee: data[0].id, // 被委托人
userId: this.userId, // 委托人
pId: this.pId // 流程实例
}).then(res =>{
if (res.success) {
this.turnLoading = false
this.$message.success('调整成功')
this.$router.push("/processCenter")
} else {
this.$message.warning(res.message)
}
})
} else {
this.roleForm = data[0]
// 选择责任人时input框内值
if (this.selectTableMore.length ===0) {
this.newDataList.dutyPeople = this.roleForm.name
this.newDataList.dutyPeopleId = this.roleForm.id
}else {
this.selectTableMore.forEach(item => {
item.dutyPeople = this.roleForm.name
item.dutyPeopleId = this.roleForm.id
})
}
this.lastDataList = this.dataList
}
this.lastDataList = this.dataList
this.modalshowflag = false
},
@@ -217,12 +217,22 @@
<ProcessFooter
show-save
show-submit
show-turn-to
:submitLoading="isSubmit"
:saveLoading="saveLoading"
:turn-to-loading="turnLoading"
@turnTo="handleTurnTo"
@save="handleSave"
@submit="handleSubmit"
>
</ProcessFooter>
<Role-tree
:is-title="drawerTitle"
check-box
:is-visible.sync="modalshowflag"
:nodeList="nodeList"
@checkedRole="drawerCheck"
/>
</div>
</template>
@@ -230,14 +240,15 @@
import ProcessHeader from '../../components/ProcessHeader'
import ProcessFooter from '../../components/ProcessFooter'
import ProcessTitle from '../../components/ProcessTitle'
import {uploadFile} from '@/api/unqualProcess.js';
import {inboundLiaisonDetail, completeTask, saveTaskForPub} from "@/api/process"
import listOfCountries from "@/pages/regulatoryRepository/accessStandardsAndRegulations/page/listOfCountries";
import {inboundLiaisonDetail, completeTask, saveTaskForPub, changeAssigneeNew} from "@/api/process"
export default {
name: "wfhxzgStep4",
data() {
return {
drawerTitle: '',
nodeList: [],
modalshowflag: false, // drawer开关
detailData: [],
loading: false,
textarea: '', // 意见
@@ -251,9 +262,11 @@ export default {
active: '1', // 默认显示
isSubmit: false,
saveLoading: false,
turnLoading: false,
dataList: [],
taskIds: this.$route.query.taskIds,
pId: this.$route.query.prcId,
userId: this.$route.query.taskAssignee,
// 当前页数
pageNo: 1,
total: 0,
@@ -409,6 +422,30 @@ export default {
})
window.open(routeUrl.href, '_blank')
},
drawerCheck (data) {
this.turnLoading = true
changeAssigneeNew({
taskId: this.taskIds, // 任务id
assignee: data[0].id, // 被委托人
userId: this.userId, // 委托人
pId: this.pId // 流程实例
}).then(res =>{
this.isSubmit = true
if (res.success) {
this.turnLoading = false
this.$message.success('调整成功')
this.$router.push("/processCenter")
} else {
this.$message.warning(res.message)
}
})
this.modalshowflag = false
},
// 转办按钮
handleTurnTo() {
this.modalshowflag = true
this.drawerTitle = '转办处理人'
},
// 保存按钮
handleSave() {
let zqa = new Map();
@@ -199,9 +199,12 @@
show-submit
show-back
approval
show-turn-to
@back="handleSubmitNo"
:submitLoading="isSubmit"
:isSubmitBack="backLoading"
:turn-to-loading="turnLoading"
@turnTo="handleTurnTo"
@submit="handleSubmit"
submitBTNText="同意"
>
@@ -215,6 +218,13 @@
>
</el-upload>
</el-dialog>
<Role-tree
check-box
:is-title="drawerTitle"
:is-visible.sync="modalshowflag"
:nodeList="nodeList"
@checkedRole="drawerCheck"
/>
</div>
</template>
@@ -223,12 +233,15 @@ import ProcessHeader from '../../components/ProcessHeader'
import ProcessFooter from '../../components/ProcessFooter'
import ProcessTitle from '../../components/ProcessTitle'
import {interfaceUrl} from "@/sysConfig";
import {inboundLiaisonDetail} from "@/api/process";
import {inboundLiaisonDetail, changeAssigneeNew} from "@/api/process";
export default {
name: "wfhxzgStep5",
data() {
return {
drawerTitle: '',
nodeList: [],
modalshowflag: false, // drawer开关
fileMadel: false,
detailData: [],
loading: false,
@@ -245,11 +258,13 @@ export default {
active: '1', // 默认显示
isSubmit: false,
backLoading: false,
turnLoading: false,
dataList: [],
json: {},
taskInfo: this.$route.query.taskInfo,
taskIds: this.$route.query.taskIds,
pId: this.$route.query.prcId,
userId: this.$route.query.taskAssignee,
// 当前页数
pageNo: 1,
total: 0,
@@ -360,6 +375,29 @@ export default {
this.isSubmit = false
})
},
drawerCheck (data) {
this.turnLoading = true
changeAssigneeNew({
taskId: this.taskIds, // 任务id
assignee: data[0].id, // 被委托人
userId: this.userId, // 委托人
pId: this.pId // 流程实例
}).then(res =>{
if (res.success) {
this.turnLoading = false
this.$message.success('调整成功')
this.$router.push("/processCenter")
} else {
this.$message.warning(res.message)
}
})
this.modalshowflag = false
},
// 转办按钮
handleTurnTo() {
this.modalshowflag = true
this.drawerTitle = '转办处理人'
},
handleSubmitNo() {
this.backLoading = true
if (this.commentText) {
@@ -743,6 +743,7 @@ export default {
taskIds: row.taskIds,
prcId: row.prcId,
prcNum: row.prcNum,
taskAssignee: row.taskAssignee,
prcName: row.prcName,
prcType: row.prcType
}
@@ -754,6 +755,7 @@ export default {
taskIds: row.taskIds,
prcId: row.prcId,
prcNum: row.prcNum,
taskAssignee: row.taskAssignee,
prcName: row.prcName,
prcType: row.prcType
}
@@ -765,6 +767,7 @@ export default {
taskIds: row.taskIds,
prcId: row.prcId,
prcNum: row.prcNum,
taskAssignee: row.taskAssignee,
prcName: row.prcName,
prcType: row.prcType
}
@@ -776,6 +779,7 @@ export default {
taskIds: row.taskIds,
prcId: row.prcId,
prcNum: row.prcNum,
taskAssignee: row.taskAssignee,
prcName: row.prcName,
prcType: row.prcType
}