11e2d0c5 by zhaoqian

已办箱功能

1 parent f6a1dfe4
...@@ -115,3 +115,18 @@ export function booleanWorkflow(data) { ...@@ -115,3 +115,18 @@ export function booleanWorkflow(data) {
115 }) 115 })
116 } 116 }
117 117
118
119 /**
120 * 获取工作流大纲
121 */
122 export function getProcessOutlineByYbx(data) {
123 return request({
124 url: '/workflow/getProcessOutline',
125 method: 'get',
126 params: {
127 processInstanceId:data,
128 isCurrent:false
129 }
130 })
131 }
132
......
...@@ -54,6 +54,7 @@ const store = new Vuex.Store({ ...@@ -54,6 +54,7 @@ const store = new Vuex.Store({
54 oldZdbsm:'', 54 oldZdbsm:'',
55 newZdbsm:'', 55 newZdbsm:'',
56 isWorkFlow:false, // 判断是否工作流数据 56 isWorkFlow:false, // 判断是否工作流数据
57 lcgzShow:false,//是否待办箱的数据,显示流程追踪
57 }, 58 },
58 modules: { 59 modules: {
59 user, 60 user,
......
...@@ -181,7 +181,10 @@ export default { ...@@ -181,7 +181,10 @@ export default {
181 }else if(newPath == '/zrz' || newPath == '/zd' || newPath == '/dz'){ 181 }else if(newPath == '/zrz' || newPath == '/zd' || newPath == '/dz'){
182 booleanWorkflow(this.$route.query.ywbsm).then(res=>{ 182 booleanWorkflow(this.$route.query.ywbsm).then(res=>{
183 this.$store.state.isWorkFlow = res.result; 183 this.$store.state.isWorkFlow = res.result;
184 }) 184 });
185 if(typeof this.$route.query.processInstanceId !== 'undefined'){
186 this.$store.state.lcgzShow = true;
187 }
185 } 188 }
186 }, 189 },
187 "$store.state.treeData":function (val) { 190 "$store.state.treeData":function (val) {
......
...@@ -115,14 +115,14 @@ ...@@ -115,14 +115,14 @@
115 115
116 <script> 116 <script>
117 import { Chart, registerShape } from '@antv/g2'; 117 import { Chart, registerShape } from '@antv/g2';
118 import {getDbxList} from "@api/dbx"; 118 import {getDbxList,getYbxList} from "@api/dbx";
119 export default { 119 export default {
120 components:{}, 120 components:{},
121 data() { 121 data() {
122 return { 122 return {
123 workList: [ 123 workList: [
124 { name: "待办箱", img: require("@assets/images/dbx.png"),count:0,path:'/dbx' }, 124 { name: "待办箱", img: require("@assets/images/dbx.png"),count:0,path:'/dbx' },
125 { name: "退件箱", img: require("@assets/images/tjx.png"),count:0,path:'ybx' }, 125 { name: "已办箱", img: require("@assets/images/tjx.png"),count:0,path:'ybx' },
126 ], 126 ],
127 list: [ 127 list: [
128 { name: "宗地分割", img: require("@assets/images/zdfg.png"),path:'change',oLevel:'fg',tLevel:'zd'}, 128 { name: "宗地分割", img: require("@assets/images/zdfg.png"),path:'change',oLevel:'fg',tLevel:'zd'},
...@@ -182,6 +182,7 @@ export default { ...@@ -182,6 +182,7 @@ export default {
182 this.imgHeight = this.$refs.enterBox.offsetHeight - 10 182 this.imgHeight = this.$refs.enterBox.offsetHeight - 10
183 }); 183 });
184 this.getDbxCount(); 184 this.getDbxCount();
185 this.getYbxCount();
185 this.initG2qllx(); 186 this.initG2qllx();
186 this.initG2tdfwtj(); 187 this.initG2tdfwtj();
187 this.initG2xntjid(); 188 this.initG2xntjid();
...@@ -248,6 +249,23 @@ export default { ...@@ -248,6 +249,23 @@ export default {
248 } 249 }
249 }) 250 })
250 }, 251 },
252 getYbxCount(){
253 let data = {
254 page:0,
255 size:20,
256 current:false,
257 currentUser:true,
258 createDateStart:"",
259 createDateEnd:""
260 }
261 getYbxList(data).then((res)=>{
262 this.workList.forEach((item,index)=>{
263 if(item.name === '已办箱'){
264 item.count = res.totalElements;
265 }
266 })
267 })
268 },
251 initG2qllx(){ 269 initG2qllx(){
252 const data = [ 270 const data = [
253 { item: '国有建设用地使用权', count: 40, percent: 0.4 }, 271 { item: '国有建设用地使用权', count: 40, percent: 0.4 },
......
...@@ -170,10 +170,10 @@ ...@@ -170,10 +170,10 @@
170 path: path, 170 path: path,
171 query: { 171 query: {
172 bsm: data.glbsm, 172 bsm: data.glbsm,
173 ywbsm: data.businessId, 173 ywbsm: data.glbsm,
174 source: 2, 174 source: 2,
175 auth: '0,1,2', 175 auth: '0,1,2',
176 workitemInstanceId:data.id 176 processInstanceId:row.id
177 } 177 }
178 }); 178 });
179 179
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
15 <el-tab-pane label="附件材料" name="fjcl"> 15 <el-tab-pane label="附件材料" name="fjcl">
16 <fjcl v-if="fjclVisible" ref="fjcl" :is-disabled="isDisabled"></fjcl> 16 <fjcl v-if="fjclVisible" ref="fjcl" :is-disabled="isDisabled"></fjcl>
17 </el-tab-pane> 17 </el-tab-pane>
18 <el-tab-pane label="流程跟踪" name="lcgz" v-if="$store.state.isWorkFlow" lazy> 18 <el-tab-pane label="流程跟踪" name="lcgz" v-if="$store.state.isWorkFlow || $store.state.lcgzShow" lazy>
19 <lcgz ref="lcgz" ></lcgz> 19 <lcgz ref="lcgz" ></lcgz>
20 </el-tab-pane> 20 </el-tab-pane>
21 </el-tabs> 21 </el-tabs>
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
26 <span>创建人</span> 26 <span>创建人</span>
27 <span>{{lcInfo.processInstance.creatorName}}</span> 27 <span>{{lcInfo.processInstance.creatorName}}</span>
28 </li> 28 </li>
29 <li> 29 <li v-if="lcInfo.workitemInstance">
30 <span>流程阶段</span> 30 <span>流程阶段</span>
31 <span>{{lcInfo.workitemInstance.nodeName}}</span> 31 <span>{{lcInfo.workitemInstance.nodeName}}</span>
32 </li> 32 </li>
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
34 <span>流程状态</span> 34 <span>流程状态</span>
35 <span>{{lcInfo.processInstance.state}}</span> 35 <span>{{lcInfo.processInstance.state}}</span>
36 </li> 36 </li>
37 <li> 37 <li v-if="lcInfo.workitemInstance">
38 <span>当前责任人</span> 38 <span>当前责任人</span>
39 <span>{{lcInfo.workitemInstance.actorName}}</span> 39 <span>{{lcInfo.workitemInstance.actorName}}</span>
40 </li> 40 </li>
...@@ -64,7 +64,7 @@ ...@@ -64,7 +64,7 @@
64 </template> 64 </template>
65 65
66 <script> 66 <script>
67 import { getActivityDetail,templateLoad,getProcessOutline } from "@api/user"; 67 import { getActivityDetail,templateLoad,getProcessOutline,getProcessOutlineByYbx } from "@api/user";
68 import flowNode from "./flownode" 68 import flowNode from "./flownode"
69 export default { 69 export default {
70 name: "", 70 name: "",
...@@ -81,7 +81,12 @@ export default { ...@@ -81,7 +81,12 @@ export default {
81 }, 81 },
82 created() {}, 82 created() {},
83 mounted() { 83 mounted() {
84 this.getTemplate(); 84 if(typeof this.$route.query.workitemInstanceId !== 'undefined'){
85 this.getTemplate();
86 }else if(typeof this.$route.query.processInstanceId !== 'undefined'){
87 this.getTemplateByProcessInstanceId();
88 }
89
85 }, 90 },
86 methods: { 91 methods: {
87 getTemplate(){ 92 getTemplate(){
...@@ -122,6 +127,35 @@ export default { ...@@ -122,6 +127,35 @@ export default {
122 vm.loadingHide(); 127 vm.loadingHide();
123 }); 128 });
124 }, 129 },
130
131 getTemplateByProcessInstanceId(){
132 vm.loadingShow('数据获取中');
133 getProcessOutlineByYbx(this.$route.query.processInstanceId).then((res) => {
134 console.log(res.processInstance.templetId);
135 this.lcInfo = res;
136 templateLoad(res.processInstance.templetId).then((res1) => {
137 vm.loadingHide();
138 console.log(this.$x2js.xml2js(res1).Process,'Process');
139 this.flowData = this.$x2js.xml2js(res1).Process;
140 console.log(res1.activityOutlines,'res.activityOutlines');
141 this.flowState = res.activityOutlines;
142 this.$nextTick(()=>{
143 this.flowData.Nodes.ManualNode.push(this.flowData.Nodes.EndNode);
144 this.flowData.Nodes.ManualNode.unshift(this.flowData.Nodes.StartNode);
145 this.flowData.Nodes.ManualNode.forEach(item => {
146 item.activityState = this.flowState.filter( i => i.activityTemplateId == item.id)[0].activityState;
147 });
148 this.flowShow = true;
149 })
150 })
151 .catch((error) => {
152 vm.loadingHide();
153 });
154 })
155 .catch((error) => {
156 vm.loadingHide();
157 });
158 },
125 //获取当前点击节点名称 159 //获取当前点击节点名称
126 getCurNode(name){ 160 getCurNode(name){
127 console.log(name); 161 console.log(name);
......