Commit e9e73c402beeb8ac566ab8907e70e46ed883066c
1 parent
9bbeb93b
#返显高亮工作流
Showing
3 changed files
with
15 additions
and
3 deletions
yudao-admin-server/src/main/java/cn/iocoder/yudao/adminserver/modules/activiti/service/workflow/impl/TaskServiceImpl.java
| @@ -267,7 +267,6 @@ public class TaskServiceImpl implements TaskService { | @@ -267,7 +267,6 @@ public class TaskServiceImpl implements TaskService { | ||
| 267 | } | 267 | } |
| 268 | 268 | ||
| 269 | private void responseImage(HttpServletResponse response, InputStream inputStream, String picName) throws IOException { | 269 | private void responseImage(HttpServletResponse response, InputStream inputStream, String picName) throws IOException { |
| 270 | - BufferedImage src = ImageIO.read(inputStream); | ||
| 271 | response.setContentType("application/octet-stream;charset=UTF-8"); | 270 | response.setContentType("application/octet-stream;charset=UTF-8"); |
| 272 | response.setHeader("Content-Disposition", "attachment; filename=" + URLEncoder.encode(picName, "UTF-8")); | 271 | response.setHeader("Content-Disposition", "attachment; filename=" + URLEncoder.encode(picName, "UTF-8")); |
| 273 | byte[] b = new byte[1024]; | 272 | byte[] b = new byte[1024]; |
yudao-admin-ui/src/api/oa/todo.js
| @@ -81,3 +81,11 @@ export function processHistorySteps(id) { | @@ -81,3 +81,11 @@ export function processHistorySteps(id) { | ||
| 81 | method: 'get' | 81 | method: 'get' |
| 82 | }) | 82 | }) |
| 83 | } | 83 | } |
| 84 | + | ||
| 85 | + | ||
| 86 | +export function getHighlightImg(id) { | ||
| 87 | + return request({ | ||
| 88 | + url: '/workflow/task/process/highlight-img/'+id, | ||
| 89 | + method: 'get' | ||
| 90 | + }) | ||
| 91 | +} |
yudao-admin-ui/src/views/oa/leave/index.vue
| @@ -137,11 +137,12 @@ | @@ -137,11 +137,12 @@ | ||
| 137 | </div> | 137 | </div> |
| 138 | </el-dialog> | 138 | </el-dialog> |
| 139 | 139 | ||
| 140 | - <el-dialog :title="title" :visible.sync="dialogStepsVisible" width="600px" append-to-body> | 140 | + <el-dialog :title="title" :visible.sync="dialogStepsVisible" width="750px" append-to-body> |
| 141 | <el-steps :active="stepActive" finish-status="success" > | 141 | <el-steps :active="stepActive" finish-status="success" > |
| 142 | <el-step :title="stepTitle(item)" :description="stepAssignee(item.assignee)" icon="el-icon-edit" v-for="(item) in handleTask.historyTask"></el-step> | 142 | <el-step :title="stepTitle(item)" :description="stepAssignee(item.assignee)" icon="el-icon-edit" v-for="(item) in handleTask.historyTask"></el-step> |
| 143 | </el-steps> | 143 | </el-steps> |
| 144 | <br/> | 144 | <br/> |
| 145 | + <div v-html="svgUrl"></div> | ||
| 145 | <el-steps direction="vertical" :active="stepActive"> | 146 | <el-steps direction="vertical" :active="stepActive"> |
| 146 | <el-step :title="stepTitle(item)" :description="stepDes(item)" v-for="(item) in handleTask.historyTask"></el-step> | 147 | <el-step :title="stepTitle(item)" :description="stepDes(item)" v-for="(item) in handleTask.historyTask"></el-step> |
| 147 | </el-steps> | 148 | </el-steps> |
| @@ -156,7 +157,7 @@ | @@ -156,7 +157,7 @@ | ||
| 156 | <script> | 157 | <script> |
| 157 | import { createLeave, updateLeave, deleteLeave, getLeave, getLeavePage, exportLeaveExcel } from "@/api/oa/leave" | 158 | import { createLeave, updateLeave, deleteLeave, getLeave, getLeavePage, exportLeaveExcel } from "@/api/oa/leave" |
| 158 | import { getDictDataLabel, getDictDatas, DICT_TYPE } from '@/utils/dict' | 159 | import { getDictDataLabel, getDictDatas, DICT_TYPE } from '@/utils/dict' |
| 159 | -import { processHistorySteps } from '@/api/oa/todo' | 160 | +import { processHistorySteps,getHighlightImg } from '@/api/oa/todo' |
| 160 | export default { | 161 | export default { |
| 161 | name: "Leave", | 162 | name: "Leave", |
| 162 | components: { | 163 | components: { |
| @@ -194,6 +195,7 @@ export default { | @@ -194,6 +195,7 @@ export default { | ||
| 194 | }, | 195 | }, |
| 195 | // 表单参数 | 196 | // 表单参数 |
| 196 | form: {}, | 197 | form: {}, |
| 198 | + svgUrl: "", | ||
| 197 | handleTask: { | 199 | handleTask: { |
| 198 | historyTask:[], | 200 | historyTask:[], |
| 199 | taskVariable: "", | 201 | taskVariable: "", |
| @@ -361,6 +363,9 @@ export default { | @@ -361,6 +363,9 @@ export default { | ||
| 361 | this.handleTask.historyTask = response.data; | 363 | this.handleTask.historyTask = response.data; |
| 362 | this.dialogStepsVisible = true | 364 | this.dialogStepsVisible = true |
| 363 | this.title = "审批进度"; | 365 | this.title = "审批进度"; |
| 366 | + getHighlightImg(row.processInstanceId).then(response => { | ||
| 367 | + that.svgUrl = response | ||
| 368 | + }) | ||
| 364 | }); | 369 | }); |
| 365 | }, | 370 | }, |
| 366 | /** 导出按钮操作 */ | 371 | /** 导出按钮操作 */ |