Commit 315e50eb7b17ebf1cbd5135750a555b204b7ca8c
1 parent
9408fae7
m
Showing
15 changed files
with
185 additions
and
141 deletions
trash-activiti/src/main/java/com/trash/activiti/controller/TaskHistoryController.java
| ... | ... | @@ -39,27 +39,27 @@ public class TaskHistoryController extends BaseController { |
| 39 | 39 | PageDomain pageDomain = TableSupport.buildPageRequest(); |
| 40 | 40 | Page<ActTaskDTO> hashMaps = actTaskService.selectRuntimeTaskHistoryDefinitionList(pageDomain); |
| 41 | 41 | |
| 42 | - List<String> allNames = actReDeploymentMapper.selectTitles(null); | |
| 43 | - | |
| 44 | - List<ActTaskDTO> list = hashMaps.getResult(); | |
| 45 | - List<String> names = new ArrayList<String>(); | |
| 46 | - | |
| 47 | - for(String str:allNames){ | |
| 48 | - for(ActTaskDTO dto:hashMaps.getResult()){ | |
| 49 | - if(str.equals(dto.getInstanceName())){ | |
| 50 | - names.add(str); | |
| 51 | - } | |
| 52 | - } | |
| 53 | - } | |
| 42 | +// List<String> allNames = actReDeploymentMapper.selectTitles(null); | |
| 43 | +// | |
| 44 | +// List<ActTaskDTO> list = hashMaps.getResult(); | |
| 45 | +// List<String> names = new ArrayList<String>(); | |
| 46 | +// | |
| 47 | +// for(String str:allNames){ | |
| 48 | +// for(ActTaskDTO dto:hashMaps.getResult()){ | |
| 49 | +// if(str.equals(dto.getInstanceName())){ | |
| 50 | +// names.add(str); | |
| 51 | +// } | |
| 52 | +// } | |
| 53 | +// } | |
| 54 | 54 | TableDataInfo info = getDataTable(hashMaps); |
| 55 | 55 | |
| 56 | - if(list.size() > pageDomain.getPageNum() * pageDomain.getPageSize()){ | |
| 57 | - list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), pageDomain.getPageNum()* pageDomain.getPageSize()); | |
| 58 | - }else{ | |
| 59 | - list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), list.size()); | |
| 60 | - } | |
| 61 | - info.setRows(list); | |
| 62 | - info.setNames(names); | |
| 56 | +// if(list.size() > pageDomain.getPageNum() * pageDomain.getPageSize()){ | |
| 57 | +// list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), pageDomain.getPageNum()* pageDomain.getPageSize()); | |
| 58 | +// }else{ | |
| 59 | +// list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), list.size()); | |
| 60 | +// } | |
| 61 | +// info.setRows(list); | |
| 62 | +// info.setNames(names); | |
| 63 | 63 | |
| 64 | 64 | return info; |
| 65 | 65 | } |
| ... | ... | @@ -68,28 +68,28 @@ public class TaskHistoryController extends BaseController { |
| 68 | 68 | public TableDataInfo getEndTasks() { |
| 69 | 69 | PageDomain pageDomain = TableSupport.buildPageRequest(); |
| 70 | 70 | Page<ActTaskDTO> hashMaps = actTaskService.selectTaskEndHistoryDefinitionList(pageDomain); |
| 71 | - List<String> allNames = actReDeploymentMapper.selectHistTitles(null); | |
| 72 | - List<String> names = new ArrayList<String>(); | |
| 73 | - | |
| 74 | - List<ActTaskDTO> list = hashMaps.getResult(); | |
| 75 | - | |
| 76 | - for(String str:allNames){ | |
| 77 | - for(ActTaskDTO dto:hashMaps.getResult()){ | |
| 78 | - if(str.equals(dto.getInstanceName())){ | |
| 79 | - names.add(str); | |
| 80 | - } | |
| 81 | - } | |
| 82 | - } | |
| 71 | +// List<String> allNames = actReDeploymentMapper.selectHistTitles(null); | |
| 72 | +// List<String> names = new ArrayList<String>(); | |
| 73 | +// | |
| 74 | +// List<ActTaskDTO> list = hashMaps.getResult(); | |
| 75 | +// | |
| 76 | +// for(String str:allNames){ | |
| 77 | +// for(ActTaskDTO dto:hashMaps.getResult()){ | |
| 78 | +// if(str.equals(dto.getInstanceName())){ | |
| 79 | +// names.add(str); | |
| 80 | +// } | |
| 81 | +// } | |
| 82 | +// } | |
| 83 | 83 | |
| 84 | 84 | TableDataInfo info = getDataTable(hashMaps); |
| 85 | 85 | |
| 86 | - if(list.size() > pageDomain.getPageNum() * pageDomain.getPageSize()){ | |
| 87 | - list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), pageDomain.getPageNum()* pageDomain.getPageSize()); | |
| 88 | - }else{ | |
| 89 | - list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), list.size()); | |
| 90 | - } | |
| 91 | - info.setNames(names); | |
| 92 | - info.setRows(list); | |
| 86 | +// if(list.size() > pageDomain.getPageNum() * pageDomain.getPageSize()){ | |
| 87 | +// list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), pageDomain.getPageNum()* pageDomain.getPageSize()); | |
| 88 | +// }else{ | |
| 89 | +// list = list.subList((pageDomain.getPageNum()-1)* pageDomain.getPageSize(), list.size()); | |
| 90 | +// } | |
| 91 | +// info.setNames(names); | |
| 92 | +// info.setRows(list); | |
| 93 | 93 | |
| 94 | 94 | |
| 95 | 95 | return info; | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/service/impl/ActTaskServiceImpl.java
| ... | ... | @@ -33,6 +33,7 @@ import org.activiti.engine.RuntimeService; |
| 33 | 33 | import org.activiti.engine.TaskService; |
| 34 | 34 | import org.activiti.engine.history.HistoricProcessInstance; |
| 35 | 35 | import org.activiti.engine.history.HistoricProcessInstanceQuery; |
| 36 | +import org.activiti.engine.query.QueryProperty; | |
| 36 | 37 | import org.activiti.engine.runtime.ProcessInstance; |
| 37 | 38 | import org.activiti.engine.runtime.ProcessInstanceQuery; |
| 38 | 39 | import org.activiti.engine.task.IdentityLink; |
| ... | ... | @@ -158,29 +159,11 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 158 | 159 | |
| 159 | 160 | Set<String> processInstanceIdIds = tasks.parallelStream().map(t -> t.getProcessInstanceId()).collect(Collectors.toSet()); |
| 160 | 161 | |
| 161 | - ProcessInstanceQuery query = runtimeService.createProcessInstanceQuery(); | |
| 162 | + if(processInstanceIdIds.size() > 0){ | |
| 163 | + | |
| 162 | 164 | |
| 163 | - if(name != null && !name.isEmpty()){ | |
| 164 | - query.processInstanceNameLike(name); | |
| 165 | - } | |
| 166 | - if(keys.size()>0){ | |
| 167 | - query.processDefinitionKeys(keys); | |
| 168 | - } | |
| 169 | - | |
| 170 | - | |
| 171 | - List<ProcessInstance> processInstanceList = query.processInstanceIds(processInstanceIdIds).list(); | |
| 172 | - | |
| 173 | - | |
| 174 | - Set<String> idString = new HashSet<String>(); | |
| 175 | - for (ProcessInstance pi : processInstanceList) { | |
| 176 | - idString.add(pi.getBusinessKey()); | |
| 177 | - } | |
| 178 | - | |
| 179 | - if(idString.size() == 0){ | |
| 180 | - return list; | |
| 181 | - } | |
| 182 | - | |
| 183 | - List<Map<String, Object>> maps = actMapper.selectWorkByIds(idString); | |
| 165 | + | |
| 166 | + List<Map<String, Object>> maps = actMapper.selectWorkByIds(processInstanceIdIds); | |
| 184 | 167 | |
| 185 | 168 | |
| 186 | 169 | for(Map<String, Object> map:maps){ |
| ... | ... | @@ -196,6 +179,7 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 196 | 179 | e.printStackTrace(); |
| 197 | 180 | } |
| 198 | 181 | } |
| 182 | + } | |
| 199 | 183 | } |
| 200 | 184 | |
| 201 | 185 | if(prev != null){ |
| ... | ... | @@ -217,6 +201,10 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 217 | 201 | |
| 218 | 202 | @Override |
| 219 | 203 | public Page<ActTaskDTO> selectTaskEndHistoryDefinitionList(PageDomain pageDomain) { |
| 204 | + | |
| 205 | + int pageNum = pageDomain.getPageNum(); | |
| 206 | + int pageSize = pageDomain.getPageSize(); | |
| 207 | + | |
| 220 | 208 | Page<ActTaskDTO> list = new Page<ActTaskDTO>(); |
| 221 | 209 | |
| 222 | 210 | ProcessEngine pes = ProcessEngines.getDefaultProcessEngine(); |
| ... | ... | @@ -240,14 +228,25 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 240 | 228 | |
| 241 | 229 | |
| 242 | 230 | List<HistoricProcessInstance> processInstanceList; |
| 243 | - HistoricProcessInstanceQuery query = historyService.createHistoricProcessInstanceQuery().involvedUser(username); | |
| 231 | + HistoricProcessInstanceQuery query = historyService.createHistoricProcessInstanceQuery().involvedUser(username).orderByProcessInstanceStartTime().desc(); | |
| 244 | 232 | |
| 245 | 233 | if(name != null) |
| 246 | - query.processInstanceNameLike(name); | |
| 247 | - | |
| 234 | + query.processInstanceNameLike("%"+name+"%"); | |
| 235 | + | |
| 236 | + if(type != null && !type.isEmpty()){ | |
| 237 | + List<String> types = new ArrayList<String>(); | |
| 238 | + for(String string :type.split(",")){ | |
| 239 | + types.add(string); | |
| 240 | + } | |
| 241 | + query.processDefinitionKeyIn(types); | |
| 242 | + } | |
| 243 | + | |
| 244 | + | |
| 245 | + list.setTotal(query.count()); | |
| 246 | + | |
| 247 | + processInstanceList = query.listPage((pageNum-1) * pageSize,pageSize); | |
| 248 | 248 | |
| 249 | 249 | |
| 250 | - processInstanceList = query.list(); | |
| 251 | 250 | |
| 252 | 251 | // List<ActWorkflowFormData> dataList = actWorkflowFormDataMapper.selectActWorkFlowFormDataListByUser(username); |
| 253 | 252 | |
| ... | ... | @@ -265,11 +264,7 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 265 | 264 | ActTaskDTO dto = new ActTaskDTO(p, |
| 266 | 265 | maps.parallelStream().filter(pi -> p.getId().equals(pi.get("instance_id"))).findAny().get()); |
| 267 | 266 | |
| 268 | - | |
| 269 | - if(type != null && !type.isEmpty() && !type.contains(dto.getDefinitionKey())){ | |
| 270 | - continue; | |
| 271 | - } | |
| 272 | - | |
| 267 | + | |
| 273 | 268 | |
| 274 | 269 | list.add(dto);} |
| 275 | 270 | catch (Exception e) { |
| ... | ... | @@ -280,19 +275,18 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 280 | 275 | |
| 281 | 276 | } |
| 282 | 277 | |
| 283 | - list.sort(new Comparator<ActTaskDTO>() { | |
| 284 | - | |
| 285 | - @Override | |
| 286 | - public int compare(ActTaskDTO o1, ActTaskDTO o2) { | |
| 287 | - // TODO Auto-generated method stub | |
| 288 | - return (int) (o2.getCreatedDate().getTime() - o1.getCreatedDate().getTime()); | |
| 289 | - } | |
| 290 | - }); | |
| 291 | - | |
| 292 | - list.setPageNum(pageDomain.getPageNum()); | |
| 293 | - list.setPageSize(pageDomain.getPageSize()); | |
| 278 | +// list.sort(new Comparator<ActTaskDTO>() { | |
| 279 | +// | |
| 280 | +// @Override | |
| 281 | +// public int compare(ActTaskDTO o1, ActTaskDTO o2) { | |
| 282 | +// // TODO Auto-generated method stub | |
| 283 | +// return (int) (o2.getCreatedDate().getTime() - o1.getCreatedDate().getTime()); | |
| 284 | +// } | |
| 285 | +// }); | |
| 286 | +// | |
| 287 | +// list.setPageNum(pageDomain.getPageNum()); | |
| 288 | +// list.setPageSize(pageDomain.getPageSize()); | |
| 294 | 289 | |
| 295 | - list.setTotal(list.size()); | |
| 296 | 290 | |
| 297 | 291 | return list; |
| 298 | 292 | } |
| ... | ... | @@ -301,6 +295,8 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 301 | 295 | public Page<ActTaskDTO> selectRuntimeTaskHistoryDefinitionList(PageDomain pageDomain) { |
| 302 | 296 | Page<ActTaskDTO> list = new Page<ActTaskDTO>(); |
| 303 | 297 | |
| 298 | + int pageNum = pageDomain.getPageNum(); | |
| 299 | + int pageSize = pageDomain.getPageSize(); | |
| 304 | 300 | String username = securityManager.getAuthenticatedUserId(); |
| 305 | 301 | |
| 306 | 302 | Map map = new HashedMap<>(); |
| ... | ... | @@ -316,7 +312,25 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 316 | 312 | } |
| 317 | 313 | |
| 318 | 314 | |
| 319 | - List<ProcessInstance> processInstanceList = runtimeService.createProcessInstanceQuery().involvedUser(username).list(); | |
| 315 | + ProcessInstanceQuery query = runtimeService.createProcessInstanceQuery().involvedUser(username); | |
| 316 | + | |
| 317 | + | |
| 318 | + if(name != null) | |
| 319 | + query.processInstanceNameLike("%"+name+"%"); | |
| 320 | + | |
| 321 | + if(type != null && !type.isEmpty()){ | |
| 322 | + Set<String> types = new HashSet<String>(); | |
| 323 | + for(String string :type.split(",")){ | |
| 324 | + types.add(string); | |
| 325 | + } | |
| 326 | + query.processDefinitionKeys(types); | |
| 327 | + } | |
| 328 | + | |
| 329 | + List<ProcessInstance> processInstanceList = query.list(); | |
| 330 | + | |
| 331 | + list.setTotal(query.count()); | |
| 332 | + | |
| 333 | + processInstanceList = query.listPage((pageNum-1) * pageSize,pageSize); | |
| 320 | 334 | |
| 321 | 335 | if (processInstanceList.size() > 0) { |
| 322 | 336 | |
| ... | ... | @@ -338,10 +352,6 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 338 | 352 | dataList.parallelStream().filter(pi -> p.getBusinessKey().equals(pi.getBusinessKey())).findAny().get()); |
| 339 | 353 | |
| 340 | 354 | |
| 341 | - if(type != null && !type.isEmpty() && !type.contains(dto.getDefinitionKey())){ | |
| 342 | - continue; | |
| 343 | - } | |
| 344 | - | |
| 345 | 355 | list.add(dto); |
| 346 | 356 | } catch (Exception e) { |
| 347 | 357 | // TODO: handle exception |
| ... | ... | @@ -350,19 +360,7 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 350 | 360 | |
| 351 | 361 | } |
| 352 | 362 | } |
| 353 | - list.sort(new Comparator<ActTaskDTO>() { | |
| 354 | - | |
| 355 | - @Override | |
| 356 | - public int compare(ActTaskDTO o1, ActTaskDTO o2) { | |
| 357 | - // TODO Auto-generated method stub | |
| 358 | - return (int) (o2.getCreatedDate().getTime() - o1.getCreatedDate().getTime()); | |
| 359 | - } | |
| 360 | - }); | |
| 361 | 363 | |
| 362 | - list.setPageNum(pageDomain.getPageNum()); | |
| 363 | - list.setPageSize(pageDomain.getPageSize()); | |
| 364 | - | |
| 365 | - list.setTotal(list.size()); | |
| 366 | 364 | return list; |
| 367 | 365 | } |
| 368 | 366 | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/service/impl/FormHistoryDataServiceImpl.java
| ... | ... | @@ -43,7 +43,18 @@ public class FormHistoryDataServiceImpl implements IFormHistoryDataService { |
| 43 | 43 | public List<ActWorkflowFormData> historyDataShow(String businessKey) { |
| 44 | 44 | List<ActWorkflowFormData> returnHistoryFromDataDTOS=new ArrayList<>(); |
| 45 | 45 | |
| 46 | - List<Task> tasks =taskService.createTaskQuery().processInstanceBusinessKey(businessKey).list(); | |
| 46 | + List<Task> tasks = null; | |
| 47 | + | |
| 48 | + if(businessKey.contains("constructsite")){ | |
| 49 | + String id = businessKey.split(":")[1]; | |
| 50 | + tasks =taskService.createTaskQuery().processInstanceBusinessKey("workflow_constructsite_edit:" + id).list(); | |
| 51 | + tasks.addAll(taskService.createTaskQuery().processInstanceBusinessKey("workflow_constructsite:" + id).list()); | |
| 52 | + }else{ | |
| 53 | + | |
| 54 | + tasks =taskService.createTaskQuery().processInstanceBusinessKey(businessKey).list(); | |
| 55 | + } | |
| 56 | + | |
| 57 | + | |
| 47 | 58 | |
| 48 | 59 | if(tasks.size() > 0){ |
| 49 | 60 | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/service/impl/myTaskServiceImpl.java
| ... | ... | @@ -169,10 +169,7 @@ public class myTaskServiceImpl implements myTaskService { |
| 169 | 169 | ProcessInstanceQuery query = runtimeService.createProcessInstanceQuery(); |
| 170 | 170 | |
| 171 | 171 | if(name != null && !name.isEmpty()){ |
| 172 | - query.processInstanceNameLike(name); | |
| 173 | - | |
| 174 | - List<ProcessInstance> pList = query.list(); | |
| 175 | - | |
| 172 | + query.processInstanceNameLike("%"+name+"%"); | |
| 176 | 173 | } |
| 177 | 174 | if(defKey.size()>0){ |
| 178 | 175 | query.processDefinitionKeys(defKey); | ... | ... |
trash-activiti/src/main/resources/mapper/activiti/ActReDeploymentMapper.xml
| ... | ... | @@ -24,7 +24,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 24 | 24 | </select> |
| 25 | 25 | |
| 26 | 26 | <select id="selectWorkByIds" parameterType="String" resultType="java.util.Map"> |
| 27 | - select id,title,start_time as startTime,end_time as endTime, reason,type,instance_id,create_time as createTime,create_by,state from workflow where id in | |
| 27 | + select id,title,start_time as startTime,end_time as endTime, reason,type,instance_id,create_time as createTime,create_by,state from workflow where instance_id in | |
| 28 | 28 | <foreach item="id" collection="ids" open="(" separator="," close=")"> |
| 29 | 29 | #{id} |
| 30 | 30 | </foreach> | ... | ... |
trash-admin/src/main/resources/application-dev.yml
| ... | ... | @@ -33,7 +33,7 @@ spring: |
| 33 | 33 | # 主库数据源 |
| 34 | 34 | master: |
| 35 | 35 | #url: jdbc:mysql://localhost:3306/trash?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true |
| 36 | - url: jdbc:mysql://192.168.168.141:3306/trash1?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true | |
| 36 | + url: jdbc:mysql://192.168.168.141:3306/trash?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true | |
| 37 | 37 | username: root |
| 38 | 38 | password: root |
| 39 | 39 | # 从库数据源 | ... | ... |
trash-ui/dist.rar
No preview for this file type
trash-ui/src/api/dict.js
| ... | ... | @@ -59,6 +59,23 @@ export function earthsitesList(data) { |
| 59 | 59 | data: data |
| 60 | 60 | }); |
| 61 | 61 | } |
| 62 | + | |
| 63 | +export function constructionsitesLedgerList(data) { | |
| 64 | + return requestRemote({ | |
| 65 | + url: '/api/siteservice/cs/constructionsites/ledger/list', | |
| 66 | + method: 'post', | |
| 67 | + data: data | |
| 68 | + }); | |
| 69 | +} | |
| 70 | + | |
| 71 | +export function earthsitesLedgerList(data) { | |
| 72 | + return requestRemote({ | |
| 73 | + url: '/api/siteservice/cs/earthsites/ledger/list', | |
| 74 | + method: 'post', | |
| 75 | + data: data | |
| 76 | + }); | |
| 77 | +} | |
| 78 | + | |
| 62 | 79 | export function updateEarthsites(data) { |
| 63 | 80 | return requestRemote({ |
| 64 | 81 | url: '/api/siteservice/cs/earthsites/status', | ... | ... |
trash-ui/src/api/three_step.js
| ... | ... | @@ -21,8 +21,8 @@ import { |
| 21 | 21 | } from "@/utils/auth"; |
| 22 | 22 | |
| 23 | 23 | import { |
| 24 | - earthsitesList, | |
| 25 | - constructionsitesList, | |
| 24 | + earthsitesLedgerList, | |
| 25 | + constructionsitesLedgerList, | |
| 26 | 26 | getDict, |
| 27 | 27 | getArea, |
| 28 | 28 | truckList, |
| ... | ... | @@ -291,9 +291,13 @@ export default { |
| 291 | 291 | if(this.form.type){ |
| 292 | 292 | if (this.form.type == "0") { |
| 293 | 293 | if(this.remoteQueryData.areaCode) |
| 294 | - this.remoteQueryData.areaCode = this.remoteQueryData.areaCode + ""; | |
| 294 | + this.remoteQueryData.areaCode = this.remoteQueryData.areaCode + ""; | |
| 295 | 295 | |
| 296 | - constructionsitesList(this.remoteQueryData).then(res => { | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + this.remoteQueryData.limitStatus = 0; | |
| 300 | + constructionsitesLedgerList(this.remoteQueryData).then(res => { | |
| 297 | 301 | for(let i in res.result.list){ |
| 298 | 302 | this.remoteData.push(res.result.list[i]); |
| 299 | 303 | |
| ... | ... | @@ -314,7 +318,10 @@ export default { |
| 314 | 318 | } else { |
| 315 | 319 | if(this.remoteQueryData.areaCode) |
| 316 | 320 | this.remoteQueryData.areaCode = [this.remoteQueryData.areaCode+""]; |
| 317 | - earthsitesList(this.remoteQueryData).then(res => { | |
| 321 | + | |
| 322 | + | |
| 323 | + this.remoteQueryData.overdue = 0; | |
| 324 | + earthsitesLedgerList(this.remoteQueryData).then(res => { | |
| 318 | 325 | for(let i in res.result.list){ |
| 319 | 326 | this.remoteData.push(res.result.list[i]); |
| 320 | 327 | if(res.result.list[i].name == this.form.name){ | ... | ... |
trash-ui/src/views/activiti/task/index.vue
| ... | ... | @@ -11,10 +11,11 @@ |
| 11 | 11 | </el-option> |
| 12 | 12 | </el-select> |
| 13 | 13 | |
| 14 | - <el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> | |
| 14 | + <el-input v-model="queryParams.name" placeholder="名称" style="width:200px;"></el-input> | |
| 15 | + <!-- <el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> | |
| 15 | 16 | <el-option v-for="item in names" :label="item" :value="item"> |
| 16 | 17 | </el-option> |
| 17 | - </el-select> | |
| 18 | + </el-select> --> | |
| 18 | 19 | |
| 19 | 20 | <el-select v-model="queryParams.prev" filterable reserve-keyword placeholder="上一节点"> |
| 20 | 21 | <el-option v-for="item in prev" :label="item.name" :value="item.name"> |
| ... | ... | @@ -784,8 +785,6 @@ |
| 784 | 785 | }; |
| 785 | 786 | }, |
| 786 | 787 | created() { |
| 787 | - console.log(this); | |
| 788 | - console.log(this.$refs["form"]); | |
| 789 | 788 | let dep = {type: "CSUserDepartmentType"}; |
| 790 | 789 | |
| 791 | 790 | getDict(dep).then(res => { | ... | ... |
trash-ui/src/views/activiti/task/taskCard.vue
| ... | ... | @@ -4,28 +4,28 @@ |
| 4 | 4 | :class="{card_status:true,notcheck:!task.checkStatus,dismiss:task.checkStatus=='2',agree:task.checkStatus=='1'}"> |
| 5 | 5 | {{task.checkStatus? task.checkStatus=="1"?"已同意":"已拒绝" : "待审批"}}</div> |
| 6 | 6 | <el-row class="card_row"> |
| 7 | - <el-col :span="20" class="card_grid"> | |
| 7 | + <el-col :span="20" > | |
| 8 | 8 | <div class="card_title">{{task.instanceName}}</div> |
| 9 | 9 | </el-col> |
| 10 | - <el-col :span="4" class="card_grid"> | |
| 10 | + <el-col :span="4" > | |
| 11 | 11 | <a @click="sendToParent(task)" style="float: right;">详情>></a> |
| 12 | 12 | </el-col> |
| 13 | 13 | </el-row> |
| 14 | 14 | |
| 15 | - <el-row class="card_row" v-if="task.checkStatus == 0"> | |
| 16 | - <el-col :span="8" class="card_grid"> | |
| 15 | + <el-row class="card_row" v-if="!task.checkStatus"> | |
| 16 | + <el-col :span="8" > | |
| 17 | 17 | <div >上一节点: {{task.prev}}</div> |
| 18 | 18 | </el-col> |
| 19 | - <el-col :span="8" class="card_grid" v-if="task.name"> | |
| 19 | + <el-col :span="8" v-if="task.name"> | |
| 20 | 20 | <div >当前节点: {{task.name}}</div> |
| 21 | 21 | </el-col> |
| 22 | - <el-col :span="8" class="card_grid"> | |
| 22 | + <el-col :span="8" > | |
| 23 | 23 | <div >下一节点: {{task.next}}</div> |
| 24 | 24 | </el-col> |
| 25 | 25 | </el-row> |
| 26 | 26 | |
| 27 | 27 | <el-row class="card_row"> |
| 28 | - <el-col :span="12" class="card_grid"> | |
| 28 | + <el-col :span="12" > | |
| 29 | 29 | <div>申请类型: {{task.type}}</div> |
| 30 | 30 | </el-col> |
| 31 | 31 | <el-col :span="12" class="card_grid right"> | ... | ... |
trash-ui/src/views/activiti/taskhistory/index.vue
| 1 | 1 | <template> |
| 2 | 2 | <div class="app-container"> |
| 3 | + | |
| 4 | + <!-- <el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> | |
| 5 | + <el-option v-for="item in names" :label="item" :value="item"> | |
| 6 | + </el-option> | |
| 7 | + </el-select> --> | |
| 8 | + | |
| 9 | + <el-input v-model="queryParams.name" placeholder="名称" style="width:200px;"></el-input> | |
| 10 | +<!-- | |
| 3 | 11 | <el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> |
| 4 | 12 | <el-option v-for="item in names" :label="item" :value="item"> |
| 5 | 13 | </el-option> |
| 6 | - </el-select> | |
| 14 | + </el-select> --> | |
| 7 | 15 | |
| 8 | 16 | <el-select v-model="queryParams.type" filterable reserve-keyword> |
| 9 | 17 | <el-option label="建筑垃圾许可证审批" value="workflow_constructsite"/> | ... | ... |
trash-ui/src/views/h5/task/index.vue
| ... | ... | @@ -10,10 +10,8 @@ |
| 10 | 10 | :value="item.code" :key="item.code"> |
| 11 | 11 | </el-option> |
| 12 | 12 | </el-select> |
| 13 | -<el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> | |
| 14 | - <el-option v-for="item in names" :label="item" :value="item"> | |
| 15 | - </el-option> | |
| 16 | - </el-select> | |
| 13 | + | |
| 14 | + <el-input v-model="queryParams.name" placeholder="名称" style="width:200px;"></el-input> | |
| 17 | 15 | |
| 18 | 16 | <el-select v-model="queryParams.prev" filterable reserve-keyword placeholder="上一节点"> |
| 19 | 17 | <el-option v-for="item in prev" :label="item.name" :value="item.name"> |
| ... | ... | @@ -781,7 +779,7 @@ export default { |
| 781 | 779 | options: [], |
| 782 | 780 | usersName: [], |
| 783 | 781 | deptName:null, |
| 784 | - | |
| 782 | + prev:[], | |
| 785 | 783 | slides: [], |
| 786 | 784 | slidesArys: [], |
| 787 | 785 | videos:[], |
| ... | ... | @@ -797,18 +795,29 @@ export default { |
| 797 | 795 | }; |
| 798 | 796 | }, |
| 799 | 797 | created() { |
| 800 | - let dep = {type: "CSUserDepartmentType"}; | |
| 798 | + let dep = {type: "CSUserDepartmentType"}; | |
| 799 | + | |
| 800 | + getDict(dep).then(res => { | |
| 801 | + this.depts = res.result; | |
| 802 | + for(let i in res.result){ | |
| 803 | + if(res.result[i].name.indexOf("渣土办") < 1){ | |
| 804 | + this.prev.push(res.result[i]); | |
| 805 | + } | |
| 806 | + } | |
| 807 | + }); | |
| 801 | 808 | |
| 802 | - getDict(dep).then(res => { | |
| 803 | - this.depts = res.result; | |
| 804 | - }); | |
| 809 | + let role = {type: "CSUserPostType"}; | |
| 805 | 810 | |
| 806 | - let role = {type: "CSUserPostType"}; | |
| 811 | + getDict(role).then(res => { | |
| 812 | + this.roles = res.result; | |
| 813 | + }); | |
| 807 | 814 | |
| 808 | - getDict(role).then(res => { | |
| 809 | - this.roles = res.result; | |
| 810 | - }); | |
| 811 | - this.getList(); | |
| 815 | + listTask(this.queryParams).then(response => { | |
| 816 | + this.taskList = response.rows; | |
| 817 | + this.names = response.names; | |
| 818 | + this.total = response.total; | |
| 819 | + this.loading = false; | |
| 820 | + }); | |
| 812 | 821 | }, |
| 813 | 822 | methods: { |
| 814 | 823 | }, | ... | ... |
trash-ui/src/views/h5/task/taskCard.vue
| ... | ... | @@ -6,7 +6,7 @@ |
| 6 | 6 | <el-row class="card_row"> |
| 7 | 7 | <div class="card_title">{{task.instanceName}}</div> |
| 8 | 8 | </el-row> |
| 9 | - <el-row class="card_row" v-if="task.checkStatus == 0"> | |
| 9 | + <el-row class="card_row" v-if="!task.checkStatus"> | |
| 10 | 10 | <el-col :span="24" class="card_grid"> |
| 11 | 11 | <div >上一节点: {{task.prev}}</div> |
| 12 | 12 | </el-col> | ... | ... |
trash-ui/src/views/h5/taskhistory/index.vue
| 1 | 1 | <template> |
| 2 | 2 | <div class="app-container"> |
| 3 | - <el-select v-model="queryParams.name" filterable reserve-keyword :filter-method="remoteName" placeholder="名称"> | |
| 4 | - <el-option v-for="item in names" :label="item" :value="item"> | |
| 5 | - </el-option> | |
| 6 | - </el-select> | |
| 3 | + | |
| 4 | + <el-input v-model="queryParams.name" placeholder="名称" style="width:200px;"></el-input> | |
| 7 | 5 | |
| 8 | 6 | <el-select v-model="queryParams.type" filterable reserve-keyword> |
| 9 | 7 | <el-option label="建筑垃圾许可证审批" value="workflow_constructsite"/> | ... | ... |