|
@@ -1,6 +1,7 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<div class="flex-handle">
|
|
|
+ <!-- <button @click="qqq">123</button> -->
|
|
|
<div class="flex-left">
|
|
|
<div class="flex-left-header">
|
|
|
<div class="flex-path">
|
|
@@ -52,11 +53,10 @@
|
|
|
</el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="flex-right" :class="{ copyClass: CopyStatus }">
|
|
|
- <div
|
|
|
- class="flex-left-header-text"
|
|
|
- :class="{ 'flex-right-text': CopyStatus }"
|
|
|
- >
|
|
|
+ <!-- :class="{ copyClass: CopyStatus }" -->
|
|
|
+ <!-- :class="{ 'flex-right-text': CopyStatus }" -->
|
|
|
+ <div class="flex-right">
|
|
|
+ <div class="flex-left-header-text">
|
|
|
本部门人员办理
|
|
|
<div style="display: flex">
|
|
|
<div class="flex-header-text-tree">
|
|
@@ -74,7 +74,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
|
|
|
+ <!-- <div v-if="CopyStatus" class="flex-left-header-text flex-right-text">
|
|
|
抄送人员
|
|
|
<div style="display: flex">
|
|
|
<div class="flex-header-text-tree">
|
|
@@ -91,7 +91,7 @@
|
|
|
<div class="">{{ copyUser }}</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- </div>
|
|
|
+ </div> -->
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="flex-footer-botton">
|
|
@@ -99,6 +99,29 @@
|
|
|
<el-button type="primary" @click="submitWork()">提交</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
+ <el-dialog
|
|
|
+ title="修改常用意见"
|
|
|
+ :visible.sync="editStatus"
|
|
|
+ width="100%"
|
|
|
+ :before-close="editCloses"
|
|
|
+ :modal="false"
|
|
|
+ :destroy-on-close="true"
|
|
|
+ >
|
|
|
+ <div style="overflow-y: scroll; overflow-x: hidden; height: 240px">
|
|
|
+ <div
|
|
|
+ v-for="(item, index) in commonlyList"
|
|
|
+ :key="index"
|
|
|
+ ref="common"
|
|
|
+ class="flex-common"
|
|
|
+ >
|
|
|
+ {{ item.dataName
|
|
|
+ }}<i class="el-icon-circle-close" @click="deleStatus(item)"></i>
|
|
|
+ </div>
|
|
|
+ <div class="flex-common">
|
|
|
+ <i class="el-icon-circle-plus-outline" @click="addStatus()"></i>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -118,7 +141,7 @@ export default {
|
|
|
node: [], //路径列表
|
|
|
seleIndex: "", //点击路径下标
|
|
|
commonlyList: [], //常用意见数组
|
|
|
- textarea: "", //意见内容字段
|
|
|
+ textarea: "未填写意见", //意见内容字段
|
|
|
copyUser: "", //抄送人员列表
|
|
|
selectUser: "", //已选人员列表
|
|
|
treeList: [], // 待选人员列表
|
|
@@ -127,6 +150,9 @@ export default {
|
|
|
initialList: [], //第一次进入是加载节点
|
|
|
clicknextName: "", //获取的流程节点
|
|
|
backThree: [],
|
|
|
+ editStatus: false, //修改控制显示字段
|
|
|
+ treeCopyList: [],
|
|
|
+ demand: "",
|
|
|
};
|
|
|
},
|
|
|
props: {
|
|
@@ -140,11 +166,34 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
created() {
|
|
|
+ console.log(this.list);
|
|
|
this.getNextPath(this.list.resourceId, 1);
|
|
|
this.getMetirialType();
|
|
|
},
|
|
|
methods: {
|
|
|
+ //生成需求决策编号接口
|
|
|
+ getDemand() {
|
|
|
+ this.$http({
|
|
|
+ url: "/market/waf/getBusi",
|
|
|
+ method: "post",
|
|
|
+ headers: {
|
|
|
+ "Content-Type": "application/json",
|
|
|
+ },
|
|
|
+ data:{}
|
|
|
+ }).then((res) => {
|
|
|
+ console.log(res);
|
|
|
+ this.demand = res.data;
|
|
|
+ });
|
|
|
+ },
|
|
|
submitWork() {
|
|
|
+ //生成需求决策编号
|
|
|
+ if (this.clicknextName === "起草人发送") {
|
|
|
+ this.getDemand()
|
|
|
+ }
|
|
|
+ if (!this.list.taskId) {
|
|
|
+ this.$message.error("请先保存表单后处理");
|
|
|
+ return false;
|
|
|
+ }
|
|
|
if (this.TransferStatus === true) {
|
|
|
if (this.backThree.length > 0) {
|
|
|
this.nextWork();
|
|
@@ -162,9 +211,9 @@ export default {
|
|
|
// resolution: this.nodes.currentShape[0].condition.resolution, //流程图线节点
|
|
|
// nextDealMan: this.backThree[0].loginNoStr || '', //下一步处理人
|
|
|
};
|
|
|
- if (this.copyUser) {
|
|
|
+ if (this.treeCopyList.length) {
|
|
|
//抄送
|
|
|
- list.copyman = this.backCopyThree[0].loginNoStr;
|
|
|
+ list.copyman = this.treeCopyList[0].loginNoStrCopy;
|
|
|
}
|
|
|
if (this.nodes.currentShape) {
|
|
|
list.resolution = this.nodes.currentShape[0].condition.resolution;
|
|
@@ -199,7 +248,6 @@ export default {
|
|
|
userId: _this.backThree[0].loginNoStr,
|
|
|
taskId: _this.list.taskId,
|
|
|
content: _this.textarea,
|
|
|
- tableName: _this.requestForm.processDefinitionKey,
|
|
|
};
|
|
|
obj.url = _this.$url.formList.transferTask + _this.list.taskId;
|
|
|
obj.data = lists;
|
|
@@ -211,7 +259,6 @@ export default {
|
|
|
let list = {
|
|
|
taskId: data.taskid,
|
|
|
id: _this.list.id,
|
|
|
- tableName: _this.requestForm.processDefinitionKey,
|
|
|
};
|
|
|
|
|
|
_this.setUpdate(list);
|
|
@@ -221,12 +268,13 @@ export default {
|
|
|
id: _this.list.id,
|
|
|
resourceId: _this.nodes.currentShape[0].resourceId,
|
|
|
taskName: _this.nodes.nextShapes[0].properties.name,
|
|
|
- tableName: _this.requestForm.processDefinitionKey,
|
|
|
};
|
|
|
if (data.copytaskid) {
|
|
|
list.copytaskid = data.copytaskid;
|
|
|
- list.copyman = _this.backCopyThree[0].loginNoStr;
|
|
|
- // list.tableName = _this.requestForm.processDefinitionKey;
|
|
|
+ list.copyman = _this.treeCopyList[0].loginNoStrCopy;
|
|
|
+ }
|
|
|
+ if(_this.demand){
|
|
|
+ list.needNo = _this.demand
|
|
|
}
|
|
|
_this.setUpdate(list);
|
|
|
}
|
|
@@ -234,23 +282,25 @@ export default {
|
|
|
let list = {
|
|
|
taskName: "结束",
|
|
|
id: _this.list.id,
|
|
|
- tableName: _this.requestForm.processDefinitionKey,
|
|
|
};
|
|
|
_this.setUpdate(list);
|
|
|
}
|
|
|
- _this.dialogStatus = false;
|
|
|
- _this.handleCloses();
|
|
|
}
|
|
|
},
|
|
|
+ // qqq() {
|
|
|
+ // this.$emit("beforeClose", true);
|
|
|
+ // },
|
|
|
+ //更新工作流接口
|
|
|
setUpdate(e) {
|
|
|
this.$http({
|
|
|
- url: "/market/waf/updateBase",
|
|
|
+ url: "/market/waf/update",
|
|
|
method: "post",
|
|
|
headers: {
|
|
|
"Content-Type": "application/json",
|
|
|
},
|
|
|
data: e,
|
|
|
}).then((res) => {
|
|
|
+ this.$emit("beforeClose", true);
|
|
|
// this.fromList.taskId = res.data.body.taskId;
|
|
|
// this.fromList.taskName = res.data.body.taskName;
|
|
|
// if (res.data.body.taskName === "起草") {
|
|
@@ -269,9 +319,12 @@ export default {
|
|
|
// fresourceId: "bf79721c-33f3-11ed-ba0b-00505687dcd3", //测试环境
|
|
|
fresourceId: this.requestForm.fresourceId, // 本地环境
|
|
|
processId: this.requestForm.processDefinitionKey,
|
|
|
+ // fresourceId: "0d94de8a-0281-11ed-a302-4ae7da54db39", // 本地环境
|
|
|
+ // processId: "request_form_process",
|
|
|
// resourceId: e,
|
|
|
};
|
|
|
if (e) {
|
|
|
+ // this.propsList = [];
|
|
|
list.resourceId = e;
|
|
|
}
|
|
|
this.$http({
|
|
@@ -295,9 +348,9 @@ export default {
|
|
|
this.transferStatus = false;
|
|
|
}
|
|
|
if (res.data.body.nextShapes[0].copy !== null) {
|
|
|
- console.log(res.data.body.nextShapes[0].copy.copy);
|
|
|
if (res.data.body.nextShapes[0].copy.copy === "true") {
|
|
|
- this.copyStatus = true; //抄送按钮生效
|
|
|
+ // this.copyStatus = true; //抄送按钮生效
|
|
|
+ this.CopyStatus = true;
|
|
|
} else {
|
|
|
this.copyStatus = false;
|
|
|
}
|
|
@@ -323,12 +376,17 @@ export default {
|
|
|
},
|
|
|
//查询候选人接口
|
|
|
getTreeLists(e, status) {
|
|
|
- let createdId = "createld"
|
|
|
- let id =
|
|
|
- e.nextShapes[0].properties.documentation === createdId
|
|
|
- ? this.list.createId
|
|
|
- : e.nextShapes[0].properties.documentation;
|
|
|
- console.log(id);
|
|
|
+ let id = "";
|
|
|
+ if (status === 2) {
|
|
|
+ id = "copy." + e;
|
|
|
+ } else {
|
|
|
+ id =
|
|
|
+ e.nextShapes[0].properties.documentation == "createId" ||
|
|
|
+ e.nextShapes[0].properties.documentation == "createId-copy"
|
|
|
+ ? this.list.createId
|
|
|
+ : e.nextShapes[0].properties.documentation;
|
|
|
+ }
|
|
|
+
|
|
|
this.$http({
|
|
|
url: "/market/api/user/info/queryNodePers?params=" + id,
|
|
|
method: "post",
|
|
@@ -340,6 +398,7 @@ export default {
|
|
|
console.log(status);
|
|
|
if (status === 2) {
|
|
|
this.treeCopyList = res.data; //抄送
|
|
|
+ console.log(this.treeCopyList);
|
|
|
// this.$refs.defTrees.treeList = res.data;
|
|
|
} else {
|
|
|
this.treeList = res.data; //抄送
|
|
@@ -359,7 +418,7 @@ export default {
|
|
|
},
|
|
|
//点击节点获取下一步的处理人字段
|
|
|
clickGetTree(e, index) {
|
|
|
- this.CopyStatus = false;
|
|
|
+ // this.CopyStatus = false;
|
|
|
this.TransferStatus = false;
|
|
|
// this.clickTaskName = e.properties.name;
|
|
|
this.clicknextName = e.properties.name;
|
|
@@ -372,6 +431,7 @@ export default {
|
|
|
},
|
|
|
//点击修改
|
|
|
clickEdit() {
|
|
|
+ console.log(123);
|
|
|
this.editStatus = true;
|
|
|
},
|
|
|
//选择树的回调
|
|
@@ -380,7 +440,12 @@ export default {
|
|
|
this.$message.error("只能选择一个人");
|
|
|
return;
|
|
|
} else {
|
|
|
+ console.log(e);
|
|
|
this.backThree = e;
|
|
|
+ if (this.CopyStatus === true) {
|
|
|
+ this.getTreeLists(e[0].loginNoStr, 2);
|
|
|
+ }
|
|
|
+
|
|
|
if (e[0]) {
|
|
|
this.selectUser = e[0].loginNameStr;
|
|
|
} else {
|
|
@@ -430,6 +495,62 @@ export default {
|
|
|
this.getMetirialType();
|
|
|
});
|
|
|
},
|
|
|
+ //常用意见添加
|
|
|
+ addStatus() {
|
|
|
+ let newData = Date.parse(new Date());
|
|
|
+ this.$prompt("请输入常用意见", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ })
|
|
|
+ .then(({ value }) => {
|
|
|
+ let list = {
|
|
|
+ dictCode: "approval",
|
|
|
+ dataCode: newData,
|
|
|
+ dataName: value,
|
|
|
+ dictName: "审批意见",
|
|
|
+ };
|
|
|
+ this.geaddctType(list);
|
|
|
+ this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: "常用意见添加成功",
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ this.$message({
|
|
|
+ type: "info",
|
|
|
+ message: "取消输入",
|
|
|
+ });
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //常用意见删除
|
|
|
+ deleStatus(e) {
|
|
|
+ this.$confirm("此操作将删除此常用意见, 是否继续?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ let list = {
|
|
|
+ dataCode: e.dataCode,
|
|
|
+ dictCode: "approval",
|
|
|
+ };
|
|
|
+ this.geDelectType(list);
|
|
|
+ this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: "删除成功!",
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ this.$message({
|
|
|
+ type: "info",
|
|
|
+ message: "已取消删除",
|
|
|
+ });
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //关闭修改
|
|
|
+ editCloses() {
|
|
|
+ this.editStatus = false;
|
|
|
+ },
|
|
|
},
|
|
|
};
|
|
|
</script>
|