Commit abc8563264f9446808cb1a71eef7da04bca1adfd
1 parent
9c06308f
m
Showing
54 changed files
with
1542 additions
and
834 deletions
trash-activiti/src/main/java/com/trash/activiti/controller/TaskController.java
| ... | ... | @@ -21,6 +21,7 @@ import org.springframework.web.bind.annotation.*; |
| 21 | 21 | import java.text.ParseException; |
| 22 | 22 | import java.util.ArrayList; |
| 23 | 23 | import java.util.List; |
| 24 | +import java.util.Map; | |
| 24 | 25 | |
| 25 | 26 | |
| 26 | 27 | @RestController |
| ... | ... | @@ -41,7 +42,7 @@ public class TaskController extends BaseController { |
| 41 | 42 | PageDomain pageDomain = TableSupport.buildPageRequest(); |
| 42 | 43 | Page<ActTaskDTO> hashMaps = actTaskService.selectProcessDefinitionList(pageDomain); |
| 43 | 44 | |
| 44 | - List<String> allNames = actReDeploymentMapper.selectTitles(); | |
| 45 | + List<String> allNames = actReDeploymentMapper.selectTitles(null); | |
| 45 | 46 | List<String> names = new ArrayList<String>(); |
| 46 | 47 | |
| 47 | 48 | for(String str:allNames){ |
| ... | ... | @@ -77,6 +78,14 @@ public class TaskController extends BaseController { |
| 77 | 78 | public String taskHistory() { |
| 78 | 79 | return "taskHistory"; |
| 79 | 80 | } |
| 81 | + | |
| 82 | + | |
| 83 | + @PostMapping(value = "/getNames") | |
| 84 | + public AjaxResult getNames(@RequestBody Map<String,String> map){ | |
| 85 | + String name=map.get("name"); | |
| 86 | + | |
| 87 | + return AjaxResult.success(actReDeploymentMapper.selectTitles(name)); | |
| 88 | + } | |
| 80 | 89 | |
| 81 | 90 | |
| 82 | 91 | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/controller/TaskHistoryController.java
| ... | ... | @@ -39,7 +39,7 @@ 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(); | |
| 42 | + List<String> allNames = actReDeploymentMapper.selectTitles(null); | |
| 43 | 43 | |
| 44 | 44 | List<ActTaskDTO> list = hashMaps.getResult(); |
| 45 | 45 | List<String> names = new ArrayList<String>(); |
| ... | ... | @@ -68,7 +68,7 @@ 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(); | |
| 71 | + List<String> allNames = actReDeploymentMapper.selectHistTitles(null); | |
| 72 | 72 | List<String> names = new ArrayList<String>(); |
| 73 | 73 | |
| 74 | 74 | List<ActTaskDTO> list = hashMaps.getResult(); | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/domain/dto/ActTaskDTO.java
| ... | ... | @@ -8,8 +8,10 @@ import com.trash.common.utils.spring.SpringUtils; |
| 8 | 8 | |
| 9 | 9 | import org.activiti.api.task.model.Task; |
| 10 | 10 | import org.activiti.bpmn.model.BpmnModel; |
| 11 | +import org.activiti.bpmn.model.EndEvent; | |
| 11 | 12 | import org.activiti.bpmn.model.FlowElement; |
| 12 | 13 | import org.activiti.bpmn.model.FlowNode; |
| 14 | +import org.activiti.bpmn.model.FormProperty; | |
| 13 | 15 | import org.activiti.bpmn.model.Gateway; |
| 14 | 16 | import org.activiti.bpmn.model.SequenceFlow; |
| 15 | 17 | import org.activiti.bpmn.model.StartEvent; |
| ... | ... | @@ -145,7 +147,7 @@ public class ActTaskDTO |
| 145 | 147 | |
| 146 | 148 | Map<String, Object> params= cache.getCacheMap(exeId); |
| 147 | 149 | |
| 148 | - if(params == null){ | |
| 150 | + if(params == null || params.size() == 0){ | |
| 149 | 151 | params= SpringUtils.getBean(RuntimeService.class).getVariables(exeId); |
| 150 | 152 | cache.setCacheMap(exeId, params); |
| 151 | 153 | } |
| ... | ... | @@ -181,53 +183,19 @@ public class ActTaskDTO |
| 181 | 183 | BpmnModel model = SpringUtils.getBean(RepositoryService.class).getBpmnModel(task.getProcessDefinitionId()); |
| 182 | 184 | List<org.activiti.bpmn.model.Process> processes = model.getProcesses(); |
| 183 | 185 | |
| 184 | - List<String> modelList = new ArrayList<String>(); | |
| 185 | - | |
| 186 | + List<String> modelList = null; | |
| 186 | 187 | |
| 187 | 188 | for(org.activiti.bpmn.model.Process p:processes){ |
| 188 | 189 | Collection<FlowElement> flows = p.getFlowElements(); |
| 189 | 190 | |
| 190 | 191 | for(FlowElement f:flows){ |
| 191 | - | |
| 192 | - if(f instanceof org.activiti.bpmn.model.UserTask){ | |
| 192 | + if(f instanceof StartEvent){ | |
| 193 | + | |
| 193 | 194 | |
| 194 | - List<SequenceFlow> flowList = ((org.activiti.bpmn.model.UserTask) f).getIncomingFlows(); | |
| 195 | + modelList = getRouteList((StartEvent)f,route,index); | |
| 195 | 196 | |
| 196 | - for(SequenceFlow sec:flowList){ | |
| 197 | - if(route != null && sec.getConditionExpression() != null){ | |
| 198 | - if(sec.getConditionExpression().contains("route") && !sec.getConditionExpression().contains("route==" + route)){ | |
| 199 | - continue; | |
| 200 | - } | |
| 201 | - } | |
| 202 | - if(index != null && sec.getConditionExpression() != null){ | |
| 203 | - if(sec.getConditionExpression().contains("index") && !sec.getConditionExpression().contains("index==" + index)){ | |
| 204 | - continue; | |
| 205 | - } | |
| 206 | - } | |
| 207 | - | |
| 208 | - if(sec.getConditionExpression() != null){ | |
| 209 | - String[] condis = sec.getConditionExpression().split("&&"); | |
| 210 | - | |
| 211 | - if(condis.length == 0 && condis[0].contains("==1")){ | |
| 212 | - continue; | |
| 213 | - } | |
| 214 | - | |
| 215 | - for(String cond:condis){ | |
| 216 | - if(cond.contains("index") || cond.contains("route")){ | |
| 217 | - continue; | |
| 218 | - } | |
| 219 | - | |
| 220 | - if(cond.contains("==1")){ | |
| 221 | - continue; | |
| 222 | - } | |
| 223 | - modelList.add(f.getName()); | |
| 224 | - } | |
| 225 | - }else{ | |
| 226 | - | |
| 227 | - modelList.add(f.getName()); | |
| 228 | - } | |
| 229 | - } | |
| 230 | 197 | |
| 198 | + break; | |
| 231 | 199 | |
| 232 | 200 | } |
| 233 | 201 | |
| ... | ... | @@ -244,110 +212,119 @@ public class ActTaskDTO |
| 244 | 212 | this.next = modelList.get(modelList.indexOf(task.getName())+1); |
| 245 | 213 | } |
| 246 | 214 | |
| 247 | -// | |
| 248 | -// | |
| 215 | + } | |
| 249 | 216 | |
| 250 | -// | |
| 251 | -// FlowNode node = (FlowNode) model.getFlowElement(task.getFormKey()); | |
| 252 | -// | |
| 253 | -// List<SequenceFlow> list = node.getIncomingFlows(); | |
| 254 | -// | |
| 255 | -// for(SequenceFlow sec:list){ | |
| 256 | -// FlowNode flow = (FlowNode) model.getMainProcess().getFlowElement(sec.getSourceRef()); | |
| 257 | -// if (flow instanceof StartEvent) { | |
| 258 | -// this.setPrev(null); | |
| 259 | -// break; | |
| 260 | -// }else if(flow instanceof Gateway) { | |
| 261 | -//// for(SequenceFlow ssf:flow.getIncomingFlows()){ | |
| 262 | -// if(route != null && sec.getConditionExpression() != null){ | |
| 263 | -// if(sec.getConditionExpression().contains("route") && !sec.getConditionExpression().contains("route==" + route)){ | |
| 264 | -// continue; | |
| 265 | -// } | |
| 266 | -// } | |
| 267 | -// if(index != null && sec.getConditionExpression() != null){ | |
| 268 | -// if(sec.getConditionExpression().contains("index") && !sec.getConditionExpression().contains("index==" + index)){ | |
| 269 | -// continue; | |
| 270 | -// } | |
| 271 | -// } | |
| 272 | -// | |
| 273 | -// if(sec.getConditionExpression() != null){ | |
| 274 | -// String[] condis = sec.getConditionExpression().split("&&"); | |
| 275 | -// | |
| 276 | -// if(condis.length == 0 && condis[0].contains("==1")){ | |
| 277 | -// continue; | |
| 278 | -// } | |
| 279 | -// | |
| 280 | -// for(String cond:condis){ | |
| 281 | -// if(cond.contains("index") || cond.contains("route")){ | |
| 282 | -// continue; | |
| 283 | -// } | |
| 284 | -// | |
| 285 | -// if(cond.contains("==1")){ | |
| 286 | -// continue; | |
| 287 | -// } | |
| 288 | -// for(SequenceFlow ssf:flow.getIncomingFlows()){ | |
| 289 | -// if(ssf.getSourceFlowElement().getName() == null) | |
| 290 | -// continue; | |
| 291 | -// this.setPrev(ssf.getSourceFlowElement().getName()); | |
| 292 | -// break; | |
| 293 | -// } | |
| 294 | -// | |
| 295 | -// | |
| 296 | -// } | |
| 297 | -// } | |
| 298 | -// } | |
| 299 | -// } | |
| 300 | -// | |
| 301 | -// List<SequenceFlow> list1 = node.getOutgoingFlows(); | |
| 302 | -// | |
| 303 | -// for(SequenceFlow sec:list1){ | |
| 304 | -// | |
| 305 | -// FlowNode flow = (FlowNode) model.getMainProcess().getFlowElement(sec.getTargetRef()); | |
| 306 | -// | |
| 307 | -// if (flow instanceof StartEvent) { | |
| 308 | -// break; | |
| 309 | -// }else if(flow instanceof Gateway) { | |
| 310 | -// for(SequenceFlow ssf:flow.getOutgoingFlows()){ | |
| 311 | -// if(route != null && ssf.getConditionExpression() != null){ | |
| 312 | -// if(ssf.getConditionExpression().contains("route") && !ssf.getConditionExpression().contains("route==" + route)){ | |
| 313 | -// continue; | |
| 314 | -// } | |
| 217 | + | |
| 218 | + | |
| 219 | + private List<String> getRouteList(StartEvent f, String route, String index) { | |
| 220 | + | |
| 221 | + List<String> modelList = new ArrayList<String>(); | |
| 222 | + | |
| 223 | + SequenceFlow firstFlow = f.getOutgoingFlows().get(0); | |
| 224 | + FlowElement firstElement = firstFlow.getTargetFlowElement(); | |
| 225 | + if(firstElement instanceof Gateway){ | |
| 226 | + | |
| 227 | + getTrueRoute(firstElement,route,index,modelList); | |
| 228 | + | |
| 229 | + }else if(firstElement instanceof UserTask){ | |
| 230 | + modelList.add(firstElement.getName()); | |
| 231 | + | |
| 232 | + getTrueRoute(firstElement,route,index,modelList); | |
| 233 | + } | |
| 234 | + | |
| 235 | +// if(f instanceof org.activiti.bpmn.model.UserTask){ | |
| 236 | +// | |
| 237 | +// List<SequenceFlow> flowList = ((org.activiti.bpmn.model.UserTask) f).getIncomingFlows(); | |
| 238 | +// | |
| 239 | +// for(SequenceFlow sec:flowList){ | |
| 240 | +// if(route != null && sec.getConditionExpression() != null){ | |
| 241 | +// if(sec.getConditionExpression().contains("route") && !sec.getConditionExpression().contains("route==" + route)){ | |
| 242 | +// continue; | |
| 315 | 243 | // } |
| 316 | -// if(index != null && ssf.getConditionExpression() != null){ | |
| 317 | -// if(ssf.getConditionExpression().contains("index") && !ssf.getConditionExpression().contains("index==" + index)){ | |
| 318 | -// continue; | |
| 319 | -// } | |
| 244 | +// } | |
| 245 | +// if(index != null && sec.getConditionExpression() != null){ | |
| 246 | +// if(sec.getConditionExpression().contains("index") && !sec.getConditionExpression().contains("index==" + index)){ | |
| 247 | +// continue; | |
| 320 | 248 | // } |
| 249 | +// } | |
| 250 | +// | |
| 251 | +// if(sec.getConditionExpression() != null){ | |
| 252 | +// String[] condis = sec.getConditionExpression().split("&&"); | |
| 321 | 253 | // |
| 322 | -// if(ssf.getConditionExpression() != null){ | |
| 323 | -// String[] condis = ssf.getConditionExpression().split("&&"); | |
| 324 | -// | |
| 325 | -// if(condis.length == 0 && condis[0].contains("==1")){ | |
| 254 | +// if(condis.length == 0 && condis[0].contains("==1")){ | |
| 255 | +// continue; | |
| 256 | +// } | |
| 257 | +// | |
| 258 | +// for(String cond:condis){ | |
| 259 | +// if(cond.contains("index") || cond.contains("route")){ | |
| 326 | 260 | // continue; |
| 327 | 261 | // } |
| 328 | 262 | // |
| 329 | -// for(String cond:condis){ | |
| 330 | -// if(cond.contains("index") || cond.contains("route")){ | |
| 331 | -// continue; | |
| 332 | -// } | |
| 333 | -// | |
| 334 | -// if(cond.contains("==1")){ | |
| 335 | -// continue; | |
| 336 | -// } | |
| 337 | -// if(ssf.getTargetFlowElement().getName() == null) | |
| 338 | -// continue; | |
| 339 | -// this.setNext(ssf.getTargetFlowElement().getName()); | |
| 340 | -// break; | |
| 341 | -// } | |
| 342 | -// | |
| 343 | -// | |
| 263 | +// if(cond.contains("==1")){ | |
| 264 | +// continue; | |
| 344 | 265 | // } |
| 266 | +// modelList.add(f.getName()); | |
| 345 | 267 | // } |
| 268 | +// }else{ | |
| 269 | +// | |
| 270 | +// modelList.add(f.getName()); | |
| 271 | +// } | |
| 346 | 272 | // } |
| 347 | -// } | |
| 273 | +// | |
| 274 | +// | |
| 275 | +// } | |
| 276 | + return modelList; | |
| 348 | 277 | } |
| 349 | 278 | |
| 350 | - | |
| 279 | + private void getTrueRoute(FlowElement fe, String route, String index,List<String> modelList) { | |
| 280 | + | |
| 281 | + if(fe instanceof EndEvent){ | |
| 282 | + return; | |
| 283 | + } | |
| 284 | + | |
| 285 | + String formString = null; | |
| 286 | + if(fe instanceof UserTask){ | |
| 287 | + | |
| 288 | + for(FormProperty fp : ((UserTask) fe).getFormProperties()){ | |
| 289 | + String id = fp.getId(); | |
| 290 | + if(id.contains("radio")){ | |
| 291 | + formString = id.split("--__!!")[0]; | |
| 292 | + break; | |
| 293 | + } | |
| 294 | + } | |
| 295 | + | |
| 296 | + fe = ((UserTask) fe).getOutgoingFlows().get(0).getTargetFlowElement(); | |
| 297 | + | |
| 298 | + } | |
| 299 | + for(SequenceFlow sf : ((Gateway) fe).getOutgoingFlows()){ | |
| 300 | + String exp = sf.getConditionExpression().replace(" ", ""); | |
| 301 | + | |
| 302 | + if(formString != null && !exp.contains(formString + "==0")){ | |
| 303 | + continue; | |
| 304 | + } | |
| 305 | + if(exp.contains("index!=") && exp.contains("index!=" + index)){ | |
| 306 | + continue; | |
| 307 | + }else if(exp.contains("index==") && !exp.contains("index==" + index)){ | |
| 308 | + continue; | |
| 309 | + } | |
| 310 | + if(exp.contains("route!=") && exp.contains("route!=" + index)){ | |
| 311 | + continue; | |
| 312 | + }else if(exp.contains("route==") && !exp.contains("route==" + route)){ | |
| 313 | + continue; | |
| 314 | + } | |
| 315 | + | |
| 316 | + if(sf.getTargetFlowElement() instanceof EndEvent){ | |
| 317 | + return; | |
| 318 | + } | |
| 319 | + modelList.add(sf.getTargetFlowElement().getName()); | |
| 320 | + | |
| 321 | + getTrueRoute(sf.getTargetFlowElement(),route,index,modelList); | |
| 322 | + | |
| 323 | + break; | |
| 324 | + | |
| 325 | + } | |
| 326 | + | |
| 327 | + } | |
| 351 | 328 | |
| 352 | 329 | public String getId() { |
| 353 | 330 | return id; | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/mapper/ActReDeploymentMapper.java
| ... | ... | @@ -28,8 +28,8 @@ public interface ActReDeploymentMapper { |
| 28 | 28 | |
| 29 | 29 | public Map<String, String> selectHistoryWorkByPId(String id); |
| 30 | 30 | |
| 31 | - public List<String> selectTitles(); | |
| 31 | + public List<String> selectTitles(String name); | |
| 32 | 32 | |
| 33 | - public List<String> selectHistTitles(); | |
| 33 | + public List<String> selectHistTitles(String name); | |
| 34 | 34 | |
| 35 | 35 | } | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/service/impl/ActTaskServiceImpl.java
| ... | ... | @@ -248,16 +248,17 @@ public class ActTaskServiceImpl implements IActTaskService { |
| 248 | 248 | |
| 249 | 249 | processInstanceList = query.list(); |
| 250 | 250 | |
| 251 | - Set<String> idString = new HashSet<String>(); | |
| 252 | - for (HistoricProcessInstance pi : processInstanceList) { | |
| 253 | - idString.add(pi.getId()); | |
| 254 | - } | |
| 255 | - | |
| 256 | - List<Map<String, Object>> maps = actMapper.selectHistoryWorkByPIds(idString); | |
| 257 | - | |
| 258 | 251 | // List<ActWorkflowFormData> dataList = actWorkflowFormDataMapper.selectActWorkFlowFormDataListByUser(username); |
| 259 | 252 | |
| 260 | 253 | if (processInstanceList.size() > 0) { |
| 254 | + | |
| 255 | + Set<String> idString = new HashSet<String>(); | |
| 256 | + for (HistoricProcessInstance pi : processInstanceList) { | |
| 257 | + idString.add(pi.getId()); | |
| 258 | + } | |
| 259 | + | |
| 260 | + List<Map<String, Object>> maps = actMapper.selectHistoryWorkByPIds(idString); | |
| 261 | + | |
| 261 | 262 | for (HistoricProcessInstance p : processInstanceList) { |
| 262 | 263 | try { |
| 263 | 264 | ActTaskDTO dto = new ActTaskDTO(p, | ... | ... |
trash-activiti/src/main/java/com/trash/activiti/service/impl/myTaskServiceImpl.java
| ... | ... | @@ -170,6 +170,9 @@ public class myTaskServiceImpl implements myTaskService { |
| 170 | 170 | |
| 171 | 171 | if(name != null && !name.isEmpty()){ |
| 172 | 172 | query.processInstanceNameLike(name); |
| 173 | + | |
| 174 | + List<ProcessInstance> pList = query.list(); | |
| 175 | + | |
| 173 | 176 | } |
| 174 | 177 | if(defKey.size()>0){ |
| 175 | 178 | query.processDefinitionKeys(defKey); |
| ... | ... | @@ -182,7 +185,9 @@ public class myTaskServiceImpl implements myTaskService { |
| 182 | 185 | idSet.add(str); |
| 183 | 186 | } |
| 184 | 187 | |
| 185 | - pid = query.processInstanceIds(idSet).list().parallelStream().map(p->p.getId()).collect(Collectors.toList()); | |
| 188 | + List<ProcessInstance> pList = query.processInstanceIds(idSet).list(); | |
| 189 | + | |
| 190 | + pid = pList.parallelStream().map(p->p.getId()).collect(Collectors.toList()); | |
| 186 | 191 | } |
| 187 | 192 | |
| 188 | 193 | ... | ... |
trash-activiti/src/main/resources/mapper/activiti/ActReDeploymentMapper.xml
| ... | ... | @@ -41,7 +41,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 41 | 41 | |
| 42 | 42 | <select id="selectTitles" parameterType="String" resultType="java.lang.String"> |
| 43 | 43 | select DISTINCT title from workflow |
| 44 | + <where> | |
| 45 | + <if test="name!=null">and title like concat('%', #{name}, '%')</if> | |
| 46 | + </where> | |
| 44 | 47 | </select> |
| 48 | + | |
| 49 | + | |
| 45 | 50 | <select id="selectHistTitles" parameterType="String" resultType="java.lang.String"> |
| 46 | 51 | select DISTINCT title from workflow_hi |
| 47 | 52 | </select> | ... | ... |
trash-admin/src/main/resources/application-dev.yml
| ... | ... | @@ -17,7 +17,7 @@ trash: |
| 17 | 17 | captchaType: math |
| 18 | 18 | # ่ฟ็จๆๅกๅจๅฐๅ |
| 19 | 19 | #remotePath: http://175.6.47.84:8008 |
| 20 | - #token: durable:auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJjc3poIiwiZXhwIjo0MTAyNDE1OTk5LCJjcmVhdGVkIjoxNjg0MzI3NzQ1ODkyfQ.4BrpgD9i_1TwjLRGqa3wo4Ikx8t8Gcl3FzHfjL_uolPnNMm2rd7fCvrUoBBN4Qp4cMGzg9h2Nt4NNx8PYThTaQ | |
| 20 | + #token: durable:auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJkdXJhYmxlIiwiZXhwIjo0MTAyNDE1OTk5LCJjcmVhdGVkIjoxNjg1NDE2NjEzMzU1fQ.58-J0KKfsK2pQhDQAzaBaUj-oFWMbYF1YzMAcshmcfidIkW16TZWIVhAVKPvCJvWfG54x7xB-ETxKCDLFnSctQ | |
| 21 | 21 | remotePath: http://183.66.242.6:14601 |
| 22 | 22 | token: durable:auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJjc3poIiwiZXhwIjo0MTAyNDE1OTk5LCJjcmVhdGVkIjoxNjg0NDU5MjEzNzQ2fQ.85oIrOnU7cz7L_-IGt4Bt1LXDTkFtyrdqNt05K0v9-4nsrrzzpbjbemK-yMlbnUpe4Fx2FFES-Wbw8Yr8ML69w |
| 23 | 23 | |
| ... | ... | @@ -32,7 +32,7 @@ spring: |
| 32 | 32 | druid: |
| 33 | 33 | # ไธปๅบๆฐๆฎๆบ |
| 34 | 34 | master: |
| 35 | - #url: jdbc:mysql://localhost:3306/trash1?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true | |
| 35 | + #url: jdbc:mysql://localhost:3306/trash?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true | |
| 36 | 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 | ... | ... |
trash-common/src/main/java/com/trash/common/utils/RemoteServerUtils.java
| ... | ... | @@ -5,6 +5,7 @@ import java.util.List; |
| 5 | 5 | import java.util.Map; |
| 6 | 6 | import java.util.concurrent.TimeUnit; |
| 7 | 7 | |
| 8 | +import org.springframework.beans.factory.annotation.Autowired; | |
| 8 | 9 | import org.springframework.beans.factory.annotation.Value; |
| 9 | 10 | import org.springframework.context.annotation.Configuration; |
| 10 | 11 | import org.springframework.context.annotation.PropertySource; |
| ... | ... | @@ -13,6 +14,7 @@ import com.alibaba.fastjson.JSON; |
| 13 | 14 | import com.alibaba.fastjson.JSONArray; |
| 14 | 15 | import com.alibaba.fastjson.JSONObject; |
| 15 | 16 | import com.trash.common.config.trashConfig; |
| 17 | +import com.trash.common.core.redis.RedisCache; | |
| 16 | 18 | import com.trash.common.utils.SecurityUtils; |
| 17 | 19 | |
| 18 | 20 | import okhttp3.MediaType; |
| ... | ... | @@ -74,7 +76,6 @@ public class RemoteServerUtils { |
| 74 | 76 | |
| 75 | 77 | public static String ContractList = "/api/siteservice/cs/sitecontract/ledger/list"; |
| 76 | 78 | |
| 77 | - | |
| 78 | 79 | public static JSONArray getContractList(Map map){ |
| 79 | 80 | JSONArray list=null; |
| 80 | 81 | Object object = post(ContractList,map); |
| ... | ... | @@ -88,6 +89,7 @@ public class RemoteServerUtils { |
| 88 | 89 | } |
| 89 | 90 | |
| 90 | 91 | public static JSONArray getContractList(Map map,String token){ |
| 92 | + | |
| 91 | 93 | JSONArray list=null; |
| 92 | 94 | Object object = post(ContractList,map,token); |
| 93 | 95 | ... | ... |
trash-quartz/src/main/java/com/trash/quartz/task/DriverTask.java
| ... | ... | @@ -81,7 +81,7 @@ public class DriverTask |
| 81 | 81 | private void checkTruckActive() { |
| 82 | 82 | int hour = new Date().getHours(); |
| 83 | 83 | int minute = new Date().getMinutes(); |
| 84 | - if(hour > 4 && hour < 8 && (hour>3 && minute>55)){ | |
| 84 | + if(hour < 8 && (hour==3 && minute>55)){ | |
| 85 | 85 | return; |
| 86 | 86 | } |
| 87 | 87 | |
| ... | ... | @@ -120,6 +120,9 @@ public class DriverTask |
| 120 | 120 | List<SupervisionThreestep> cs = SpringUtils.getBean(SupervisionThreestepMapper.class).selectTodayDataList(param); |
| 121 | 121 | |
| 122 | 122 | for(SupervisionThreestep c:cs){ |
| 123 | + if(hour < 8 && (hour==3 && minute>55)){ | |
| 124 | + return; | |
| 125 | + } | |
| 123 | 126 | try { |
| 124 | 127 | SpringUtils.getBean(ISupervisionThreestepService.class).checkDataToActiveTruck(c,TOKEN); |
| 125 | 128 | } catch (Exception e) { |
| ... | ... | @@ -332,6 +335,19 @@ public class DriverTask |
| 332 | 335 | JSONArray jsonArray = RemoteServerUtils.getCompanyList(map, trashConfig.getToken()); |
| 333 | 336 | redisCache.setCacheObject("companyList",jsonArray); |
| 334 | 337 | } |
| 338 | + | |
| 339 | + public void getContractList(){ | |
| 340 | + if(RemoteServerUtils.remote == null){ | |
| 341 | + RemoteServerUtils.remote = trashConfig.getRemotePath(); | |
| 342 | + } | |
| 343 | + Map<String, Object> map = new HashMap<>(); | |
| 344 | + map.put("size",9999); | |
| 345 | + map.put("page",1); | |
| 346 | + map.put("contractStatus", 1); | |
| 347 | + map.put("auditStatus", 1); | |
| 348 | + JSONArray jsonArray = RemoteServerUtils.getContractList(map, trashConfig.getToken()); | |
| 349 | + redisCache.setCacheObject("contractList",jsonArray); | |
| 350 | + } | |
| 335 | 351 | |
| 336 | 352 | /** |
| 337 | 353 | * ๆฏๅ้ๆดๆฐไธๆฌกๅทฅๅฐๅ่กจ |
| ... | ... | @@ -341,7 +357,7 @@ public class DriverTask |
| 341 | 357 | RemoteServerUtils.remote = trashConfig.getRemotePath(); |
| 342 | 358 | } |
| 343 | 359 | Map<String, Object> map = new HashMap<>(); |
| 344 | - map.put("size",999); | |
| 360 | + map.put("size",9999); | |
| 345 | 361 | map.put("page",1); |
| 346 | 362 | JSONArray jsonArray = RemoteServerUtils.getConstructionList(map,trashConfig.getToken()); |
| 347 | 363 | redisCache.setCacheObject("constructionList",jsonArray); |
| ... | ... | @@ -355,7 +371,7 @@ public class DriverTask |
| 355 | 371 | RemoteServerUtils.remote = trashConfig.getRemotePath(); |
| 356 | 372 | } |
| 357 | 373 | Map<String, Object> map = new HashMap<>(); |
| 358 | - map.put("size",999); | |
| 374 | + map.put("size",9999); | |
| 359 | 375 | map.put("page",1); |
| 360 | 376 | JSONArray jsonArray = RemoteServerUtils.getEarthSitesList(map,trashConfig.getToken()); |
| 361 | 377 | redisCache.setCacheObject("earthSitesList",jsonArray); |
| ... | ... | @@ -369,7 +385,7 @@ public class DriverTask |
| 369 | 385 | RemoteServerUtils.remote = trashConfig.getRemotePath(); |
| 370 | 386 | } |
| 371 | 387 | Map<String, Object> map = new HashMap<>(); |
| 372 | - map.put("size",999); | |
| 388 | + map.put("size",9999); | |
| 373 | 389 | map.put("page",1); |
| 374 | 390 | JSONArray jsonArray = RemoteServerUtils.getAreas(trashConfig.getToken()); |
| 375 | 391 | redisCache.setCacheObject("areaList",jsonArray); | ... | ... |
trash-ui/dist.rar
0 โ 100644
No preview for this file type
trash-ui/src/api/activiti/task.js
trash-ui/src/api/caseOfflineInfo.js
| ... | ... | @@ -49,6 +49,7 @@ export default { |
| 49 | 49 | caseType: [ |
| 50 | 50 | {code: 7, name: "ๆ ่ฎธๅฏๆถ็บณ๏ผๅทฅ๏ผ"}, |
| 51 | 51 | {code: 8, name: "ๆ ่ฎธๅฏๆถ็บณ๏ผๆถ๏ผ"}, |
| 52 | + {code: 9, name: "ไฝฟ็จ้ไธ็จ่ฝฆ่พ"}, | |
| 52 | 53 | {code: 0, name: "ๆธฃๅๅค็ฝฎๅทฅๅฐ๏ผๅซๅค็ๅบๆ๏ผ็ๆธฃๅ่ฟ่พ่ฝฆ่พๅบๅบ่ฝฆ่บซไธๆด๏ผ่ฝฆ่ฝฎๅธฆๆณฅ"}, |
| 53 | 54 | {code: 1, name: "ๆชๆด่ฝฆๅบๅบๆ่ ๅบๅบๆธ ๆดไธๅฝปๅบ"}, |
| 54 | 55 | {code: 2, name: "ๆธฃๅ่ฟ่พ่ฝฆ่พ่ดง็ฎฑ้กถ็ๆชๆ่งๅฎๅ ณ้ญๅฐไฝๆๆชๆ่งๅฎๅๆ ๅ่ฃ ่ฝฝๆธฃๅๅบๅบ"}, |
| ... | ... | @@ -56,7 +57,6 @@ export default { |
| 56 | 57 | {code: 4, name: "ๆธฃๅๅค็ฝฎๅทฅๅฐๆชๆ่งๅฎๆถ้ดๅผๅๅทฅ"}, |
| 57 | 58 | {code: 5, name: "ๆธฃๅๅค็ฝฎๅทฅๅฐๆด่ฝฆ่ฎพๆฝ็ญ็ ดๆใๆชๆญฃๅธธไฝฟ็จๅๆชๆฝไธๅฐไฝ็"}, |
| 58 | 59 | {code: 6, name: "ๆธฃๅๅค็ฝฎๅทฅๅฐใๅค็ๅบๆ(ๅซๅๅกซๅบ๏ผๅบๅ ฅๅฃไธคไพง50็ฑณ่ๅดๅ ๅบ็ฐๆธฃๅๆฑกๆใๆฑกๆฐดๅคๆ็ญ็ฐ่ฑก"}, |
| 59 | - {code: 9, name: "ๅ ถไป3"} | |
| 60 | 60 | ], |
| 61 | 61 | fileList: [], |
| 62 | 62 | areas: [], | ... | ... |
trash-ui/src/api/caseoffline.js
| ... | ... | @@ -67,6 +67,9 @@ export default { |
| 67 | 67 | rules: { |
| 68 | 68 | }, |
| 69 | 69 | caseType:[ |
| 70 | + {code: 7, name: "ๆ ่ฎธๅฏๆถ็บณ๏ผๅทฅ๏ผ"}, | |
| 71 | + {code: 8, name: "ๆ ่ฎธๅฏๆถ็บณ๏ผๆถ๏ผ"}, | |
| 72 | + {code: 9, name: "ไฝฟ็จ้ไธ็จ่ฝฆ่พ"}, | |
| 70 | 73 | {code:0,name:"ๆธฃๅๅค็ฝฎๅทฅๅฐ๏ผๅซๅค็ๅบๆ๏ผ็ๆธฃๅ่ฟ่พ่ฝฆ่พๅบๅบ่ฝฆ่บซไธๆด๏ผ่ฝฆ่ฝฎๅธฆๆณฅ"}, |
| 71 | 74 | {code:1,name:"ๆชๆด่ฝฆๅบๅบๆ่ ๅบๅบๆธ ๆดไธๅฝปๅบ"}, |
| 72 | 75 | {code:2,name:"ๆธฃๅ่ฟ่พ่ฝฆ่พ่ดง็ฎฑ้กถ็ๆชๆ่งๅฎๅ ณ้ญๅฐไฝๆๆชๆ่งๅฎๅๆ ๅ่ฃ ่ฝฝๆธฃๅๅบๅบ"}, |
| ... | ... | @@ -74,9 +77,6 @@ export default { |
| 74 | 77 | {code:4,name:"ๆธฃๅๅค็ฝฎๅทฅๅฐๆชๆ่งๅฎๆถ้ดๅผๅๅทฅ"}, |
| 75 | 78 | {code:5,name:"ๆธฃๅๅค็ฝฎๅทฅๅฐๆด่ฝฆ่ฎพๆฝ็ญ็ ดๆใๆชๆญฃๅธธไฝฟ็จๅๆชๆฝไธๅฐไฝ็"}, |
| 76 | 79 | {code:6,name:"ๆธฃๅๅค็ฝฎๅทฅๅฐใๅค็ๅบๆ(ๅซๅๅกซๅบ๏ผๅบๅ ฅๅฃไธคไพง50็ฑณ่ๅดๅ ๅบ็ฐๆธฃๅๆฑกๆใๆฑกๆฐดๅคๆ็ญ็ฐ่ฑก"}, |
| 77 | - {code:7,name:"ๅ ถไป1"}, | |
| 78 | - {code:8,name:"ๅ ถไป2"}, | |
| 79 | - {code:9,name:"ๅ ถไป3"} | |
| 80 | 80 | ], |
| 81 | 81 | fileList:[], |
| 82 | 82 | areas: [], |
| ... | ... | @@ -99,6 +99,10 @@ export default { |
| 99 | 99 | slides:[], |
| 100 | 100 | videoSrc:[], |
| 101 | 101 | businessKey:null, |
| 102 | + remoteQueryData : { | |
| 103 | + "page": 1, | |
| 104 | + "size": 100 | |
| 105 | + } | |
| 102 | 106 | }; |
| 103 | 107 | }, |
| 104 | 108 | created() { |
| ... | ... | @@ -132,22 +136,37 @@ export default { |
| 132 | 136 | |
| 133 | 137 | |
| 134 | 138 | |
| 135 | - let remoteQueryData = { | |
| 136 | - "page": 1, | |
| 137 | - "size": 9999 | |
| 138 | - } | |
| 139 | - | |
| 140 | - constructionsitesList(remoteQueryData).then(res => { | |
| 139 | + constructionsitesList(this.remoteQueryData).then(res => { | |
| 141 | 140 | this.data[0]= res.result.list; |
| 142 | 141 | }); |
| 143 | 142 | |
| 144 | - earthsitesList(remoteQueryData).then(res => { | |
| 143 | + earthsitesList(this.remoteQueryData).then(res => { | |
| 145 | 144 | this.data[1]= res.result.list; |
| 146 | 145 | }); |
| 147 | 146 | }, |
| 148 | 147 | methods: { |
| 149 | 148 | getSite(item){ |
| 150 | - this.form.objectId = item.id; | |
| 149 | + | |
| 150 | + this.remoteQueryData.name = item; | |
| 151 | + | |
| 152 | + constructionsitesList(this.remoteQueryData).then(res => { | |
| 153 | + this.data[0]= res.result.list; | |
| 154 | + for(let i in res.result.list){ | |
| 155 | + if(res.result.list[i].name == item){ | |
| 156 | + this.form.objectId = res.result.list[i].id; | |
| 157 | + } | |
| 158 | + } | |
| 159 | + }); | |
| 160 | + | |
| 161 | + earthsitesList(this.remoteQueryData).then(res => { | |
| 162 | + this.data[1]= res.result.list; | |
| 163 | + for(let i in res.result.list){ | |
| 164 | + if(res.result.list[i].name == item){ | |
| 165 | + this.form.objectId = res.result.list[i].id; | |
| 166 | + } | |
| 167 | + } | |
| 168 | + }); | |
| 169 | + | |
| 151 | 170 | }, |
| 152 | 171 | /** ๆฅ่ฏข็บฟไธไบคๅๆกๅทๅ่กจ */ |
| 153 | 172 | getList() { | ... | ... |
trash-ui/src/api/dayWorkReport.js
| ... | ... | @@ -304,13 +304,13 @@ export default { |
| 304 | 304 | }); |
| 305 | 305 | // let query = this.queryParams; |
| 306 | 306 | |
| 307 | - if (tabIdx == 1) { | |
| 307 | + if (this.queryParams.his != tabIdx && tabIdx == 1) { | |
| 308 | 308 | this.queryParams.pageNum = 1; |
| 309 | 309 | this.resetQuery(); |
| 310 | 310 | this.names = null; |
| 311 | 311 | this.ename = null; |
| 312 | 312 | this.queryParams.his = tabIdx; |
| 313 | - } else if (tabIdx == 0) { | |
| 313 | + } else if (this.queryParams.his != tabIdx && tabIdx == 0) { | |
| 314 | 314 | this.queryParams.pageNum = 1; |
| 315 | 315 | this.resetQuery(); |
| 316 | 316 | this.names = null; | ... | ... |
trash-ui/src/api/dict.js
| 1 | 1 | import requestRemote from '@/utils/requestRemote' |
| 2 | 2 | |
| 3 | +export function getTruckList(params) { | |
| 4 | + return requestRemote({ | |
| 5 | + url: ' /api/gpsservice/cs/basevehicle/simplelist', | |
| 6 | + method: 'get', | |
| 7 | + params:params | |
| 8 | + }); | |
| 9 | +} | |
| 10 | + | |
| 11 | + | |
| 3 | 12 | export function constructionById(id) { |
| 4 | 13 | return requestRemote({ |
| 5 | 14 | url: '/api/siteservice/cs/constructionsites/'+id, | ... | ... |
trash-ui/src/api/three_step.js
| ... | ... | @@ -31,6 +31,7 @@ import { |
| 31 | 31 | getConstructionTruck, |
| 32 | 32 | constructionById, |
| 33 | 33 | earthsitesById, |
| 34 | + getTruckList, | |
| 34 | 35 | } from "@/api/dict"; |
| 35 | 36 | |
| 36 | 37 | export default { |
| ... | ... | @@ -50,6 +51,7 @@ export default { |
| 50 | 51 | businessKey:null, |
| 51 | 52 | picSample: false, |
| 52 | 53 | uploadImageDialog: false, |
| 54 | + truckName:null, | |
| 53 | 55 | // ้ไธญๆฐ็ป |
| 54 | 56 | ids: [], |
| 55 | 57 | // ้ๅไธช็ฆ็จ |
| ... | ... | @@ -138,16 +140,6 @@ export default { |
| 138 | 140 | message: '่ฏทๅกซๅๅฎๆด', |
| 139 | 141 | trigger: 'change' |
| 140 | 142 | },], |
| 141 | - companys: [{ | |
| 142 | - required: false, | |
| 143 | - message: '่ฏทๅกซๅๅฎๆด', | |
| 144 | - trigger: 'change' | |
| 145 | - },], | |
| 146 | - trucks: [{ | |
| 147 | - required: false, | |
| 148 | - message: '่ฏทๅกซๅๅฎๆด', | |
| 149 | - trigger: 'change' | |
| 150 | - },], | |
| 151 | 143 | objectId: [{ |
| 152 | 144 | required: true, |
| 153 | 145 | message: '่ฏทๅกซๅๅฎๆด', |
| ... | ... | @@ -174,7 +166,7 @@ export default { |
| 174 | 166 | remoteData: [], |
| 175 | 167 | remoteQueryData: { |
| 176 | 168 | "page": 1, |
| 177 | - "size": 9999, | |
| 169 | + "size": 100, | |
| 178 | 170 | "auditStatus": 1, |
| 179 | 171 | "creditStatus": 0, |
| 180 | 172 | }, |
| ... | ... | @@ -287,66 +279,108 @@ export default { |
| 287 | 279 | selectArea(a) { |
| 288 | 280 | this.areaCode = a; |
| 289 | 281 | this.form.name = ""; |
| 282 | + this.remoteQueryData.name = null; | |
| 283 | + | |
| 284 | + this.remoteQueryData.areaCode = a; | |
| 285 | + | |
| 286 | + this.remoteData = []; | |
| 287 | + this.getRemoteData(); | |
| 288 | + | |
| 290 | 289 | }, |
| 291 | - getObjId(value) { | |
| 292 | - let item; | |
| 293 | - for (let i in this.remoteData) { | |
| 294 | - if (this.remoteData[i].name == value) { | |
| 295 | - item = this.remoteData[i]; | |
| 296 | - break; | |
| 290 | + getRemoteData(){ | |
| 291 | + if(this.form.type){ | |
| 292 | + if (this.form.type == "0") { | |
| 293 | + if(this.remoteQueryData.areaCode) | |
| 294 | + this.remoteQueryData.areaCode = this.remoteQueryData.areaCode + ""; | |
| 295 | + | |
| 296 | + constructionsitesList(this.remoteQueryData).then(res => { | |
| 297 | + for(let i in res.result.list){ | |
| 298 | + this.remoteData.push(res.result.list[i]); | |
| 299 | + | |
| 300 | + if(res.result.list[i].name == this.form.name){ | |
| 301 | + let item = this.remoteData[0]; | |
| 302 | + this.form.objectId = item.id; | |
| 303 | + this.form.place = Number(item.areaCode); | |
| 304 | + this.getCompanyTrucks(item.id); | |
| 305 | + } | |
| 306 | + | |
| 307 | + } | |
| 308 | + | |
| 309 | + | |
| 310 | + // this.rules.companys[0].required = true; | |
| 311 | + // this.rules.trucks[0].required = true; | |
| 312 | + | |
| 313 | + }); | |
| 314 | + } else { | |
| 315 | + if(this.remoteQueryData.areaCode) | |
| 316 | + this.remoteQueryData.areaCode = [this.remoteQueryData.areaCode+""]; | |
| 317 | + earthsitesList(this.remoteQueryData).then(res => { | |
| 318 | + for(let i in res.result.list){ | |
| 319 | + this.remoteData.push(res.result.list[i]); | |
| 320 | + if(res.result.list[i].name == this.form.name){ | |
| 321 | + let item = this.remoteData[0]; | |
| 322 | + this.form.objectId = item.id; | |
| 323 | + this.form.place = Number(item.areaCode) ; | |
| 324 | + } | |
| 325 | + } | |
| 326 | + }); | |
| 297 | 327 | } |
| 298 | 328 | } |
| 329 | + }, | |
| 330 | + getObjId(value) { | |
| 331 | + console.log(value); | |
| 332 | + let item; | |
| 299 | 333 | |
| 334 | + this.remoteQueryData.name = value; | |
| 335 | + this.remoteData = []; | |
| 336 | + this.getRemoteData(); | |
| 300 | 337 | |
| 301 | - this.form.objectId = item.id; | |
| 302 | - this.form.place = Number(item.areaCode); | |
| 303 | - | |
| 304 | - if(this.form.type == 1) | |
| 305 | - return; | |
| 306 | 338 | |
| 307 | 339 | |
| 308 | - this.getCompanyTrucks(item.id); | |
| 309 | 340 | }, |
| 310 | 341 | getCompanyTrucks(objId){ |
| 311 | - | |
| 312 | 342 | this.form.companys = null; |
| 313 | 343 | this.form.companyTrucks = null; |
| 314 | 344 | this.companyList = []; |
| 315 | 345 | this.truckList = []; |
| 316 | 346 | |
| 317 | - constructionById(objId).then(response => { | |
| 318 | - this.companyList.push({id: response.result.transportCompanyId, name: response.result.transportCompany}); | |
| 319 | - let query = { | |
| 320 | - 'page': 1, | |
| 321 | - 'size': 9999, | |
| 322 | - 'dishonestState': 0, | |
| 323 | - 'valid': 0 | |
| 347 | + constructionById(objId).then(res => { | |
| 348 | + this.companyList.push({ | |
| 349 | + id: res.result.transportCompanyId, | |
| 350 | + name: res.result.transportCompany | |
| 351 | + }); | |
| 352 | + | |
| 353 | + let param = { | |
| 354 | + companyId:res.result.transportCompanyId, | |
| 355 | + auditStatus:1, | |
| 356 | + dishonestState:0 | |
| 324 | 357 | } |
| 325 | 358 | |
| 326 | - let ids = []; | |
| 359 | + for(let i in res.result.unitCompanyList){ | |
| 360 | + let unit = res.result.unitCompanyList[i]; | |
| 361 | + | |
| 362 | + let today = new Date().getTime(); | |
| 363 | + if(new Date(unit.startTime).getTime() > today || new Date(unit.endTime).getTime() < today){ | |
| 364 | + continue; | |
| 365 | + } | |
| 366 | + param.companyId += "," + unit.companyId; | |
| 327 | 367 | |
| 328 | - ids.push(response.result.transportCompanyId); | |
| 368 | + this.companyList.push({ | |
| 369 | + id: unit.companyId, | |
| 370 | + name: unit.companyName | |
| 371 | + }); | |
| 329 | 372 | |
| 330 | - query.companyID = ids + ""; | |
| 331 | - query.valid = 0; | |
| 373 | + } | |
| 332 | 374 | |
| 333 | - getConstructionTruck(objId).then(res => { | |
| 334 | - for (let i in res.result) { | |
| 335 | - this.companyList.push({id: res.result[i].companyId, name: res.result[i].companyName}); | |
| 336 | - for (let j in res.result[i].vehicleList) { | |
| 337 | - this.truckList.push({ | |
| 338 | - id: res.result[i].vehicleList[j].id, | |
| 339 | - licenseplateNo: res.result[i].vehicleList[j].licenseplateNo, | |
| 340 | - companyName: res.result[i].companyName | |
| 341 | - }); | |
| 342 | - } | |
| 375 | + | |
| 376 | + getTruckList(param).then(tres=>{ | |
| 377 | + for(let i = 0;i< tres.result.length;i++){; | |
| 378 | + this.truckList.push({licenseplateNo:tres.result[i].licenseplateNo,id:tres.result[i].id,companyName:tres.result[i].companyName}); | |
| 343 | 379 | } |
| 344 | - truckList(query).then(res => { | |
| 345 | - for (let i in res.result.list) { | |
| 346 | - this.truckList.push(res.result.list[i]); | |
| 347 | - } | |
| 348 | - }); | |
| 349 | - }); | |
| 380 | + }) | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 350 | 384 | }); |
| 351 | 385 | |
| 352 | 386 | }, |
| ... | ... | @@ -355,33 +389,40 @@ export default { |
| 355 | 389 | window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); |
| 356 | 390 | }, |
| 357 | 391 | removeImage(index, img) { |
| 358 | - for(let i=0;i<this.slides[index].length;i++){ | |
| 359 | - if(this.slides[index][i].alt == img){ | |
| 360 | - this.slides[index].splice(i,1); | |
| 392 | + if(this.slides[index]){ | |
| 393 | + for(let i=0;i<this.slides[index].length;i++){ | |
| 394 | + if(this.slides[index][i].alt == img){ | |
| 395 | + this.slides[index].splice(i,1); | |
| 396 | + } | |
| 361 | 397 | } |
| 362 | 398 | } |
| 363 | - for(let i=0;i<this.videos[index].length;i++){ | |
| 364 | - if(this.videos[index][i].alt == img){ | |
| 365 | - this.videos[index].splice(i,1); | |
| 399 | + if(this.videos[index]){ | |
| 400 | + for(let i=0;i<this.videos[index].length;i++){ | |
| 401 | + if(this.videos[index][i].alt == img){ | |
| 402 | + this.videos[index].splice(i,1); | |
| 403 | + } | |
| 366 | 404 | } |
| 367 | 405 | } |
| 406 | + | |
| 368 | 407 | let target = "img" + index; |
| 369 | 408 | this.form[target].splice(this.form[target].indexOf(img), 1); |
| 370 | 409 | this.$forceUpdate(); |
| 371 | 410 | }, |
| 372 | - removeAttchItem(index, img,index1) { | |
| 373 | - let target = "attchItem" + index; | |
| 411 | + removeAttchItem(index, img) { | |
| 412 | + let target = "attchItem" + (index-90); | |
| 374 | 413 | this.form[target].splice(this.form[target].indexOf(img), 1); |
| 375 | - for(let i=0;i<this.slides[index1].length;i++){ | |
| 376 | - if(this.slides[index1][i].alt == img){ | |
| 377 | - this.slides[index1].splice(i,1); | |
| 378 | - } | |
| 379 | - } | |
| 380 | - for(let i=0;i<this.videos[index].length;i++){ | |
| 381 | - if(this.videos[index][i].alt == img){ | |
| 382 | - this.videos[index].splice(i,1); | |
| 383 | - } | |
| 384 | - } | |
| 414 | + if(this.slides[index]){ | |
| 415 | + for(let i=0;i<this.slides[index].length;i++){ | |
| 416 | + if(this.slides[index][i].alt == img){ | |
| 417 | + this.slides[index].splice(i,1); | |
| 418 | + } | |
| 419 | + }} | |
| 420 | + if(this.videos[index]){ | |
| 421 | + for(let i=0;i<this.videos[index].length;i++){ | |
| 422 | + if(this.videos[index][i].alt == img){ | |
| 423 | + this.videos[index].splice(i,1); | |
| 424 | + } | |
| 425 | + }} | |
| 385 | 426 | this.$forceUpdate(); |
| 386 | 427 | }, |
| 387 | 428 | |
| ... | ... | @@ -396,15 +437,16 @@ export default { |
| 396 | 437 | this.form[target] = []; |
| 397 | 438 | } |
| 398 | 439 | this.form[target].push(res); |
| 399 | - return; | |
| 400 | - } | |
| 401 | - let target = "img" + this.picIndex; | |
| 440 | + }else{ | |
| 441 | + let target = "img" + this.picIndex; | |
| 442 | + | |
| 443 | + if (!this.form[target]) { | |
| 444 | + this.form[target] = []; | |
| 445 | + } | |
| 402 | 446 | |
| 403 | - if (!this.form[target]) { | |
| 404 | - this.form[target] = []; | |
| 447 | + this.form[target].push(res); | |
| 405 | 448 | } |
| 406 | 449 | |
| 407 | - this.form[target].push(res); | |
| 408 | 450 | if(file.name.indexOf('.jpg') > -1 ||file.name.indexOf('.png') > -1){ |
| 409 | 451 | let url = URL.createObjectURL(file.raw) |
| 410 | 452 | if(!this.slides[this.picIndex]){ |
| ... | ... | @@ -434,7 +476,6 @@ export default { |
| 434 | 476 | this.picIndex = i; |
| 435 | 477 | }, |
| 436 | 478 | beforeUpload(file) { |
| 437 | - console.log(file); | |
| 438 | 479 | let isRightSize = file.size / 1024 / 1024 < 20 |
| 439 | 480 | if (!isRightSize) { |
| 440 | 481 | this.$message.error('ๆไปถๅคงๅฐ่ถ ่ฟ 20MB') |
| ... | ... | @@ -462,26 +503,21 @@ export default { |
| 462 | 503 | }, |
| 463 | 504 | selectType(value) { |
| 464 | 505 | |
| 465 | - this.rules.companys[0].required = false; | |
| 466 | - this.rules.trucks[0].required = false; | |
| 506 | + // this.rules.companys[0].required = false; | |
| 507 | + // this.rules.trucks[0].required = false; | |
| 467 | 508 | |
| 468 | 509 | this.form.name = null; |
| 469 | - this.bindname = null; | |
| 510 | + | |
| 511 | + this.remoteQueryData.name = null; | |
| 470 | 512 | |
| 471 | 513 | if (value == "0") { |
| 472 | 514 | this.labelName = "ๅทฅๅฐๅ็งฐ"; |
| 473 | - constructionsitesList(this.remoteQueryData).then(res => { | |
| 474 | - this.remoteData = res.result.list; | |
| 475 | - this.rules.companys[0].required = true; | |
| 476 | - this.rules.trucks[0].required = true; | |
| 477 | - | |
| 478 | - }); | |
| 479 | 515 | } else { |
| 480 | 516 | this.labelName = "ๅค็ๅบๆๅ็งฐ"; |
| 481 | - earthsitesList(this.remoteQueryData).then(res => { | |
| 482 | - this.remoteData = res.result.list; | |
| 483 | - }); | |
| 484 | 517 | } |
| 518 | + | |
| 519 | + this.remoteData = []; | |
| 520 | + this.getRemoteData(); | |
| 485 | 521 | }, |
| 486 | 522 | getAreaName(code) { |
| 487 | 523 | for (let i = 0; i < this.areas.length; i++) { |
| ... | ... | @@ -515,15 +551,6 @@ export default { |
| 515 | 551 | }) |
| 516 | 552 | } |
| 517 | 553 | |
| 518 | - let query = { | |
| 519 | - "page": 1, | |
| 520 | - "size": 9999, | |
| 521 | - "auditStatus": 1, | |
| 522 | - }; | |
| 523 | - | |
| 524 | - contractList(query).then(res => { | |
| 525 | - this.contractList = res.result.list; | |
| 526 | - }); | |
| 527 | 554 | |
| 528 | 555 | this.loading = true; |
| 529 | 556 | listThreestep(this.queryParams).then(response => { |
| ... | ... | @@ -556,8 +583,8 @@ export default { |
| 556 | 583 | checkTime: null, |
| 557 | 584 | earthsitesName: null, |
| 558 | 585 | contract: null, |
| 559 | - companys: null, | |
| 560 | - companyTrucks: null, | |
| 586 | + companys: [], | |
| 587 | + companyTrucks: [], | |
| 561 | 588 | img0: null, |
| 562 | 589 | img1: null, |
| 563 | 590 | img2: null, |
| ... | ... | @@ -574,6 +601,15 @@ export default { |
| 574 | 601 | person: null, |
| 575 | 602 | phone: null |
| 576 | 603 | }; |
| 604 | + | |
| 605 | + this.remoteQueryData = { | |
| 606 | + page:1, | |
| 607 | + size:100, | |
| 608 | + auditStatus: 1, | |
| 609 | + creditStatus: 0, | |
| 610 | + } | |
| 611 | + | |
| 612 | + | |
| 577 | 613 | this.videos = []; |
| 578 | 614 | this.slides = []; |
| 579 | 615 | this.resetForm("form"); |
| ... | ... | @@ -613,14 +649,16 @@ export default { |
| 613 | 649 | } |
| 614 | 650 | }, |
| 615 | 651 | reSub(row) { |
| 616 | - this.reset(); | |
| 652 | + // this.reset(); | |
| 617 | 653 | |
| 618 | 654 | this.title = "ๅๆฌกๆไบค"; |
| 619 | 655 | |
| 620 | - this.open = true; | |
| 656 | + this.open = true; | |
| 657 | + | |
| 621 | 658 | getThreestep(row.id).then(res => { |
| 622 | 659 | this.form = res.data; |
| 623 | - | |
| 660 | + this.form.name = res.data.name; | |
| 661 | + this.form.objectId = res.data.objectId; | |
| 624 | 662 | this.form.type = this.form.type + ""; |
| 625 | 663 | this.form.place = Number(this.form.place); |
| 626 | 664 | this.bindname = res.data.earthsitesName; |
| ... | ... | @@ -644,7 +682,6 @@ export default { |
| 644 | 682 | let query = { |
| 645 | 683 | 'page': 1, |
| 646 | 684 | 'size': 9999, |
| 647 | - 'dishonestState': 0, | |
| 648 | 685 | 'valid': 0 |
| 649 | 686 | } |
| 650 | 687 | |
| ... | ... | @@ -653,7 +690,6 @@ export default { |
| 653 | 690 | ids.push(response.result.transportCompanyId); |
| 654 | 691 | |
| 655 | 692 | query.companyID = ids + ""; |
| 656 | - query.valid = 0; | |
| 657 | 693 | |
| 658 | 694 | getConstructionTruck(this.form.objectId).then(res => { |
| 659 | 695 | for (let i in res.result) { |
| ... | ... | @@ -666,17 +702,21 @@ export default { |
| 666 | 702 | }); |
| 667 | 703 | } |
| 668 | 704 | } |
| 705 | + | |
| 669 | 706 | truckList(query).then(res => { |
| 670 | 707 | let trucks = []; |
| 671 | 708 | for (let i in res.result.list) { |
| 672 | - for(let j in this.form.trucks){ | |
| 673 | - if(this.form.trucks[j] == res.result.list[i].id){ | |
| 674 | - trucks.push(res.result.list[i].licenseplateNo); | |
| 709 | + this.truckList.push(res.result.list[i]); | |
| 710 | + } | |
| 711 | + for(let j in this.form.trucks){ | |
| 712 | + for (let i in this.truckList) { | |
| 713 | + console.log(this.form.trucks[j]); | |
| 714 | + console.log(this.truckList[i].id); | |
| 715 | + if(this.form.trucks[j] == this.truckList[i].id){ | |
| 716 | + trucks.push(this.truckList[i].licenseplateNo); | |
| 675 | 717 | break; |
| 676 | 718 | } |
| 677 | 719 | } |
| 678 | - | |
| 679 | - this.truckList.push(res.result.list[i]); | |
| 680 | 720 | } |
| 681 | 721 | this.form.trucks = trucks; |
| 682 | 722 | }); |
| ... | ... | @@ -714,7 +754,6 @@ export default { |
| 714 | 754 | }, |
| 715 | 755 | /** ๆไบคๆ้ฎ */ |
| 716 | 756 | submitForm() { |
| 717 | - debugger; | |
| 718 | 757 | if(this.form.trucks){ |
| 719 | 758 | this.form.companyTrucks = []; |
| 720 | 759 | for(let i in this.form.trucks){ |
| ... | ... | @@ -727,10 +766,32 @@ export default { |
| 727 | 766 | } |
| 728 | 767 | } |
| 729 | 768 | |
| 769 | + let companyNames = ""; | |
| 770 | + for(let i in this.companyList){ | |
| 771 | + companyNames += this.companyList[i].name + ","; | |
| 772 | + } | |
| 730 | 773 | |
| 731 | 774 | |
| 732 | 775 | this.$refs["form"].validate(valid => { |
| 733 | 776 | if (valid) { |
| 777 | + let query = { | |
| 778 | + "page": 1, | |
| 779 | + "size": 9999, | |
| 780 | + "auditStatus": 1, | |
| 781 | + }; | |
| 782 | + | |
| 783 | + this.form.companys = companyNames; | |
| 784 | + | |
| 785 | + if(this.form.type == 0){ | |
| 786 | + | |
| 787 | + query.constructionSiteID = [this.form.objectId]; | |
| 788 | + | |
| 789 | + }else{ | |
| 790 | + query.earthSiteID= [this.form.objectId]; | |
| 791 | + } | |
| 792 | + | |
| 793 | + contractList(query).then(res => { | |
| 794 | + this.contractList = res.result.list; | |
| 734 | 795 | |
| 735 | 796 | let racts = []; |
| 736 | 797 | let ractsName = []; |
| ... | ... | @@ -773,6 +834,7 @@ export default { |
| 773 | 834 | |
| 774 | 835 | if (this.form.id != null) { |
| 775 | 836 | if (this.queryParams.pageStatus == 1) { |
| 837 | + | |
| 776 | 838 | updateThreestep(this.form).then(response => { |
| 777 | 839 | this.msgSuccess("ๆไบคๆๅ"); |
| 778 | 840 | this.open = false; |
| ... | ... | @@ -793,10 +855,8 @@ export default { |
| 793 | 855 | } |
| 794 | 856 | }); |
| 795 | 857 | } else { |
| 796 | - this.form.companys = this.form.companys + ""; | |
| 797 | 858 | this.form.companyTrucks = this.form.companyTrucks + ""; |
| 798 | 859 | |
| 799 | - | |
| 800 | 860 | for (let i = 0; i < 13; i++) { |
| 801 | 861 | if (this.form["img" + i]) { |
| 802 | 862 | this.form["img" + i] = this.form["img" + i] + ""; |
| ... | ... | @@ -851,14 +911,11 @@ export default { |
| 851 | 911 | } |
| 852 | 912 | }) |
| 853 | 913 | } |
| 914 | + }); | |
| 915 | + | |
| 854 | 916 | } |
| 855 | 917 | }); |
| 856 | 918 | }, |
| 857 | - loadMore(n) { | |
| 858 | - // nๆฏ้ป่ฎคๅๅงๅฑ็คบ็ๆกๆฐไผๅจๆธฒๆ็ๆถๅๅฐฑๅฏไปฅ่ทๅ,ๅ ทไฝๅฏไปฅๆlogๆฅ็ | |
| 859 | - // elementuiไธๆ่ถ ่ฟ7ๆกๆไผๅบๆปๅจๆก,ๅฆๆๅๅงไธๅบๆปๅจๆกๆ ๆณ่งฆๅloadMoreๆนๆณ | |
| 860 | - return () => (this.rangeNumber += 5); // ๆฏๆฌกๆปๅจๅฐๅบ้จๅฏไปฅๆฐๅขๆกๆฐ ๅฏ่ชๅฎไน | |
| 861 | - }, | |
| 862 | 919 | /** ๅ ้คๆ้ฎๆไฝ */ |
| 863 | 920 | handleDelete(row) { |
| 864 | 921 | const ids = row.id || this.ids; |
| ... | ... | @@ -885,26 +942,10 @@ export default { |
| 885 | 942 | }).then(response => { |
| 886 | 943 | this.download(response.message); |
| 887 | 944 | }) |
| 945 | + }, | |
| 946 | + checkUpdate(value){ | |
| 947 | + this.$forceUpdate(); | |
| 888 | 948 | } |
| 889 | 949 | }, |
| 890 | - directives:{ | |
| 891 | - 'el-select-loadmore':(el, binding) => { | |
| 892 | - // ่ทๅelement-uiๅฎไนๅฅฝ็scroll็ๅญ | |
| 893 | - const SELECTWRAP_DOM = el.querySelector(".el-select-dropdown .el-select-dropdown__wrap"); | |
| 894 | - if(SELECTWRAP_DOM){ | |
| 895 | - SELECTWRAP_DOM.addEventListener("scroll", function () { | |
| 896 | - /** | |
| 897 | - * scrollHeight ่ทๅๅ ็ด ๅ ๅฎน้ซๅบฆ(ๅช่ฏป) | |
| 898 | - * scrollTop ่ทๅๆ่ ่ฎพ็ฝฎๅ ็ด ็ๅ็งปๅผ, | |
| 899 | - * ๅธธ็จไบ:่ฎก็ฎๆปๅจๆก็ไฝ็ฝฎ, ๅฝไธไธชๅ ็ด ็ๅฎนๅจๆฒกๆไบง็ๅ็ดๆนๅ็ๆปๅจๆก, ้ฃๅฎ็scrollTop็ๅผ้ป่ฎคไธบ0. | |
| 900 | - * clientHeight ่ฏปๅๅ ็ด ็ๅฏ่ง้ซๅบฆ(ๅช่ฏป) | |
| 901 | - * ๅฆๆๅ ็ด ๆปๅจๅฐๅบ, ไธ้ข็ญๅผ่ฟๅtrue, ๆฒกๆๅ่ฟๅfalse: | |
| 902 | - * ele.scrollHeight - ele.scrollTop === ele.clientHeight; | |
| 903 | - */ | |
| 904 | - const condition = this.scrollHeight - this.scrollTop <= this.clientHeight; | |
| 905 | - if (condition) binding.value(); | |
| 906 | - }); | |
| 907 | - } | |
| 908 | - }, | |
| 909 | - } | |
| 950 | + | |
| 910 | 951 | }; | ... | ... |
trash-ui/src/api/truck_active.js
| ... | ... | @@ -19,7 +19,8 @@ import { |
| 19 | 19 | mainworkcompany, |
| 20 | 20 | getConstructionTruck, |
| 21 | 21 | constructionById, |
| 22 | - truckList | |
| 22 | + truckList, | |
| 23 | + getTruckList | |
| 23 | 24 | } from "@/api/dict"; |
| 24 | 25 | |
| 25 | 26 | export default { |
| ... | ... | @@ -95,9 +96,16 @@ export default { |
| 95 | 96 | company: null, |
| 96 | 97 | openActivateTime: false, |
| 97 | 98 | isLoading: false, |
| 99 | + simpleName:null, | |
| 98 | 100 | }; |
| 99 | 101 | }, |
| 100 | 102 | created() { |
| 103 | + | |
| 104 | + | |
| 105 | + // if(this.$store.getters.name.indexOf("ๆธฃๅ") == -1){ | |
| 106 | + // this.simpleName = this.$store.getters.name; | |
| 107 | + // } | |
| 108 | + | |
| 101 | 109 | this.getList(0); |
| 102 | 110 | }, |
| 103 | 111 | methods: { |
| ... | ... | @@ -131,7 +139,6 @@ export default { |
| 131 | 139 | }, |
| 132 | 140 | getCompany(value) { |
| 133 | 141 | let item; |
| 134 | - | |
| 135 | 142 | for (let i in this.constList) { |
| 136 | 143 | if (this.constList[i].name == value) { |
| 137 | 144 | this.construction = this.constList[i]; |
| ... | ... | @@ -142,43 +149,42 @@ export default { |
| 142 | 149 | this.companyList = []; |
| 143 | 150 | this.truckList = []; |
| 144 | 151 | |
| 152 | + | |
| 145 | 153 | constructionById(item.objectId).then(res => { |
| 146 | 154 | this.companyList.push({ |
| 147 | 155 | id: res.result.transportCompanyId, |
| 148 | 156 | name: res.result.transportCompany |
| 149 | 157 | }); |
| 150 | - | |
| 151 | - let query = { | |
| 152 | - 'page': 1, | |
| 153 | - 'size': 9999, | |
| 154 | - 'dishonestState': 0, | |
| 155 | - 'valid': 0 | |
| 158 | + | |
| 159 | + | |
| 160 | + let param = { | |
| 161 | + companyId:res.result.transportCompanyId, | |
| 162 | + auditStatus:1, | |
| 163 | + dishonestState:0 | |
| 156 | 164 | } |
| 157 | 165 | |
| 158 | - let ids = []; | |
| 159 | - | |
| 160 | - ids.push(item.transportCompanyId); | |
| 161 | - | |
| 162 | - query.companyID = ids + ""; | |
| 163 | - query.valid = 0; | |
| 164 | - | |
| 165 | - getConstructionTruck(item.id).then(res => { | |
| 166 | - for (let i in res.result) { | |
| 167 | - this.companyList.push({id: res.result[i].companyId, name: res.result[i].companyName}); | |
| 168 | - for (let j in res.result[i].vehicleList) { | |
| 169 | - this.truckList.push({ | |
| 170 | - id: res.result[i].vehicleList[j].id, | |
| 171 | - licenseplateNo: res.result[i].vehicleList[j].licenseplateNo, | |
| 172 | - companyName: res.result[i].companyName | |
| 173 | - }); | |
| 166 | + | |
| 167 | + for(let i in res.result.unitCompanyList){ | |
| 168 | + let unit = res.result.unitCompanyList[i]; | |
| 169 | + | |
| 170 | + let today = new Date().getTime(); | |
| 171 | + if(new Date(unit.startTime).getTime() > today || new Date(unit.endTime).getTime() < today){ | |
| 172 | + continue; | |
| 174 | 173 | } |
| 174 | + param.companyId += "," + unit.companyId; | |
| 175 | + | |
| 176 | + this.companyList.push({ | |
| 177 | + id: unit.companyId, | |
| 178 | + name: unit.companyName | |
| 179 | + }); | |
| 180 | + | |
| 181 | + } | |
| 182 | + | |
| 183 | + getTruckList(param).then(tres=>{ | |
| 184 | + for(let i = 0;i< tres.result.length;i++){; | |
| 185 | + this.truckList.push({licenseplateNo:tres.result[i].licenseplateNo,id:tres.result[i].id,companyName:tres.result[i].companyName}); | |
| 175 | 186 | } |
| 176 | - truckList(query).then(res => { | |
| 177 | - for (let i in res.result.list) { | |
| 178 | - this.truckList.push(res.result.list[i]); | |
| 179 | - } | |
| 180 | - }); | |
| 181 | - }); | |
| 187 | + }) | |
| 182 | 188 | }); |
| 183 | 189 | |
| 184 | 190 | |
| ... | ... | @@ -246,27 +252,30 @@ export default { |
| 246 | 252 | submitForm() { |
| 247 | 253 | this.$refs["form"].validate(valid => { |
| 248 | 254 | if (valid) { |
| 249 | - | |
| 255 | + let data = { | |
| 256 | + objectId: "", | |
| 257 | + licensePlate: "", | |
| 258 | + constructionId:this.construction.objectId, | |
| 259 | + construction: this.construction.name, | |
| 260 | + earthsite: this.construction.earthsitesName, | |
| 261 | + status: 0, | |
| 262 | + company: this.form.company, | |
| 263 | + } | |
| 250 | 264 | for (var i in this.form.licensePlate) { |
| 251 | 265 | for (let j in this.truckList) { |
| 252 | 266 | if (this.form.licensePlate[i] == this.truckList[j].id) { |
| 253 | 267 | |
| 254 | - let data = { | |
| 255 | - objectId: this.form.licensePlate[i], | |
| 256 | - licensePlate: this.truckList[j].licenseplateNo, | |
| 257 | - construction: this.construction.name, | |
| 258 | - earthsite: this.construction.earthsitesName, | |
| 259 | - status: 0, | |
| 260 | - company: this.form.company, | |
| 261 | - } | |
| 262 | - addTruckActivate(data).then(response => { | |
| 263 | - this.msgSuccess("ๆฐๅขๆๅ"); | |
| 264 | - this.open = false; | |
| 265 | - this.getList(); | |
| 266 | - }); | |
| 268 | + data.objectId += this.form.licensePlate[i] + ","; | |
| 269 | + data.licensePlate += this.truckList[j].licenseplateNo + ","; | |
| 270 | + | |
| 267 | 271 | } |
| 268 | 272 | } |
| 269 | 273 | } |
| 274 | + addTruckActivate(data).then(response => { | |
| 275 | + this.msgSuccess("ๆฐๅขๆๅ"); | |
| 276 | + this.open = false; | |
| 277 | + this.getList(); | |
| 278 | + }); | |
| 270 | 279 | } |
| 271 | 280 | }); |
| 272 | 281 | }, | ... | ... |
trash-ui/src/api/vio_casefile.js
| ... | ... | @@ -77,9 +77,25 @@ export default { |
| 77 | 77 | violationType: [ |
| 78 | 78 | {required: true, message: "ๅฟ ๅกซ", trigger: "blur"} |
| 79 | 79 | ], |
| 80 | + projectName: [{ | |
| 81 | + required: true, | |
| 82 | + message: "ๅฟ ๅกซ", | |
| 83 | + trigger: "blur" | |
| 84 | + }], | |
| 85 | + describe: [{ | |
| 86 | + required: true, | |
| 87 | + message: "ๅฟ ๅกซ", | |
| 88 | + trigger: "blur" | |
| 89 | + }], | |
| 90 | + companyName: [{ | |
| 91 | + required: true, | |
| 92 | + message: "ๅฟ ๅกซ", | |
| 93 | + trigger: "blur" | |
| 94 | + }], | |
| 80 | 95 | }, |
| 81 | 96 | caseType: [{code: 0, name: "่ฟๅ ฅ้ไธ็จ่ฝฆ่พ"}, |
| 82 | - {code: 1, name: "ไธๆ ่ฝฆ่พ่ฟ่พ"}, | |
| 97 | + {code: 1, name: "ๆ ่ฎธๅฏๆ็ปญ๏ผๅทฅ๏ผ"}, | |
| 98 | + {code: 2, name: "ๆ ่ฎธๅฏๆ็ปญ๏ผๆถ๏ผ"}, | |
| 83 | 99 | {code: 3, name: "้ปๅ่ฆ็ๆ ๅต"}, |
| 84 | 100 | {code: 4, name: "ๅบๅ ฅๅฃ่ทฏ้ขๆฑกๆ"}, |
| 85 | 101 | {code: 5, name: "ๅบๅ ฅๅฃ้่ทฏ็กฌๅ"}, |
| ... | ... | @@ -114,7 +130,7 @@ export default { |
| 114 | 130 | companyList: [], |
| 115 | 131 | remoteQueryData: { |
| 116 | 132 | "page": 1, |
| 117 | - "size": 9999 | |
| 133 | + "size": 100 | |
| 118 | 134 | }, |
| 119 | 135 | areas: [], |
| 120 | 136 | data: {}, |
| ... | ... | @@ -175,6 +191,18 @@ export default { |
| 175 | 191 | this.getList(); |
| 176 | 192 | }, |
| 177 | 193 | methods: { |
| 194 | + getRemoteDate(value){ | |
| 195 | + this.remoteQueryData.name =value; | |
| 196 | + constructionsitesList(this.remoteQueryData).then(res => { | |
| 197 | + this.projectNameList = res.result.list; | |
| 198 | + earthsitesList(this.remoteQueryData).then(res => { | |
| 199 | + for (var i in res.result.list) { | |
| 200 | + this.projectNameList.push(res.result.list[i]); | |
| 201 | + } | |
| 202 | + }); | |
| 203 | + }); | |
| 204 | + | |
| 205 | + }, | |
| 178 | 206 | selectArea(item) { |
| 179 | 207 | |
| 180 | 208 | this.form.owningRegion = item.name; |
| ... | ... | @@ -369,6 +397,18 @@ export default { |
| 369 | 397 | this.isLoading = false |
| 370 | 398 | }, 200) |
| 371 | 399 | }, |
| 400 | + getCompanys(value){ | |
| 401 | + | |
| 402 | + let query = { | |
| 403 | + name:value, | |
| 404 | + page:1, | |
| 405 | + size:100 | |
| 406 | + }; | |
| 407 | + | |
| 408 | + companyList(query).then(res => { | |
| 409 | + this.companyList = res.result.list; | |
| 410 | + }); | |
| 411 | + }, | |
| 372 | 412 | companyLoadOptions(query) { |
| 373 | 413 | // ๆ นๆฎ่พๅ ฅ็ๅ ณ้ฎๅญqueryๅผๆญฅๅ ่ฝฝ้้กนๆฐๆฎ |
| 374 | 414 | this.isLoadingCompany = true | ... | ... |
trash-ui/src/api/warningInfo.js
| ... | ... | @@ -102,6 +102,21 @@ export default { |
| 102 | 102 | message: "ๅฟ ๅกซ", |
| 103 | 103 | trigger: "blur" |
| 104 | 104 | }], |
| 105 | + projectName: [{ | |
| 106 | + required: true, | |
| 107 | + message: "ๅฟ ๅกซ", | |
| 108 | + trigger: "blur" | |
| 109 | + }], | |
| 110 | + describe: [{ | |
| 111 | + required: true, | |
| 112 | + message: "ๅฟ ๅกซ", | |
| 113 | + trigger: "blur" | |
| 114 | + }], | |
| 115 | + companyName: [{ | |
| 116 | + required: true, | |
| 117 | + message: "ๅฟ ๅกซ", | |
| 118 | + trigger: "blur" | |
| 119 | + }], | |
| 105 | 120 | }, |
| 106 | 121 | caseType: [{ |
| 107 | 122 | code: 0, |
| ... | ... | @@ -416,6 +431,17 @@ export default { |
| 416 | 431 | const code = `${year}${month}${day}${hour}${minute}${second}${millisecond}`; |
| 417 | 432 | return code; |
| 418 | 433 | }, |
| 434 | + getCompanys(value){ | |
| 435 | + let query = { | |
| 436 | + name:value, | |
| 437 | + page:1, | |
| 438 | + size:100 | |
| 439 | + }; | |
| 440 | + | |
| 441 | + companyList(query).then(res => { | |
| 442 | + this.companyList = res.result.list; | |
| 443 | + }); | |
| 444 | + }, | |
| 419 | 445 | projectNameLoadOptions(query) { |
| 420 | 446 | // ๆ นๆฎ่พๅ ฅ็ๅ ณ้ฎๅญqueryๅผๆญฅๅ ่ฝฝ้้กนๆฐๆฎ |
| 421 | 447 | this.isLoading = true | ... | ... |
trash-ui/src/layout/index5.vue renamed to trash-ui/src/layout/index33.vue
trash-ui/src/main.js
| ... | ... | @@ -37,6 +37,9 @@ Vue.prototype.handleTree = handleTree |
| 37 | 37 | Vue.prototype.parseStatus = parseStatus |
| 38 | 38 | Vue.prototype.checkPer = checkPermi |
| 39 | 39 | |
| 40 | +Vue.prototype.remoteFrame = "http://183.66.242.6:14601" | |
| 41 | +// Vue.prototype.remoteFrame = "http://175.6.47.84:8008" | |
| 42 | + | |
| 40 | 43 | Vue.prototype.msgSuccess = function (msg) { |
| 41 | 44 | this.$message({ showClose: true, message: msg, type: "success" }); |
| 42 | 45 | } | ... | ... |
trash-ui/src/views/activiti/task/companyInfo.vue
| ... | ... | @@ -71,7 +71,7 @@ import store from "@/store"; |
| 71 | 71 | id = this.businessKey; |
| 72 | 72 | } |
| 73 | 73 | |
| 74 | - let http = "http://183.66.242.6:14601"; | |
| 74 | + let http = this.remoteFrame; | |
| 75 | 75 | |
| 76 | 76 | if(this.businessType == 0){ |
| 77 | 77 | this.src = http + "/single/#/enterprise-information/information-detail?id=" + id; | ... | ... |
trash-ui/src/views/activiti/task/index.vue
| ... | ... | @@ -11,19 +11,16 @@ |
| 11 | 11 | </el-option> |
| 12 | 12 | </el-select> |
| 13 | 13 | |
| 14 | - <el-select v-model="queryParams.name" filterable reserve-keyword placeholder="ๅ็งฐ"> | |
| 15 | - <el-option label="ๅ จ้จ" value=""/> | |
| 14 | + <el-select v-model="queryParams.name" filterable allow-create reserve-keyword :filter-method="remoteName" placeholder="ๅ็งฐ"> | |
| 16 | 15 | <el-option v-for="item in names" :label="item" :value="item"> |
| 17 | 16 | </el-option> |
| 18 | 17 | </el-select> |
| 19 | 18 | |
| 20 | 19 | <el-select v-model="queryParams.prev" filterable reserve-keyword placeholder="ไธไธ่็น"> |
| 21 | - <el-option label="ๅ จ้จ" value=""/> | |
| 22 | 20 | <el-option v-for="item in prev" :label="item.name" :value="item.name"> |
| 23 | 21 | </el-option> |
| 24 | 22 | </el-select> |
| 25 | 23 | <el-select v-model="queryParams.type" filterable reserve-keyword> |
| 26 | - <el-option label="ๅ จ้จ" value=""/> | |
| 27 | 24 | <el-option label="ๅปบ็ญๅๅพ่ฎธๅฏ่ฏๅฎกๆน" value="workflow_constructsite"/> |
| 28 | 25 | <el-option label="ๆถ็บณๅๅ็ณๆฅๅคๆก" value="workflow_conract"/> |
| 29 | 26 | <el-option label="ๅค็ๅบๆๅคๆก" value="workflow_earthsites"/> |
| ... | ... | @@ -616,7 +613,7 @@ |
| 616 | 613 | </style> |
| 617 | 614 | |
| 618 | 615 | <script> |
| 619 | -import {formDataSave, formDataShow, listTask} from "@/api/activiti/task"; | |
| 616 | +import {formDataSave, formDataShow, listTask,getNames} from "@/api/activiti/task"; | |
| 620 | 617 | |
| 621 | 618 | import {historyFromData} from '@/api/activiti/historyFormdata' |
| 622 | 619 | |
| ... | ... | @@ -704,6 +701,7 @@ export default { |
| 704 | 701 | taskName: null, |
| 705 | 702 | // ๆฅ่ฏขๅๆฐ |
| 706 | 703 | queryParams: { |
| 704 | + name:null, | |
| 707 | 705 | pageNum: 1, |
| 708 | 706 | pageSize: 10, |
| 709 | 707 | role: null, |
| ... | ... | @@ -795,9 +793,23 @@ export default { |
| 795 | 793 | getDict(role).then(res => { |
| 796 | 794 | this.roles = res.result; |
| 797 | 795 | }); |
| 798 | - this.getList(); | |
| 796 | + | |
| 797 | + listTask(this.queryParams).then(response => { | |
| 798 | + this.taskList = response.rows; | |
| 799 | + this.names = response.names; | |
| 800 | + this.total = response.total; | |
| 801 | + this.loading = false; | |
| 802 | + }); | |
| 799 | 803 | }, |
| 800 | 804 | methods: { |
| 805 | + remoteName(value){ | |
| 806 | + getNames(value).then(res=>{ | |
| 807 | + | |
| 808 | + this.names = res.data; | |
| 809 | + | |
| 810 | + this.queryParams.name = value; | |
| 811 | + }); | |
| 812 | + }, | |
| 801 | 813 | resetQuery(){ |
| 802 | 814 | this.queryParams = {}; |
| 803 | 815 | this.queryParams.pageNum=1; |
| ... | ... | @@ -907,8 +919,6 @@ export default { |
| 907 | 919 | this.loading = true; |
| 908 | 920 | listTask(this.queryParams).then(response => { |
| 909 | 921 | this.taskList = response.rows; |
| 910 | - if(!this.names) | |
| 911 | - this.names = response.names; | |
| 912 | 922 | this.total = response.total; |
| 913 | 923 | this.loading = false; |
| 914 | 924 | }); |
| ... | ... | @@ -929,7 +939,6 @@ export default { |
| 929 | 939 | this.conferenceOpen = false; |
| 930 | 940 | this.construct = false; |
| 931 | 941 | this.leaveApplicationOpen = false; |
| 932 | - | |
| 933 | 942 | this.company = false; |
| 934 | 943 | this.driver = false; |
| 935 | 944 | this.vehicle = false; |
| ... | ... | @@ -1173,20 +1182,7 @@ export default { |
| 1173 | 1182 | return; |
| 1174 | 1183 | } |
| 1175 | 1184 | |
| 1176 | - if (this.definitionKey == "workflow_conract") { | |
| 1177 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 1178 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1179 | - this.contract = false; | |
| 1180 | - this.getList(); | |
| 1181 | - }); | |
| 1182 | - } | |
| 1183 | - if (this.definitionKey == "workflow_earthsites") { | |
| 1184 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 1185 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1186 | - this.earthsites = false; | |
| 1187 | - this.getList(); | |
| 1188 | - }); | |
| 1189 | - } | |
| 1185 | + | |
| 1190 | 1186 | if (this.definitionKey == "workflow_caseoffline") { |
| 1191 | 1187 | |
| 1192 | 1188 | let postData = {}; |
| ... | ... | @@ -1300,16 +1296,13 @@ export default { |
| 1300 | 1296 | }); |
| 1301 | 1297 | } |
| 1302 | 1298 | |
| 1303 | - if (this.definitionKey.indexOf("supervision") > -1) { | |
| 1304 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 1305 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1306 | - this.supervisionOpen = false; | |
| 1307 | - this.getList(); | |
| 1308 | - }); | |
| 1309 | - } | |
| 1310 | - if (this.definitionKey == "workflow_company" || | |
| 1299 | + if ( | |
| 1300 | + this.definitionKey.indexOf("supervision") > -1 || | |
| 1301 | + this.definitionKey == "workflow_company" || | |
| 1311 | 1302 | this.definitionKey == "workflow_driver" || |
| 1312 | 1303 | this.definitionKey == "workflow_vehicle" || |
| 1304 | + this.definitionKey == "workflow_earthsites" || | |
| 1305 | + this.definitionKey == "workflow_conract" || | |
| 1313 | 1306 | this.definitionKey == "workflow_constructsite_edit") { |
| 1314 | 1307 | formDataSave(this.id, this.form.formData).then(response => { |
| 1315 | 1308 | this.msgSuccess("ๅฎกๆนๆๅ"); | ... | ... |
trash-ui/src/views/activiti/taskhistory/index.vue
| ... | ... | @@ -111,13 +111,13 @@ |
| 111 | 111 | <!-- ๅนณๅฐ่ฟ่งไฟกๆฏ --> |
| 112 | 112 | <el-dialog :title="title" :visible.sync="violationCaseFile" width="850px" append-to-body |
| 113 | 113 | :close-on-click-modal="false"> |
| 114 | - <violationCaseFileInfo :idInfo="businessKey" v-if="violationCaseFile"/> | |
| 114 | + <violationCaseFileInfo :idInfo="businessKey" v-if="violationCaseFile" :entryType="0"/> | |
| 115 | 115 | </el-dialog> |
| 116 | 116 | |
| 117 | 117 | <!-- ่ฟ่ง้ข่ญฆไฟกๆฏ --> |
| 118 | 118 | <el-dialog :title="title" :visible.sync="violationCaseFile1" width="850px" append-to-body |
| 119 | 119 | :close-on-click-modal="false"> |
| 120 | - <violationWarningInformationInfo :idInfo="businessKey" v-if="violationCaseFile1"/> | |
| 120 | + <violationWarningInformationInfo :idInfo="businessKey" v-if="violationCaseFile1" :entryType="0"/> | |
| 121 | 121 | </el-dialog> |
| 122 | 122 | |
| 123 | 123 | <el-dialog :title="title" :visible.sync="supervisionOpen" width="700px" append-to-body | ... | ... |
trash-ui/src/views/business/threestep/index.vue
| ... | ... | @@ -24,7 +24,7 @@ |
| 24 | 24 | </el-form-item> |
| 25 | 25 | <el-form-item label="ๆๅฑๅบๅ" prop="place"> |
| 26 | 26 | <el-select v-model="queryParams.place" placeholder="่ฏท้ๆฉๆๅฑๅบๅ " size="small"> |
| 27 | - <el-option v-for="item in areas" :label="item.name" :value="item.code" :key="item.code" /> | |
| 27 | + <el-option v-for="item in areas" :label="item.name" :value="item.code" /> | |
| 28 | 28 | </el-select> |
| 29 | 29 | </el-form-item> |
| 30 | 30 | |
| ... | ... | @@ -113,7 +113,7 @@ |
| 113 | 113 | <el-col :span="12"> |
| 114 | 114 | <el-form-item label="ๆๅฑๅบๅ" prop="place"> |
| 115 | 115 | <el-select v-model="form.place" placeholder="่ฏท้ๆฉๆๅฑๅบๅ" filterable reserve-keyword @clear="areaClear" @change="selectArea"> |
| 116 | - <el-option v-for="item in areas" :label="item.name" :value="item.code" :key="item.code"> | |
| 116 | + <el-option v-for="item in areas" :label="item.name" :value="item.code" > | |
| 117 | 117 | </el-option> |
| 118 | 118 | </el-select> |
| 119 | 119 | </el-form-item> |
| ... | ... | @@ -122,20 +122,19 @@ |
| 122 | 122 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 123 | 123 | <el-col > |
| 124 | 124 | <el-form-item :label="labelName" prop="name"> |
| 125 | - <el-select v-model="form.name" filterable reserve-keyword @change="getObjId" v-el-select-loadmore="loadMore(rangeNumber)"> | |
| 126 | - <el-option v-for="item in remoteData.slice(0, rangeNumber)" :label="item.name" | |
| 127 | - :value="item.name" :key="item.id" v-if="!form.place || item.areaCode == form.place"> | |
| 125 | + <el-select v-model="form.name" filterable reserve-keyword @change="getObjId" :filter-method="getObjId"> | |
| 126 | + <el-option v-for="item in remoteData" :label="item.name" | |
| 127 | + :value="item.name" v-if="!form.place || item.areaCode == form.place"> | |
| 128 | 128 | </el-option> |
| 129 | 129 | </el-select> |
| 130 | 130 | </el-form-item> |
| 131 | 131 | </el-col> |
| 132 | 132 | </el-row> |
| 133 | - <el-row type="flex" justify="center" v-if="form.type == 0" > | |
| 133 | + <!-- <el-row type="flex" justify="center" v-if="form.type == 0" > | |
| 134 | 134 | <el-col :span="24" > |
| 135 | 135 | <el-form-item label="่ฟ่พไผไธ" prop="companys"> |
| 136 | 136 | <el-select v-model="form.companys" filterable multiple @change="checkCompany" > |
| 137 | - <el-option v-for="item in companyList" :label="item.name" :value="item.name" :key="item.id" | |
| 138 | - /> | |
| 137 | + <el-option v-for="item in companyList" :label="item.name" :value="item.name" /> | |
| 139 | 138 | </el-select> |
| 140 | 139 | </el-form-item> |
| 141 | 140 | </el-col> |
| ... | ... | @@ -144,12 +143,13 @@ |
| 144 | 143 | <el-row type="flex" justify="center" v-if="form.type == 0" > |
| 145 | 144 | <el-col :span="24" > |
| 146 | 145 | <el-form-item label="่ฟ่พ่ฝฆ่พ" prop="trucks" > |
| 147 | - <el-checkbox-group v-model="form.trucks" style="max-height: 200px;overflow: auto;"> | |
| 148 | - <el-checkbox :label="item.licenseplateNo" v-for="item in truckList" v-if="form.companys && (form.companys.indexOf(item.companyName) > -1)"/> | |
| 146 | + <el-input v-model="truckName" /> | |
| 147 | + <el-checkbox-group v-model="form.trucks" style="max-height: 200px;overflow: auto;" @change="checkUpdate"> | |
| 148 | + <el-checkbox :label="item.licenseplateNo" v-for="item in truckList" v-if="(!truckName || item.licenseplateNo.indexOf(truckName) > -1) &&form.companys && (form.companys.indexOf(item.companyName) > -1)" /> | |
| 149 | 149 | </el-checkbox-group> |
| 150 | 150 | </el-form-item> |
| 151 | 151 | </el-col> |
| 152 | - </el-row> | |
| 152 | + </el-row> --> | |
| 153 | 153 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 154 | 154 | <el-col :span="12"> |
| 155 | 155 | <el-form-item label="็ฐๅบ่ด่ดฃไบบ" prop="person"> |
| ... | ... | @@ -416,7 +416,7 @@ |
| 416 | 416 | <video width="100%" controls="controls" height="100%" :src="item.url"></video> |
| 417 | 417 | </div> |
| 418 | 418 | <el-input v-model="form.attchItem1" type="hidden"></el-input> |
| 419 | - <p v-for="(img,index) in form.attchItem1">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(1,img,91)" style="color:red"> x</a></p> | |
| 419 | + <p v-for="(img,index) in form.attchItem1">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(91,img)" style="color:red"> x</a></p> | |
| 420 | 420 | </el-col> |
| 421 | 421 | <el-col :span="8"> |
| 422 | 422 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(92)">้ไปถ2</a> |
| ... | ... | @@ -432,7 +432,7 @@ |
| 432 | 432 | <video width="100%" controls="controls" height="100%" :src="item.url"></video> |
| 433 | 433 | </div> |
| 434 | 434 | <el-input v-model="form.attchItem2" type="hidden"></el-input> |
| 435 | - <p v-for="(img,index) in form.attchItem2">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(2,img,92)" style="color:red"> x</a></p> | |
| 435 | + <p v-for="(img,index) in form.attchItem2">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(92,img)" style="color:red"> x</a></p> | |
| 436 | 436 | </el-col> |
| 437 | 437 | <el-col :span="8"> |
| 438 | 438 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(93)">้ไปถ3</a> |
| ... | ... | @@ -448,7 +448,7 @@ |
| 448 | 448 | <video width="100%" controls="controls" height="100%" :src="item.url"></video> |
| 449 | 449 | </div> |
| 450 | 450 | <el-input v-model="form.attchItem3" type="hidden"></el-input> |
| 451 | - <p v-for="(img,index) in form.attchItem3">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(3,img,93)" style="color:red"> x</a></p> | |
| 451 | + <p v-for="(img,index) in form.attchItem3">{{img.split("/")[img.split("/").length -1]}}<a @click="removeAttchItem(93,img)" style="color:red"> x</a></p> | |
| 452 | 452 | </el-col> |
| 453 | 453 | </el-row> |
| 454 | 454 | </el-form> | ... | ... |
trash-ui/src/views/business/truckActivate/index.vue
| ... | ... | @@ -45,7 +45,8 @@ |
| 45 | 45 | <el-row :gutter="10" class="mb8"> |
| 46 | 46 | <el-col :span="1.5"> |
| 47 | 47 | <el-button |
| 48 | - v-if="this.queryParams.status==0 && checkPer(['business.supervision.truckActivate.active'])" | |
| 48 | + v-if="this.queryParams.status==0 && checkPer(['business.supervision.truckActivate.active']) | |
| 49 | + && new Date().getHours() > 7 && new Date().getHours() < 24" | |
| 49 | 50 | type="primary" |
| 50 | 51 | size="mini" |
| 51 | 52 | @click="handleAdd" |
| ... | ... | @@ -93,18 +94,20 @@ |
| 93 | 94 | <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> |
| 94 | 95 | <el-form ref="form" :model="form" :rules="rules" label-width="80px"> |
| 95 | 96 | <el-form-item label="ๆๅฑๅทฅๅฐ" prop="construction"> |
| 96 | - <el-select v-model="form.construction" placeholder="่ฏท้ๆฉๆๅฑๅทฅๅฐ" @change="getCompany"> | |
| 97 | + <el-select v-model="form.construction" placeholder="่ฏท้ๆฉๆๅฑๅทฅๅฐ" filterable reserve-keyword @change="getCompany"> | |
| 97 | 98 | <el-option v-for="item in constList" :label="item.name" :value="item.name" ></el-option> |
| 98 | 99 | </el-select> |
| 99 | 100 | </el-form-item> |
| 100 | 101 | <el-form-item label="ๆๅฑไผไธ" prop="company"> |
| 101 | 102 | <el-select v-model="form.company" filterable reserve-keyword @change="clearTruck"> |
| 102 | - <el-option v-for="item in companyList" :label="item.name" :value="item.name" /> | |
| 103 | + <el-option v-for="item in companyList" :label="item.name" :value="item.name" | |
| 104 | + v-if="!simpleName || item.name.indexOf(simpleName) > -1" | |
| 105 | + /> | |
| 103 | 106 | </el-select> |
| 104 | 107 | </el-form-item> |
| 105 | 108 | <el-form-item label="่ฝฆ็ๅท" prop="licensePlate"> |
| 106 | 109 | <el-select v-model="form.licensePlate" placeholder="่ฏท้ๆฉ่ฝฆ่พ" multiple filterable> |
| 107 | - <el-option v-if="!form.company || form.company == item.companyName" | |
| 110 | + <el-option v-if="(form.company && form.company == item.companyName)" | |
| 108 | 111 | v-for="item in truckList" |
| 109 | 112 | :label="item.licenseplateNo" |
| 110 | 113 | :value="item.id"/> | ... | ... |
trash-ui/src/views/caseOffline/caseOffline/index.vue
| ... | ... | @@ -97,9 +97,8 @@ |
| 97 | 97 | </el-select> |
| 98 | 98 | </el-form-item> |
| 99 | 99 | <el-form-item :label="form.siteType==0?'ๅทฅๅฐๅ็งฐ':'ๅค็ๅบๆๅ็งฐ'" prop="siteName"> |
| 100 | - <el-select v-model="form.siteName" placeholder="่ฏท้ๆฉ็ฑปๅ" allow-create filterable> | |
| 101 | - <el-option v-for="item in data[form.siteType]" :label="item.name" :value="item.name" | |
| 102 | - @native.click="getSite(item)"/> | |
| 100 | + <el-select v-model="form.siteName" placeholder="่ฏท้ๆฉ็ฑปๅ" allow-create filterable @change="getSite(item)"> | |
| 101 | + <el-option v-for="item in data[form.siteType]" :label="item.name" :value="item.name"/> | |
| 103 | 102 | </el-select> |
| 104 | 103 | </el-form-item> |
| 105 | 104 | <el-form-item label="้ฎ้ขๆ่ฟฐ" prop="caseDec"> | ... | ... |
trash-ui/src/views/casefile/violationCaseFile/index.vue
| ... | ... | @@ -54,7 +54,7 @@ |
| 54 | 54 | size="mini" |
| 55 | 55 | @click="handleAdd" |
| 56 | 56 | v-hasPermi="['casefile:violationCaseFile:add']" |
| 57 | - | |
| 57 | + | |
| 58 | 58 | v-if="checkPer(['intelligencecontrols.messagemanage.enter'])" |
| 59 | 59 | >่ฟ่งๆกๅทๅฝๅ ฅ</el-button> |
| 60 | 60 | </el-col> |
| ... | ... | @@ -174,7 +174,9 @@ |
| 174 | 174 | </el-col> |
| 175 | 175 | <el-col :span="11"> |
| 176 | 176 | <el-form-item label="่ฟ่งๅฏน่ฑก" prop="projectName"> |
| 177 | - <el-select v-model="form.projectName" :filterable="true" :remote-method="projectNameLoadOptions" :loading="isLoading" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 177 | + <el-select v-model="form.projectName" :filterable="true" | |
| 178 | + :remote-method="projectNameLoadOptions" :loading="isLoading" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;" | |
| 179 | + :filter-method="getRemoteDate"> | |
| 178 | 180 | <el-option v-for="item in projectNameList" :key="item.name" :label="item.name" :value="item.name"></el-option> |
| 179 | 181 | </el-select> |
| 180 | 182 | </el-form-item> |
| ... | ... | @@ -183,7 +185,9 @@ |
| 183 | 185 | <el-row :gutter="2"> |
| 184 | 186 | <el-col :span="11"> |
| 185 | 187 | <el-form-item label="ๅ ฌๅธ" prop="companyName"> |
| 186 | - <el-select v-model="form.companyName" :filterable="true" :remote-method="companyLoadOptions" :loading="isLoadingCompany" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 188 | + <el-select v-model="form.companyName" :filterable="true" | |
| 189 | + :filter-method="getCompanys" :loading="isLoadingCompany" | |
| 190 | + placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 187 | 191 | <el-option v-for="item in companyList" :key="item.name" :label="item.name" :value="item.name"></el-option> |
| 188 | 192 | </el-select> |
| 189 | 193 | </el-form-item> | ... | ... |
trash-ui/src/views/casefile/violationWarningInformation/index.vue
| ... | ... | @@ -177,7 +177,8 @@ |
| 177 | 177 | </el-col> |
| 178 | 178 | <el-col :span="11"> |
| 179 | 179 | <el-form-item label="ไผไธๅ็งฐ" prop="companyName"> |
| 180 | - <el-select v-model="form.companyName" :filterable="true" :remote-method="companyLoadOptions" :loading="isLoadingCompany" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 180 | + <el-select v-model="form.companyName" :filterable="true" | |
| 181 | + :filter-method="getCompanys" :loading="isLoadingCompany" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 181 | 182 | <el-option v-for="item in companyList" :key="item.name" :label="item.name" :value="item.name"></el-option> |
| 182 | 183 | </el-select> |
| 183 | 184 | </el-form-item> | ... | ... |
trash-ui/src/views/daily/situation/index.vue
| ... | ... | @@ -134,7 +134,7 @@ |
| 134 | 134 | <editor v-model="form.numberOfVehicles" :min-height="192"/> |
| 135 | 135 | </el-form-item> |
| 136 | 136 | |
| 137 | - <el-form-item label="ๅนณๅฐๅ็ฑป้ข่ญฆๅผๆฏ(ๆกๅทๆ ๅต)" prop="numberOfVehicles"> | |
| 137 | + <el-form-item label="ๅนณๅฐๅ็ฑป้ข่ญฆๅผไฟกๆฏ(ๆกๅทๆ ๅต)" prop="numberOfVehicles"> | |
| 138 | 138 | <editor v-model="form.caseFileInfo" :min-height="192"/> |
| 139 | 139 | </el-form-item> |
| 140 | 140 | |
| ... | ... | @@ -184,8 +184,8 @@ |
| 184 | 184 | </el-row> |
| 185 | 185 | <el-row type="flex" justify="center" class="bd_left bd_right bd_bottom "> |
| 186 | 186 | <el-col :span="4"> <p >3</p></el-col> |
| 187 | - <el-col :span="6" class="bd_left bd_right"> <p >ๅนณๅฐๅ็ฑป้ข่ญฆๅผๆฏ(ๆกๅทๆ ๅต)</p></el-col> | |
| 188 | - <el-col :span="14"> <editor v-model="form.consumptionSiteSituation" disabled/></el-col> | |
| 187 | + <el-col :span="6" class="bd_left bd_right"> <p >ๅนณๅฐๅ็ฑป้ข่ญฆๅผไฟกๆฏ(ๆกๅทๆ ๅต)</p></el-col> | |
| 188 | + <el-col :span="14"> <editor v-model="form.caseFileInfo" disabled/></el-col> | |
| 189 | 189 | </el-row> |
| 190 | 190 | <el-row type="flex" justify="center" class="bd_left bd_right bd_bottom "> |
| 191 | 191 | <el-col :span="4"> <p >4</p></el-col> |
| ... | ... | @@ -206,7 +206,7 @@ |
| 206 | 206 | <el-row type="flex" justify="center" class="bd_left bd_right bd_bottom "> |
| 207 | 207 | <el-col :span="4"> <p >7</p></el-col> |
| 208 | 208 | <el-col :span="6" class="bd_left bd_right"> <p >็ชๅไบไปถๅค็ฝฎ็ญๅ ถไปๆ ๅต</p></el-col> |
| 209 | - <el-col :span="14"> <editor v-model="form.desc2" disabled/></el-col> | |
| 209 | + <el-col :span="14"> <editor v-model="form.desc3" disabled/></el-col> | |
| 210 | 210 | </el-row> |
| 211 | 211 | |
| 212 | 212 | <div slot="footer" class="dialog-footer" > | ... | ... |
trash-ui/src/views/h5/caseOffline/index.vue
| ... | ... | @@ -95,8 +95,8 @@ |
| 95 | 95 | </el-select> |
| 96 | 96 | </el-form-item> |
| 97 | 97 | <el-form-item :label="form.siteType==0?'ๅทฅๅฐๅ็งฐ':'ๅค็ๅบๆๅ็งฐ'" prop="siteName"> |
| 98 | - <el-select v-model="form.siteName" placeholder="่ฏท้ๆฉ็ฑปๅ" allow-create filterable> | |
| 99 | - <el-option v-for="item in data[form.siteType]" :label="item.name" :value="item.name" @native.click="getSite(item)"/> | |
| 98 | + <el-select v-model="form.siteName" placeholder="่ฏท้ๆฉ็ฑปๅ" allow-create filterable @change="getSite(item)"> | |
| 99 | + <el-option v-for="item in data[form.siteType]" :label="item.name" :value="item.name" /> | |
| 100 | 100 | </el-select> |
| 101 | 101 | </el-form-item> |
| 102 | 102 | <el-form-item label="้ฎ้ขๆ่ฟฐ" prop="caseDec"> | ... | ... |
trash-ui/src/views/h5/task/companyInfo.vue
| ... | ... | @@ -71,27 +71,26 @@ import store from "@/store"; |
| 71 | 71 | id = this.businessKey; |
| 72 | 72 | } |
| 73 | 73 | |
| 74 | - let http = "http://183.66.242.6:14601"; | |
| 74 | + let http = this.remoteFrame; | |
| 75 | 75 | |
| 76 | 76 | if(this.businessType == 0){ |
| 77 | - this.src = http + "/single/#/enterprise-information/information-detail?id=" + id; | |
| 77 | + this.src = http + "/h5/#/enterpriseInfo?enterpriseId=" + id; | |
| 78 | 78 | } |
| 79 | 79 | if(this.businessType == 1){ |
| 80 | - this.src = http + "/single/#/vehicleInformation/information-detail?id=" + id; | |
| 80 | + this.src = http + "/h5/#/vehicleDetail?id=" + id; | |
| 81 | 81 | } |
| 82 | 82 | if(this.businessType == 2){ |
| 83 | - this.src = http + "/single/#/constructionInfo/detail?id="+id+"&type=detail"; | |
| 83 | + this.src = http + "/h5/#/constructionInfo?id="+id; | |
| 84 | 84 | } |
| 85 | 85 | if(this.businessType == 3){ |
| 86 | - this.src = http + "/single/#/absorptionsitedetail?absorptionId=" + id; | |
| 86 | + this.src = http + "/h5/#/digestionSite?digestionId=" + id; | |
| 87 | 87 | } |
| 88 | 88 | if(this.businessType == 4){ |
| 89 | - this.src = http + "/single/#/contractInfo/detail?id=" + id; | |
| 89 | + this.src = http + "/h5/#/contractDetail?id=" + id; | |
| 90 | 90 | } |
| 91 | 91 | if(this.businessType == 5){ |
| 92 | - this.src = http + "/single/#/driverdetail?driverId=" + id; | |
| 92 | + this.src = http + "/h5/#/driverDetail?id=" + id; | |
| 93 | 93 | } |
| 94 | - | |
| 95 | 94 | }, |
| 96 | 95 | |
| 97 | 96 | } | ... | ... |
trash-ui/src/views/h5/task/index.vue
| ... | ... | @@ -52,12 +52,32 @@ |
| 52 | 52 | <el-row el-row style="margin-top: 20px;"> |
| 53 | 53 | <el-col :span="12"> |
| 54 | 54 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(0)">ๅฑฅ่ๆ ๅต็ ง็</a> |
| 55 | + <el-image v-for="item in slides[0]" | |
| 56 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 57 | + :src="item.url" | |
| 58 | + :preview-src-list="[item.url]" | |
| 59 | + :z-index="2000"> | |
| 60 | + </el-image> | |
| 61 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 62 | + v-for="item in videos[0]"> | |
| 63 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 64 | + </div> | |
| 55 | 65 | <el-input v-model="form.sub_img0" type="hidden"></el-input> |
| 56 | 66 | <p v-for="img in form.sub_img0">{{img.split(":")[0]}}<a @click="removeImage(0,img)" style="color:red"> x</a> |
| 57 | 67 | </p> |
| 58 | 68 | </el-col> |
| 59 | 69 | <el-col :span="12"> |
| 60 | 70 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(1)">ๆฐดๆชๆฐดๅด็ ง็</a> |
| 71 | + <el-image v-for="item in slides[1]" | |
| 72 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 73 | + :src="item.url" | |
| 74 | + :preview-src-list="[item.url]" | |
| 75 | + :z-index="2000"> | |
| 76 | + </el-image> | |
| 77 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 78 | + v-for="item in videos[1]"> | |
| 79 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 80 | + </div> | |
| 61 | 81 | <el-input v-model="form.sub_img1" type="hidden"></el-input> |
| 62 | 82 | <p v-for="img in form.sub_img1">{{img.split(":")[0]}}<a @click="removeImage(1,img)" style="color:red"> x</a> |
| 63 | 83 | </p> |
| ... | ... | @@ -66,12 +86,32 @@ |
| 66 | 86 | <el-row> |
| 67 | 87 | <el-col :span="12"> |
| 68 | 88 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(2)">็ งๆ็ ง็</a> |
| 89 | + <el-image v-for="item in slides[2]" | |
| 90 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 91 | + :src="item.url" | |
| 92 | + :preview-src-list="[item.url]" | |
| 93 | + :z-index="2000"> | |
| 94 | + </el-image> | |
| 95 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 96 | + v-for="item in videos[2]"> | |
| 97 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 98 | + </div> | |
| 69 | 99 | <el-input v-model="form.sub_img2" type="hidden"></el-input> |
| 70 | 100 | <p v-for="img in form.sub_img2">{{img.split(":")[0]}}<a @click="removeImage(2,img)" style="color:red"> x</a> |
| 71 | 101 | </p> |
| 72 | 102 | </el-col> |
| 73 | 103 | <el-col :span="12"> |
| 74 | 104 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(3)">่ง้ข็ๆง็ ง็</a> |
| 105 | + <el-image v-for="item in slides[3]" | |
| 106 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 107 | + :src="item.url" | |
| 108 | + :preview-src-list="[item.url]" | |
| 109 | + :z-index="2000"> | |
| 110 | + </el-image> | |
| 111 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 112 | + v-for="item in videos[3]"> | |
| 113 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 114 | + </div> | |
| 75 | 115 | <el-input v-model="form.sub_img3" type="hidden"></el-input> |
| 76 | 116 | <p v-for="img in form.sub_img3">{{img.split(":")[0]}}<a @click="removeImage(3,img)" style="color:red"> x</a> |
| 77 | 117 | </p> |
| ... | ... | @@ -81,6 +121,16 @@ |
| 81 | 121 | <el-col :span="12"> |
| 82 | 122 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(4)">ๆด่ฝฆๆบ็ ง็</a> |
| 83 | 123 | <el-input v-model="form.sub_img4" type="hidden"></el-input> |
| 124 | + <el-image v-for="item in slides[4]" | |
| 125 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 126 | + :src="item.url" | |
| 127 | + :preview-src-list="[item.url]" | |
| 128 | + :z-index="2000"> | |
| 129 | + </el-image> | |
| 130 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 131 | + v-for="item in videos[4]"> | |
| 132 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 133 | + </div> | |
| 84 | 134 | <p v-for="img in form.sub_img4">{{img.split(":")[0]}}<a @click="removeImage(4,img)" style="color:red"> x</a> |
| 85 | 135 | </p> |
| 86 | 136 | </el-col> |
| ... | ... | @@ -88,6 +138,16 @@ |
| 88 | 138 | <el-col :span="12"> |
| 89 | 139 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(5)">ๆๅๅคด่ง้ขๆชๅพ1</a> |
| 90 | 140 | <el-input v-model="form.sub_img5" type="hidden"></el-input> |
| 141 | + <el-image v-for="item in slides[5]" | |
| 142 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 143 | + :src="item.url" | |
| 144 | + :preview-src-list="[item.url]" | |
| 145 | + :z-index="2000"> | |
| 146 | + </el-image> | |
| 147 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 148 | + v-for="item in videos[5]"> | |
| 149 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 150 | + </div> | |
| 91 | 151 | <p v-for="img in form.sub_img5">{{img.split(":")[0]}}<a @click="removeImage(5,img)" style="color:red"> x</a> |
| 92 | 152 | </p> |
| 93 | 153 | </el-col> |
| ... | ... | @@ -96,12 +156,32 @@ |
| 96 | 156 | <el-col :span="12"> |
| 97 | 157 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(6)">ๆๅๅคด่ง้ขๆชๅพ2</a> |
| 98 | 158 | <el-input v-model="form.sub_img6" type="hidden"></el-input> |
| 159 | + <el-image v-for="item in slides[6]" | |
| 160 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 161 | + :src="item.url" | |
| 162 | + :preview-src-list="[item.url]" | |
| 163 | + :z-index="2000"> | |
| 164 | + </el-image> | |
| 165 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 166 | + v-for="item in videos[6]"> | |
| 167 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 168 | + </div> | |
| 99 | 169 | <p v-for="img in form.sub_img6">{{img.split(":")[0]}}<a @click="removeImage(6,img)" style="color:red"> x</a> |
| 100 | 170 | </p> |
| 101 | 171 | </el-col> |
| 102 | 172 | <el-col :span="12"> |
| 103 | 173 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(7)">ๆๅๅคด่ง้ขๆชๅพ3</a> |
| 104 | 174 | <el-input v-model="form.sub_img7" type="hidden"></el-input> |
| 175 | + <el-image v-for="item in slides[7]" | |
| 176 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 177 | + :src="item.url" | |
| 178 | + :preview-src-list="[item.url]" | |
| 179 | + :z-index="2000"> | |
| 180 | + </el-image> | |
| 181 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 182 | + v-for="item in videos[7]"> | |
| 183 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 184 | + </div> | |
| 105 | 185 | <p v-for="img in form.sub_img7">{{img.split(":")[0]}}<a @click="removeImage(7,img)" style="color:red"> x</a> |
| 106 | 186 | </p> |
| 107 | 187 | </el-col> |
| ... | ... | @@ -110,6 +190,16 @@ |
| 110 | 190 | <el-col :span="12"> |
| 111 | 191 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(8)">ๅ ถไป1</a> |
| 112 | 192 | <el-input v-model="form.sub_img8" type="hidden"></el-input> |
| 193 | + <el-image v-for="item in slides[8]" | |
| 194 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 195 | + :src="item.url" | |
| 196 | + :preview-src-list="[item.url]" | |
| 197 | + :z-index="2000"> | |
| 198 | + </el-image> | |
| 199 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 200 | + v-for="item in videos[8]"> | |
| 201 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 202 | + </div> | |
| 113 | 203 | <p v-for="img in form.sub_img8">{{img.split(":")[0]}}<a @click="removeImage(8,img)" style="color:red"> x</a> |
| 114 | 204 | </p> |
| 115 | 205 | </el-col> |
| ... | ... | @@ -117,6 +207,16 @@ |
| 117 | 207 | <el-col :span="12"> |
| 118 | 208 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(9)">ๅ ถไป2</a> |
| 119 | 209 | <el-input v-model="form.sub_img9" type="hidden"></el-input> |
| 210 | + <el-image v-for="item in slides[9]" | |
| 211 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 212 | + :src="item.url" | |
| 213 | + :preview-src-list="[item.url]" | |
| 214 | + :z-index="2000"> | |
| 215 | + </el-image> | |
| 216 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 217 | + v-for="item in videos[9]"> | |
| 218 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 219 | + </div> | |
| 120 | 220 | <p v-for="img in form.sub_img9">{{img.split(":")[0]}}<a @click="removeImage(9,img)" style="color:red"> x</a> |
| 121 | 221 | </p> |
| 122 | 222 | </el-col> |
| ... | ... | @@ -125,6 +225,16 @@ |
| 125 | 225 | <el-col :span="12"> |
| 126 | 226 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(10)">ๅ ถไป3</a> |
| 127 | 227 | <el-input v-model="form.sub_img10" type="hidden"></el-input> |
| 228 | + <el-image v-for="item in slides[10]" | |
| 229 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 230 | + :src="item.url" | |
| 231 | + :preview-src-list="[item.url]" | |
| 232 | + :z-index="2000"> | |
| 233 | + </el-image> | |
| 234 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 235 | + v-for="item in videos[10]"> | |
| 236 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 237 | + </div> | |
| 128 | 238 | <p v-for="img in form.sub_img10">{{img.split(":")[0]}}<a @click="removeImage(10,img)" style="color:red"> |
| 129 | 239 | x</a> |
| 130 | 240 | </p> |
| ... | ... | @@ -132,6 +242,16 @@ |
| 132 | 242 | <el-col :span="12"> |
| 133 | 243 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(11)">ๅ ถไป4</a> |
| 134 | 244 | <el-input v-model="form.sub_img11" type="hidden"></el-input> |
| 245 | + <el-image v-for="item in slides[11]" | |
| 246 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 247 | + :src="item.url" | |
| 248 | + :preview-src-list="[item.url]" | |
| 249 | + :z-index="2000"> | |
| 250 | + </el-image> | |
| 251 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 252 | + v-for="item in videos[11]"> | |
| 253 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 254 | + </div> | |
| 135 | 255 | <p v-for="img in form.sub_img11">{{img.split(":")[0]}}<a @click="removeImage(11,img)" style="color:red"> |
| 136 | 256 | x</a> |
| 137 | 257 | </p> |
| ... | ... | @@ -140,6 +260,16 @@ |
| 140 | 260 | <el-col :span="12"> |
| 141 | 261 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(12)">ๅ ถไป5</a> |
| 142 | 262 | <el-input v-model="form.sub_img12" type="hidden"></el-input> |
| 263 | + <el-image v-for="item in slides[12]" | |
| 264 | + style="width: 100px; height: 100px; margin: 5px;" | |
| 265 | + :src="item.url" | |
| 266 | + :preview-src-list="[item.url]" | |
| 267 | + :z-index="2000"> | |
| 268 | + </el-image> | |
| 269 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 270 | + v-for="item in videos[12]"> | |
| 271 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 272 | + </div> | |
| 143 | 273 | <p v-for="img in form.sub_img12">{{img.split(":")[0]}}<a @click="removeImage(12,img)" style="color:red"> |
| 144 | 274 | x</a> |
| 145 | 275 | </p> |
| ... | ... | @@ -292,7 +422,27 @@ |
| 292 | 422 | <!-- ็บฟไธๆกๅทไบคๅ --> |
| 293 | 423 | <el-dialog :title="title" :visible.sync="caseOffline" width="300px" append-to-body :close-on-click-modal="false"> |
| 294 | 424 | <caseOfflineInfo :businessKey="businessKey" v-if="caseOffline"/> |
| 295 | - <el-input v-model="form.advice" placeholder="่ฏทๅกซๅๅฎกๆนๆ่ง" type="textarea" :rows="3"/> | |
| 425 | + <el-input v-model="form.reply" type="textarea" :rows="3" placeholder="ๅๅคๆ่ง"> | |
| 426 | + </el-input> | |
| 427 | + <el-upload multiple :headers="upload.headers" :action="upload.url" | |
| 428 | + accept=".docx,.doc,.pdf,.png,.jpeg,.png,.jpg,.mp4,.avi" | |
| 429 | + :show-file-list="false" | |
| 430 | + :on-success="uploadSuccess1" :before-upload="beforeUpload"> | |
| 431 | + <el-button size="small" type="primary">้ๆฉ้ไปถ</el-button> | |
| 432 | + <div slot="tip" class="el-upload__tip">ๅช่ฝไธไผ ไธ่ถ ่ฟ 100MB ็jpgใpngใpdfใwordใaviใmp4ๆไปถ</div> | |
| 433 | + </el-upload> | |
| 434 | + <el-image v-for="item in slides1" | |
| 435 | + style="width: 150px; height: 100px; margin: 5px;" | |
| 436 | + :src="item.url" | |
| 437 | + :preview-src-list="[item.url]" | |
| 438 | + :z-index="2000"> | |
| 439 | + </el-image> | |
| 440 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 441 | + v-for="item in videoSrc1"> | |
| 442 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 443 | + </div> | |
| 444 | + <div style="color: blue;" v-for="(img,index) in form.replyImg">{{ img.split("/")[img.split("/").length - 1] }}<a | |
| 445 | + @click="removeAttchItem(index,img)" style="color:red;"> X</a></div> | |
| 296 | 446 | <div slot="footer" class="dialog-footer"> |
| 297 | 447 | <el-button type="danger" @click="submitForm(form.formData[0].controlId,1)">้ฉณๅ</el-button> |
| 298 | 448 | <el-button type="primary" @click="submitForm(form.formData[0].controlId,0)">้่ฟ</el-button> |
| ... | ... | @@ -302,23 +452,28 @@ |
| 302 | 452 | <!-- ๅนณๅฐ่ฟ่งไฟกๆฏ --> |
| 303 | 453 | <el-dialog :title="title" :visible.sync="violationCaseFile" width="300px" append-to-body :close-on-click-modal="false"> |
| 304 | 454 | <violationCaseFileInfo :idInfo="businessKey" v-if="violationCaseFile"/> |
| 305 | - <el-form v-if="this.taskName != '่ฝฆ่พๆๅฑไผไธ' && this.taskName != 'ๆธฃๅๅ็งๅ' && violationCaseFile" :rules="rules" label-width="120px" > | |
| 306 | - <el-input v-model="form.reply" type="textarea" :rows="3" placeholder="ๅๅคๆ่ง"> | |
| 307 | - </el-input> | |
| 308 | - <el-upload | |
| 309 | - list-type="picture" | |
| 310 | - action='' | |
| 311 | - accept=".jpg, .png , .bmp" | |
| 312 | - :limit="1" | |
| 313 | - :auto-upload="false" | |
| 314 | - :file-list="form.replyImg" | |
| 315 | - :on-change="getFile" | |
| 316 | - :on-preview="handlePictureCardPreview" | |
| 317 | - :on-remove="handleUploadRemove" | |
| 318 | - > | |
| 319 | - <el-button size="small" type="primary" @click="uploadimg" v-if="form.replyImg == null">้ๆฉๅพ็ไธไผ </el-button> | |
| 320 | - <div slot="tip" class="el-upload__tip" v-if="form.replyImg== null">ๅช่ฝไธไผ ไธๅผ ๅพ็ๆไปถ</div> | |
| 321 | - </el-upload> | |
| 455 | + <el-form label-width="120px" > | |
| 456 | + <el-input v-model="form.reply" type="textarea" :rows="3" placeholder="ๅๅคๆ่ง"> | |
| 457 | + </el-input> | |
| 458 | + <el-upload multiple :headers="upload.headers" :action="upload.url" | |
| 459 | + accept=".docx,.doc,.pdf,.png,.jpeg,.png,.jpg,.mp4,.avi" | |
| 460 | + :show-file-list="false" | |
| 461 | + :on-success="uploadSuccess1" :before-upload="beforeUpload"> | |
| 462 | + <el-button size="small" type="primary">้ๆฉ้ไปถ</el-button> | |
| 463 | + <div slot="tip" class="el-upload__tip">ๅช่ฝไธไผ ไธ่ถ ่ฟ 100MB ็jpgใpngใpdfใwordใaviใmp4ๆไปถ</div> | |
| 464 | + </el-upload> | |
| 465 | + <el-image v-for="item in slides1" | |
| 466 | + style="width: 150px; height: 100px; margin: 5px;" | |
| 467 | + :src="item.url" | |
| 468 | + :preview-src-list="[item.url]" | |
| 469 | + :z-index="2000"> | |
| 470 | + </el-image> | |
| 471 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 472 | + v-for="item in videoSrc1"> | |
| 473 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 474 | + </div> | |
| 475 | + <div style="color: blue;" v-for="(img,index) in form.replyImg">{{ img.split("/")[img.split("/").length - 1] }}<a | |
| 476 | + @click="removeAttchItem(index,img)" style="color:red;"> X</a></div> | |
| 322 | 477 | |
| 323 | 478 | </el-form> |
| 324 | 479 | |
| ... | ... | @@ -332,23 +487,28 @@ |
| 332 | 487 | <!-- ่ฟ่ง้ข่ญฆไฟกๆฏ --> |
| 333 | 488 | <el-dialog :title="title" :visible.sync="violationCaseFile1" width="300px" append-to-body :close-on-click-modal="false"> |
| 334 | 489 | <violationWarningInformationInfo :idInfo="businessKey" v-if="violationCaseFile1"/> |
| 335 | - <el-form v-if="this.taskName != '่ฝฆ่พๆๅฑไผไธ' && this.taskName != 'ๆธฃๅๅ็งๅ' && violationCaseFile1" :rules="rules" label-width="120px" > | |
| 336 | - <el-input v-model="form.reply" type="textarea" :rows="3" placeholder="ๅๅคๆ่ง"> | |
| 337 | - </el-input> | |
| 338 | - <el-upload | |
| 339 | - list-type="picture" | |
| 340 | - action='' | |
| 341 | - accept=".jpg, .png , .bmp" | |
| 342 | - :limit="1" | |
| 343 | - :auto-upload="false" | |
| 344 | - :file-list="form.replyImg" | |
| 345 | - :on-change="getFile" | |
| 346 | - :on-preview="handlePictureCardPreview" | |
| 347 | - :on-remove="handleUploadRemove" | |
| 348 | - > | |
| 349 | - <el-button size="small" type="primary" @click="uploadimg" v-if="form.replyImg == null">้ๆฉๅพ็ไธไผ </el-button> | |
| 350 | - <div slot="tip" class="el-upload__tip" v-if="form.replyImg== null">ๅช่ฝไธไผ ไธๅผ ๅพ็ๆไปถ</div> | |
| 351 | - </el-upload> | |
| 490 | + <el-form label-width="120px" > | |
| 491 | + <el-input v-model="form.reply" type="textarea" :rows="3" placeholder="ๅๅคๆ่ง"> | |
| 492 | + </el-input> | |
| 493 | + <el-upload multiple :headers="upload.headers" :action="upload.url" | |
| 494 | + accept=".docx,.doc,.pdf,.png,.jpeg,.png,.jpg,.mp4,.avi" | |
| 495 | + :show-file-list="false" | |
| 496 | + :on-success="uploadSuccess1" :before-upload="beforeUpload"> | |
| 497 | + <el-button size="small" type="primary">้ๆฉ้ไปถ</el-button> | |
| 498 | + <div slot="tip" class="el-upload__tip">ๅช่ฝไธไผ ไธ่ถ ่ฟ 100MB ็jpgใpngใpdfใwordใaviใmp4ๆไปถ</div> | |
| 499 | + </el-upload> | |
| 500 | + <el-image v-for="item in slides1" | |
| 501 | + style="width: 150px; height: 100px; margin: 5px;" | |
| 502 | + :src="item.url" | |
| 503 | + :preview-src-list="[item.url]" | |
| 504 | + :z-index="2000"> | |
| 505 | + </el-image> | |
| 506 | + <div style="display: inline-block;margin: 5px;position: relative; width: 150px;height: 100px;overflow:hidden;" | |
| 507 | + v-for="item in videoSrc1"> | |
| 508 | + <video width="100%" controls="controls" height="100%" :src="item.url"></video> | |
| 509 | + </div> | |
| 510 | + <div style="color: blue;" v-for="(img,index) in form.replyImg">{{ img.split("/")[img.split("/").length - 1] }}<a | |
| 511 | + @click="removeAttchItem(index,img)" style="color:red;"> X</a></div> | |
| 352 | 512 | |
| 353 | 513 | </el-form> |
| 354 | 514 | |
| ... | ... | @@ -373,9 +533,9 @@ |
| 373 | 533 | <el-input v-if="item.controlType=='textarea'" :label="item.controlLable" v-model="item.controlValue" |
| 374 | 534 | placeholder="ๆนๆณจ" type="textarea" :rows="3" style="margin-top:20px;"/> |
| 375 | 535 | </div> |
| 376 | - | |
| 536 | + | |
| 377 | 537 | <el-table :data="hisfromData" v-if="hisfromData != null"> |
| 378 | - | |
| 538 | + | |
| 379 | 539 | <el-table-column label="ๅฎกๆนๆ่ง" align="center" prop="controlValue"/> |
| 380 | 540 | <el-table-column label="ๅฎกๆนไบบ" align="center" prop="createName"/> |
| 381 | 541 | <el-table-column label="ๅฎกๆนๆถ้ด" align="center" prop="createTime"/> |
| ... | ... | @@ -432,9 +592,11 @@ |
| 432 | 592 | import { |
| 433 | 593 | listTask, |
| 434 | 594 | formDataShow, |
| 435 | - formDataSave | |
| 595 | + formDataSave, | |
| 436 | 596 | } from "@/api/activiti/task"; |
| 437 | 597 | |
| 598 | +import {historyFromData} from '@/api/activiti/historyFormdata' | |
| 599 | + | |
| 438 | 600 | |
| 439 | 601 | import {getSignByObjId, addSign, updateSign} from "@/api/sign/sign"; |
| 440 | 602 | |
| ... | ... | @@ -461,7 +623,7 @@ import {updateHandleAffairs} from "@/api/office/handle"; |
| 461 | 623 | import Treeselect from "@riophae/vue-treeselect"; |
| 462 | 624 | import '@riophae/vue-treeselect/dist/vue-treeselect.css' |
| 463 | 625 | |
| 464 | -import pagination from '../Pagination'; | |
| 626 | +import h5Page from '@/views/h5/Pagination'; | |
| 465 | 627 | |
| 466 | 628 | import threestepInfo from "@/views/h5/task/threestepInfo"; |
| 467 | 629 | import taskCard from "@/views/h5/task/taskCard"; |
| ... | ... | @@ -476,7 +638,7 @@ import caseOfflineInfo from "@/views/h5/caseOffline/caseOfflineInfo"; |
| 476 | 638 | import violationCaseFileInfo from "@/views/h5/task/violationCaseFileInfo"; |
| 477 | 639 | import violationWarningInformationInfo from "@/views/h5/task/violationWarningInformationInfo"; |
| 478 | 640 | import supervisionInfo from "@/views/h5/task/SupervisionInfo"; |
| 479 | -import companyInfo from "@/views/activiti/task/companyInfo"; | |
| 641 | +import companyInfo from "@/views/h5/task/companyInfo"; | |
| 480 | 642 | import driverInfo from "@/views/activiti/task/driverInfo"; |
| 481 | 643 | import vehicleInfo from "@/views/activiti/task/vehicleInfo"; |
| 482 | 644 | |
| ... | ... | @@ -500,7 +662,7 @@ export default { |
| 500 | 662 | companyInfo, |
| 501 | 663 | driverInfo, |
| 502 | 664 | vehicleInfo, |
| 503 | - pagination, | |
| 665 | + h5Page | |
| 504 | 666 | }, |
| 505 | 667 | data() { |
| 506 | 668 | return { |
| ... | ... | @@ -588,9 +750,18 @@ export default { |
| 588 | 750 | usersName: [], |
| 589 | 751 | deptName:null, |
| 590 | 752 | |
| 753 | + slides: [], | |
| 754 | + slidesArys: [], | |
| 755 | + videos:[], | |
| 591 | 756 | company:false, |
| 592 | 757 | driver:false, |
| 593 | 758 | vehicle:false, |
| 759 | + hisfromData:[], | |
| 760 | + | |
| 761 | + slides: [], | |
| 762 | + slidesArys: [], | |
| 763 | + slides1: [], | |
| 764 | + videoSrc1: [], | |
| 594 | 765 | }; |
| 595 | 766 | }, |
| 596 | 767 | created() { |
| ... | ... | @@ -614,40 +785,114 @@ export default { |
| 614 | 785 | this.fileList = []; |
| 615 | 786 | }, |
| 616 | 787 | removeImage(index, img) { |
| 617 | - let target = "sub_img" + this.picIndex; | |
| 618 | - this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 788 | + if(this.slides[index]){ | |
| 789 | + for(let i=0;i<this.slides[index].length;i++){ | |
| 790 | + if(this.slides[index][i].alt == img){ | |
| 791 | + this.slides[index].splice(i,1); | |
| 792 | + } | |
| 793 | + } | |
| 794 | + } | |
| 795 | + if(this.videos[index]){ | |
| 796 | + for(let i=0;i<this.videos[index].length;i++){ | |
| 797 | + if(this.videos[index][i].alt == img){ | |
| 798 | + this.videos[index].splice(i,1); | |
| 799 | + } | |
| 800 | + } | |
| 801 | + } | |
| 802 | + | |
| 803 | + let target = "sub_img" + index; | |
| 804 | + this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 805 | + this.$forceUpdate(); | |
| 619 | 806 | }, |
| 620 | 807 | uploadSuccess(res, file, fileList) { |
| 621 | - if(res.code){ | |
| 622 | - this.$message(res.message); | |
| 623 | - return; | |
| 808 | + debugger; | |
| 809 | + if (res.code) { | |
| 810 | + this.$message(res.message); | |
| 811 | + return; | |
| 624 | 812 | } |
| 625 | - let target = "sub_img" + this.picIndex; | |
| 626 | - if (!this.form[target]) { | |
| 627 | - this.form[target] = []; | |
| 628 | - } | |
| 813 | + | |
| 814 | + let target = "sub_img" + this.picIndex; | |
| 815 | + | |
| 816 | + if (!this.form[target]) { | |
| 817 | + this.form[target] = []; | |
| 818 | + } | |
| 819 | + | |
| 629 | 820 | this.form[target].push(file.name + ':' + res); |
| 630 | 821 | |
| 822 | + if(file.name.indexOf('.jpg') > -1 ||file.name.indexOf('.png') > -1){ | |
| 823 | + let url = URL.createObjectURL(file.raw) | |
| 824 | + if(!this.slides[this.picIndex]){ | |
| 825 | + this.slides[this.picIndex] = []; | |
| 826 | + } | |
| 827 | + | |
| 828 | + this.slides[this.picIndex].push({ | |
| 829 | + url:url, | |
| 830 | + alt:res | |
| 831 | + }) | |
| 832 | + } | |
| 833 | + if(file.name.indexOf('.avi') > -1 ||file.name.indexOf('.mp4') > -1){ | |
| 834 | + | |
| 835 | + let url = URL.createObjectURL(file.raw) | |
| 836 | + if(!this.videos[this.picIndex]){ | |
| 837 | + this.videos[this.picIndex] = []; | |
| 838 | + } | |
| 839 | + this.videos[this.picIndex].push({ | |
| 840 | + url:url, | |
| 841 | + alt:res | |
| 842 | + }); | |
| 843 | + } | |
| 844 | + | |
| 845 | + this.$forceUpdate(); | |
| 631 | 846 | }, |
| 632 | 847 | showFileUpload(i) { |
| 633 | 848 | this.uploadImageDialog = true; |
| 634 | 849 | this.picIndex = i; |
| 635 | 850 | }, |
| 636 | - beforeUpload(file) { | |
| 637 | - let isRightSize = file.size / 1024 / 1024 < 20 | |
| 638 | - if (!isRightSize) { | |
| 639 | - this.$message.error('ๆไปถๅคงๅฐ่ถ ่ฟ 20MB') | |
| 640 | - return isRightSize; | |
| 851 | + uploadSuccess1(res, file, fileList) { | |
| 852 | + if (res.code) { | |
| 853 | + this.$message(res.message); | |
| 854 | + return; | |
| 641 | 855 | } |
| 642 | - let isAccept = false; | |
| 643 | - if (file.name.indexOf('.docx') > -1 || file.name.indexOf(".jpg") > -1 || file.name.indexOf('.doc') > -1 || file | |
| 644 | - .name.indexOf('.pdf') > -1) { | |
| 645 | - isAccept = true; | |
| 856 | + if (!this.form.replyImg) { | |
| 857 | + this.form.replyImg = []; | |
| 646 | 858 | } |
| 647 | - if (!isAccept) { | |
| 648 | - this.$message.error('ๅบ่ฏฅ้ๆฉPDFใJPGใWORD็ฑปๅ็ๆไปถ') | |
| 649 | - return isAccept; | |
| 859 | + this.form.replyImg.push(res); | |
| 860 | + if (file.name.indexOf('.jpg') > -1 || file.name.indexOf('.png') > -1 || file.name.indexOf('.gif') > -1 || file.name.indexOf('.jpeg') > -1) { | |
| 861 | + let url = URL.createObjectURL(file.raw) | |
| 862 | + this.slides1.push({ | |
| 863 | + url: url, | |
| 864 | + alt: res | |
| 865 | + }) | |
| 866 | + } | |
| 867 | + if (file.name.indexOf('.avi') > -1 || file.name.indexOf('.mp4') > -1) { | |
| 868 | + let url = URL.createObjectURL(file.raw) | |
| 869 | + this.videoSrc1.push({ | |
| 870 | + url: url, | |
| 871 | + alt: res | |
| 872 | + }); | |
| 650 | 873 | } |
| 874 | + this.$forceUpdate(); | |
| 875 | + }, | |
| 876 | + beforeUpload(file) { | |
| 877 | + let isRightSize = file.size / 1024 / 1024 < 20 | |
| 878 | + if (!isRightSize) { | |
| 879 | + this.$message.error('ๆไปถๅคงๅฐ่ถ ่ฟ 20MB') | |
| 880 | + return isRightSize; | |
| 881 | + } | |
| 882 | + | |
| 883 | + let isAccept = false; | |
| 884 | + let name = file.name + ""; | |
| 885 | + name = name.toLowerCase(); | |
| 886 | + | |
| 887 | + if (name.indexOf('.docx') > -1 || name.indexOf(".jpg") > -1 || name.indexOf('.doc') > -1 || file | |
| 888 | + .name.indexOf('.pdf') > -1||name.indexOf('.png') > -1 ||name.indexOf('.mp4') > -1 ||name.indexOf('.avi') > -1) { | |
| 889 | + isAccept = true; | |
| 890 | + } | |
| 891 | + if (!isAccept) { | |
| 892 | + this.$message.error('ๅบ่ฏฅ้ๆฉPDFใPNGใJPGใMP4,AVI,WORD็ฑปๅ็ๆไปถ') | |
| 893 | + return isAccept; | |
| 894 | + } | |
| 895 | + | |
| 651 | 896 | }, |
| 652 | 897 | getList() { |
| 653 | 898 | this.reset(); |
| ... | ... | @@ -677,6 +922,8 @@ export default { |
| 677 | 922 | this.company=false; |
| 678 | 923 | this.driver=false; |
| 679 | 924 | this.vehicle=false; |
| 925 | + | |
| 926 | + | |
| 680 | 927 | this.reset(); |
| 681 | 928 | }, |
| 682 | 929 | // ่กจๅ้็ฝฎ |
| ... | ... | @@ -686,6 +933,9 @@ export default { |
| 686 | 933 | this.form = { |
| 687 | 934 | formData: [], |
| 688 | 935 | }; |
| 936 | + this.videoSrc1 = []; | |
| 937 | + this.slides1 = []; | |
| 938 | + | |
| 689 | 939 | this.resetForm("form"); |
| 690 | 940 | }, |
| 691 | 941 | showTask(row, idx) { |
| ... | ... | @@ -694,6 +944,15 @@ export default { |
| 694 | 944 | this.businessKey = row.businessKey; |
| 695 | 945 | this.id = row.id; |
| 696 | 946 | this.taskName = row.name; |
| 947 | + historyFromData(this.businessKey).then(response => { | |
| 948 | + this.hisfromData = []; | |
| 949 | + this.hisfromData.push({createName:row.createBy,controlValue:row.reason,createTime:row.time}) | |
| 950 | + for(let i in response.data){ | |
| 951 | + | |
| 952 | + this.hisfromData.push(response.data[i]); | |
| 953 | + } | |
| 954 | + }) | |
| 955 | + | |
| 697 | 956 | formDataShow(row.id).then(response => { |
| 698 | 957 | let datas = response.data; |
| 699 | 958 | let formData = [] |
| ... | ... | @@ -806,7 +1065,7 @@ export default { |
| 806 | 1065 | |
| 807 | 1066 | /** ๆไบคๆ้ฎ */ |
| 808 | 1067 | submitForm(formid, value) { |
| 809 | - this.form.formData[0].controlValue = value; | |
| 1068 | +this.form.formData[0].controlValue = value; | |
| 810 | 1069 | this.form.formData[0].controlId = formid; |
| 811 | 1070 | this.form.id = this.businessKey.split(":")[1]; |
| 812 | 1071 | if (this.form.formData[0].controlValue == 0) { |
| ... | ... | @@ -828,7 +1087,7 @@ export default { |
| 828 | 1087 | } |
| 829 | 1088 | } |
| 830 | 1089 | |
| 831 | - if (this.form.status == 1 ) { | |
| 1090 | + if (this.form.status == 1) { | |
| 832 | 1091 | activeThreestep(this.form).then(res => { |
| 833 | 1092 | formDataSave(this.id, this.form.formData).then(response => { |
| 834 | 1093 | this.msgSuccess("ๅฎกๆนๆๅ"); |
| ... | ... | @@ -838,12 +1097,12 @@ export default { |
| 838 | 1097 | }); |
| 839 | 1098 | }); |
| 840 | 1099 | } else { |
| 841 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 842 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 843 | - this.open2 = false; | |
| 844 | - this.taskList = []; | |
| 845 | - this.getList(); | |
| 846 | - }); | |
| 1100 | + formDataSave(this.id, this.form.formData).then(response => { | |
| 1101 | + this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1102 | + this.open2 = false; | |
| 1103 | + this.taskList = []; | |
| 1104 | + this.getList(); | |
| 1105 | + }); | |
| 847 | 1106 | } |
| 848 | 1107 | return; |
| 849 | 1108 | } |
| ... | ... | @@ -854,18 +1113,28 @@ export default { |
| 854 | 1113 | let query = { |
| 855 | 1114 | objectId: objId, |
| 856 | 1115 | }; |
| 1116 | + let text = ""; | |
| 1117 | + for (let i = 0; i < this.form.formData.length; i++) { | |
| 1118 | + let strings = this.form.formData[i]; | |
| 1119 | + switch (strings.controlType) { | |
| 1120 | + case 'textarea': | |
| 1121 | + text = strings.controlValue; | |
| 1122 | + break; | |
| 1123 | + } | |
| 1124 | + } | |
| 1125 | + | |
| 857 | 1126 | if (this.taskName == "ๅๅฏ็งๅ") { |
| 858 | 1127 | query.idx = 0; |
| 859 | - query.sign1Text = this.signDataInfo; | |
| 1128 | + query.sign1Text = text; | |
| 860 | 1129 | } else if (this.taskName == "ๅ ชๅฏ้จ้ฟ") { |
| 861 | 1130 | query.idx = 1; |
| 862 | - query.sign2Text = this.signDataInfo; | |
| 1131 | + query.sign2Text = text; | |
| 863 | 1132 | } else if (this.taskName == "ๅ ชๅฏๅ็ฎก้ขๅฏผ") { |
| 864 | 1133 | query.idx = 2; |
| 865 | - query.sign3Text = this.signDataInfo; | |
| 1134 | + query.sign3Text = text | |
| 866 | 1135 | } else if (this.taskName == "ไธญๅฟ่ด่ดฃไบบ") { |
| 867 | 1136 | query.idx = 3; |
| 868 | - query.sign4Text = this.signDataInfo; | |
| 1137 | + query.sign4Text = text; | |
| 869 | 1138 | } |
| 870 | 1139 | |
| 871 | 1140 | addSign(query).then(res => { |
| ... | ... | @@ -903,6 +1172,24 @@ export default { |
| 903 | 1172 | }); |
| 904 | 1173 | } |
| 905 | 1174 | if (this.definitionKey == "workflow_caseoffline") { |
| 1175 | + | |
| 1176 | + let postData = {}; | |
| 1177 | + | |
| 1178 | + postData.tableName = this.businessKey; | |
| 1179 | + postData.replyImg = this.form.replyImg + ""; | |
| 1180 | + postData.reply = this.form.reply; | |
| 1181 | + if(postData.reply==null || postData.reply==""){ | |
| 1182 | + if(value==0){ | |
| 1183 | + postData.reply = "้่ฟ"; | |
| 1184 | + }else{ | |
| 1185 | + postData.reply = "้ฉณๅ"; | |
| 1186 | + } | |
| 1187 | + } | |
| 1188 | + | |
| 1189 | + addReplyApprovalProcess(postData).then(res => { | |
| 1190 | + this.videoSrc1 = []; | |
| 1191 | + this.slides1 = []; | |
| 1192 | + }); | |
| 906 | 1193 | let id = this.businessKey.split(":")[1]; |
| 907 | 1194 | let query = { |
| 908 | 1195 | id: id, |
| ... | ... | @@ -935,113 +1222,79 @@ export default { |
| 935 | 1222 | this.getList(); |
| 936 | 1223 | }); |
| 937 | 1224 | }) |
| 938 | - | |
| 939 | - | |
| 940 | 1225 | return; |
| 941 | 1226 | } |
| 942 | 1227 | |
| 943 | - | |
| 944 | - if (this.definitionKey == "workflow_caseoffline") { | |
| 945 | - let id = this.businessKey.split(":")[1]; | |
| 946 | - let query = { | |
| 947 | - id: id, | |
| 948 | - }; | |
| 949 | - let adv = this.form.advice; | |
| 950 | - if (!adv) { | |
| 951 | - if (value == 0) { | |
| 952 | - adv = "ๅฎกๆน้่ฟ"; | |
| 953 | - } else { | |
| 954 | - adv = "ๅฎกๆน้ฉณๅ"; | |
| 1228 | + if (this.definitionKey == "workflow_casefile") { | |
| 1229 | + let postData = {}; | |
| 1230 | + | |
| 1231 | + postData.tableName = this.businessKey; | |
| 1232 | + postData.replyImg = this.form.replyImg + ""; | |
| 1233 | + postData.reply = this.form.reply; | |
| 1234 | + if(postData.reply==null || postData.reply==""){ | |
| 1235 | + if(value==0){ | |
| 1236 | + postData.reply = "้่ฟ"; | |
| 1237 | + }else{ | |
| 1238 | + postData.reply = "้ฉณๅ"; | |
| 955 | 1239 | } |
| 956 | 1240 | } |
| 957 | - if (this.taskName == "ๆธฃๅๅ็งๅ") { | |
| 958 | - query.advice1 = adv; | |
| 959 | - } else if (this.taskName == "ๆธฃๅๅๅ็ฎก้ขๅฏผ") { | |
| 960 | - query.advice2 = adv; | |
| 961 | - } else if (this.taskName == "ๆฒป็้จ้จ้ฟ") { | |
| 962 | - query.advice3 = adv; | |
| 963 | - } else if (this.taskName == "ๆฒป็้จๅ็ฎก้ขๅฏผ") { | |
| 964 | - query.advice4 = adv; | |
| 965 | - } | |
| 966 | - updateCaseOffline(query).then(res => { | |
| 967 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 968 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 969 | - this.caseOffline = false; | |
| 970 | - this.getList(); | |
| 971 | - }); | |
| 972 | - }) | |
| 973 | - return; | |
| 974 | - } | |
| 975 | - if (this.definitionKey == "workflow_casefile") { | |
| 976 | - | |
| 977 | 1241 | if (this.taskName == "่ฝฆ่พๆๅฑไผไธ" || this.taskName == "ๆธฃๅๅ็งๅ") { |
| 978 | 1242 | console.log(this.businessKey); |
| 979 | 1243 | let objId = this.businessKey.split(":")[1]; |
| 980 | 1244 | updateViolationCaseFileReader({id: objId}).then(res => { |
| 981 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 982 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 983 | - this.violationCaseFile = false; | |
| 984 | - this.getList(); | |
| 985 | - }); | |
| 986 | 1245 | }) |
| 987 | - return; | |
| 988 | - } else { | |
| 989 | - let postData = {}; | |
| 990 | - | |
| 991 | - postData.tableName = this.businessKey; | |
| 992 | - postData.replyImg = this.form.replyImg; | |
| 993 | - postData.reply = this.form.reply; | |
| 994 | - addReplyApprovalProcess(postData).then(res => { | |
| 995 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 996 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 997 | - this.violationCaseFile = false; | |
| 998 | - this.getList(); | |
| 999 | - }); | |
| 1000 | - }); | |
| 1001 | - | |
| 1002 | 1246 | } |
| 1247 | + addReplyApprovalProcess(postData).then(res => { | |
| 1248 | + this.videoSrc1 = []; | |
| 1249 | + this.slides1 = []; | |
| 1250 | + formDataSave(this.id, this.form.formData).then(response => { | |
| 1251 | + this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1252 | + this.violationCaseFile = false; | |
| 1253 | + this.getList(); | |
| 1254 | + }); | |
| 1255 | + }); | |
| 1003 | 1256 | } |
| 1004 | 1257 | if (this.definitionKey == "violation_warning") { |
| 1258 | + let postData = {}; | |
| 1259 | + postData.tableName = this.businessKey; | |
| 1260 | + postData.replyImg = this.form.replyImg + ""; | |
| 1261 | + postData.reply = this.form.reply; | |
| 1262 | + if(postData.reply==null || postData.reply==""){ | |
| 1263 | + if(value==0){ | |
| 1264 | + postData.reply = "้่ฟ"; | |
| 1265 | + }else{ | |
| 1266 | + postData.reply = "้ฉณๅ"; | |
| 1267 | + } | |
| 1268 | + } | |
| 1269 | + | |
| 1270 | + | |
| 1005 | 1271 | if (this.taskName == "่ฝฆ่พๆๅฑไผไธ" || this.taskName == "ๆธฃๅๅ็งๅ") { |
| 1006 | - console.log(this.businessKey); | |
| 1007 | 1272 | let objId = this.businessKey.split(":")[1]; |
| 1008 | 1273 | updateViolationCaseFileReader1({id: objId}).then(res => { |
| 1009 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 1010 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1011 | - this.violationCaseFile1 = false; | |
| 1012 | - this.getList(); | |
| 1013 | - }); | |
| 1014 | 1274 | }) |
| 1015 | - return; | |
| 1016 | - } else { | |
| 1017 | - | |
| 1018 | - let postData = {}; | |
| 1019 | - postData.tableName = this.businessKey; | |
| 1020 | - postData.replyImg = this.form.replyImg; | |
| 1021 | - postData.reply = this.form.reply; | |
| 1022 | - addReplyApprovalProcess(postData).then(res => { | |
| 1023 | - formDataSave(this.id, this.form.formData).then(response => { | |
| 1024 | - this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1025 | - this.violationCaseFile1 = false; | |
| 1026 | - this.getList(); | |
| 1027 | - }); | |
| 1028 | - }); | |
| 1029 | - | |
| 1030 | - | |
| 1031 | 1275 | } |
| 1276 | + addReplyApprovalProcess(postData).then(res => { | |
| 1277 | + this.videoSrc1 = []; | |
| 1278 | + this.slides1 = []; | |
| 1279 | + formDataSave(this.id, this.form.formData).then(response => { | |
| 1280 | + this.msgSuccess("ๅฎกๆนๆๅ"); | |
| 1281 | + this.violationCaseFile1 = false; | |
| 1282 | + this.getList(); | |
| 1283 | + }); | |
| 1284 | + }); | |
| 1032 | 1285 | } |
| 1033 | 1286 | |
| 1034 | - if(this.definitionKey.indexOf("supervision")>-1){ | |
| 1287 | + if (this.definitionKey.indexOf("supervision") > -1) { | |
| 1035 | 1288 | formDataSave(this.id, this.form.formData).then(response => { |
| 1036 | 1289 | this.msgSuccess("ๅฎกๆนๆๅ"); |
| 1037 | 1290 | this.supervisionOpen = false; |
| 1038 | 1291 | this.getList(); |
| 1039 | 1292 | }); |
| 1040 | 1293 | } |
| 1041 | - if(this.definitionKey == "workflow_company" || | |
| 1042 | - this.definitionKey == "workflow_driver" || | |
| 1043 | - this.definitionKey == "workflow_vehicle" || | |
| 1044 | - this.definitionKey == "workflow_constructsite_edit"){ | |
| 1294 | + if (this.definitionKey == "workflow_company" || | |
| 1295 | + this.definitionKey == "workflow_driver" || | |
| 1296 | + this.definitionKey == "workflow_vehicle" || | |
| 1297 | + this.definitionKey == "workflow_constructsite_edit") { | |
| 1045 | 1298 | formDataSave(this.id, this.form.formData).then(response => { |
| 1046 | 1299 | this.msgSuccess("ๅฎกๆนๆๅ"); |
| 1047 | 1300 | this.cancel(); |
| ... | ... | @@ -1064,6 +1317,9 @@ export default { |
| 1064 | 1317 | this.getList(); |
| 1065 | 1318 | }); |
| 1066 | 1319 | }, |
| 1320 | + downloadFile(path) { | |
| 1321 | + window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 1322 | + }, | |
| 1067 | 1323 | leaveApplicationSubmitForm(value) { |
| 1068 | 1324 | if (value == 0) { |
| 1069 | 1325 | this.form.status = 1; | ... | ... |
trash-ui/src/views/h5/task/taskCard.vue
| 1 | 1 | <template> |
| 2 | 2 | <a @click="sendToParent(task)"><el-card class="box-card"> |
| 3 | - <div :class="{card_status:true,notcheck:!task.checkStatus,dismiss:task.checkStatus=='1',agree:task.checkStatus=='0'}"> | |
| 4 | - {{task.checkStatus? task.checkStatus=="0"?"ๅทฒๅๆ":"ๅทฒๆ็ป" : "ๅพ ๅฎกๆน"}}</div> | |
| 3 | + <div :class="{card_status:true,notcheck:!task.checkStatus,dismiss:task.checkStatus=='2',agree:task.checkStatus=='1'}"> | |
| 4 | + {{task.checkStatus? task.checkStatus=="1"?"ๅทฒๅๆ":"ๅทฒๆ็ป" : "ๅพ ๅฎกๆน"}}</div> | |
| 5 | 5 | |
| 6 | 6 | <el-row class="card_row"> |
| 7 | 7 | <div class="card_title">{{task.instanceName}}</div> | ... | ... |
trash-ui/src/views/h5/task/violationCaseFileInfo.vue
| ... | ... | @@ -79,7 +79,7 @@ |
| 79 | 79 | <el-row> |
| 80 | 80 | <el-col :offset="3"><el-button type="primary" @click="open = true">ๆฅ็้ไปถ({{fileEntityList.length}})</el-button></el-col> |
| 81 | 81 | </el-row> |
| 82 | - <el-table :data="replyApprovalProcessList" v-if="entryType==0"> | |
| 82 | + <el-table :data="replyApprovalProcessList" > | |
| 83 | 83 | <el-table-column property="replyPeople" label="ๆไฝไบบ" header-align="center" align="center"></el-table-column> |
| 84 | 84 | <el-table-column property="reply" label="ๆ่ง" header-align="center" align="center"></el-table-column> |
| 85 | 85 | <el-table-column property="replyTime" label="ๆไฝๆถ้ด" header-align="center" align="center"></el-table-column> |
| ... | ... | @@ -90,6 +90,7 @@ |
| 90 | 90 | type="text" |
| 91 | 91 | icon="el-icon-view" |
| 92 | 92 | @click="openImage(scope.row.replyImg)" |
| 93 | + v-if="scope.row.replyImg!=null && scope.row.replyImg!='undefined'" | |
| 93 | 94 | v-hasPermi="['casefile:violationWarningInformation:view']" |
| 94 | 95 | >ๆฅ็</el-button> |
| 95 | 96 | </template> |
| ... | ... | @@ -124,12 +125,20 @@ |
| 124 | 125 | <el-button @click="open = false">ๅ ๆถ</el-button> |
| 125 | 126 | </div> |
| 126 | 127 | </el-dialog> |
| 127 | - <el-dialog title="้ข่ง" :visible.sync="openImg" append-to-body v-if="entryType==0" width="300px"> | |
| 128 | - <el-image style="width: 250px; height: 250px; margin: 5px;" | |
| 129 | - :src="img[0]" | |
| 130 | - :preview-src-list="img" | |
| 131 | - :z-index="2000"> | |
| 132 | - </el-image> | |
| 128 | + <el-dialog title="้ข่ง" :visible.sync="openImg" append-to-body width="300px"> | |
| 129 | + <div v-for="item in img" style="border: 1px black solid;text-align: center;"> | |
| 130 | + | |
| 131 | + <el-image style="width: 250px; height: 250px; margin: 5px;" | |
| 132 | + v-if="item.indexOf('.jpg')>-1||item.indexOf('.png')>-1||item.indexOf('.jpeg')>-1||item.indexOf('.gif')>-1" | |
| 133 | + :src="showFile(item)" | |
| 134 | + :preview-src-list="[showFile(item)]" | |
| 135 | + :z-index="2000"> | |
| 136 | + </el-image> | |
| 137 | + <div style="display: inline-block;margin: 5px;position: relative; width: 250px;height: 250px;overflow:hidden;" v-if="item.indexOf('.mp4')>-1||item.indexOf('.avi')>-1"> | |
| 138 | + <video width="100%" controls="controls" height="100%" :src="showFile(item)"></video> | |
| 139 | + </div> | |
| 140 | + <a @click="downloadFile(item);" style="color: blue;"> ไธ่ฝฝ: {{ item.split("/")[item.split("/").length - 1] }} </a> | |
| 141 | + </div> | |
| 133 | 142 | </el-dialog> |
| 134 | 143 | |
| 135 | 144 | </el-form> |
| ... | ... | @@ -138,6 +147,7 @@ |
| 138 | 147 | <script> |
| 139 | 148 | import {getViolationCaseFile} from "@/api/casefile/violationCaseFile"; |
| 140 | 149 | import {listReplyApprovalProcess} from "@/api/casefile/replyApprovalProcess"; |
| 150 | + | |
| 141 | 151 | export default { |
| 142 | 152 | name: "violationWarningInformationInfo", |
| 143 | 153 | props: { |
| ... | ... | @@ -156,9 +166,9 @@ export default { |
| 156 | 166 | form: {}, |
| 157 | 167 | fileEntityList: [], |
| 158 | 168 | open: false, |
| 159 | - replyApprovalProcessList:[], | |
| 160 | - openImg:false, | |
| 161 | - img:null, | |
| 169 | + replyApprovalProcessList: [], | |
| 170 | + openImg: false, | |
| 171 | + img: [], | |
| 162 | 172 | showPic: null, |
| 163 | 173 | picImage: null, |
| 164 | 174 | slide1: [], |
| ... | ... | @@ -168,19 +178,17 @@ export default { |
| 168 | 178 | created() { |
| 169 | 179 | let id = this.idInfo.split(":"); |
| 170 | 180 | |
| 171 | - if(id.length == 2){ | |
| 181 | + if (id.length == 2) { | |
| 172 | 182 | this.idInfo = id[1]; |
| 173 | - }else{ | |
| 183 | + } else { | |
| 174 | 184 | this.idInfo = id; |
| 175 | 185 | } |
| 176 | 186 | |
| 177 | 187 | |
| 178 | - | |
| 179 | - | |
| 180 | 188 | this.init(); |
| 181 | 189 | }, |
| 182 | - methods:{ | |
| 183 | - init(){ | |
| 190 | + methods: { | |
| 191 | + init() { | |
| 184 | 192 | getViolationCaseFile(this.idInfo).then(response => { |
| 185 | 193 | this.form = response.data.violationCaseFile; |
| 186 | 194 | let files = JSON.stringify(response.data.uploadFiles); |
| ... | ... | @@ -196,7 +204,7 @@ export default { |
| 196 | 204 | }); |
| 197 | 205 | |
| 198 | 206 | |
| 199 | - listReplyApprovalProcess({tableName:"workflow_casefile" + ":" + this.idInfo}).then(response => { | |
| 207 | + listReplyApprovalProcess({tableName: "workflow_casefile" + ":" + this.idInfo}).then(response => { | |
| 200 | 208 | this.replyApprovalProcessList = response.rows; |
| 201 | 209 | }); |
| 202 | 210 | }, |
| ... | ... | @@ -210,10 +218,20 @@ export default { |
| 210 | 218 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); |
| 211 | 219 | a.click() |
| 212 | 220 | }, |
| 213 | - openImage(img) { | |
| 221 | + openImage(path) { | |
| 222 | + debugger; | |
| 214 | 223 | this.img = []; |
| 215 | 224 | this.openImg = true; |
| 216 | - this.img.push(img); | |
| 225 | + let files = path.split(","); | |
| 226 | + for(let i=0;i<files.length;i++){ | |
| 227 | + this.img.push(files[i]); | |
| 228 | + } | |
| 229 | + }, | |
| 230 | + downloadFile(path) { | |
| 231 | + window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 232 | + }, | |
| 233 | + showFile(path) { | |
| 234 | + return process.env.VUE_APP_BASE_API + path; | |
| 217 | 235 | }, |
| 218 | 236 | } |
| 219 | 237 | } | ... | ... |
trash-ui/src/views/h5/task/violationWarningInformationInfo.vue
| ... | ... | @@ -75,7 +75,7 @@ |
| 75 | 75 | </el-form-item> |
| 76 | 76 | <el-button type="primary" @click="open = true">ๆฅ็้ไปถ({{ fileEntityList.length }})</el-button> |
| 77 | 77 | |
| 78 | - <el-table :data="replyApprovalProcessList" v-if="entryType==0"> | |
| 78 | + <el-table :data="replyApprovalProcessList" > | |
| 79 | 79 | <el-table-column property="replyPeople" label="ๆไฝไบบ" header-align="center" align="center"></el-table-column> |
| 80 | 80 | <el-table-column property="reply" label="ๆ่ง" header-align="center" align="center"></el-table-column> |
| 81 | 81 | <el-table-column property="replyTime" label="ๆไฝๆถ้ด" header-align="center" align="center"></el-table-column> |
| ... | ... | @@ -120,12 +120,20 @@ |
| 120 | 120 | <el-button @click="open = false">ๅ ๆถ</el-button> |
| 121 | 121 | </div> |
| 122 | 122 | </el-dialog> |
| 123 | - <el-dialog title="้ข่ง" :visible.sync="openImg" append-to-body v-if="entryType==0" width="300px"> | |
| 124 | - <el-image style="width: 250px; height: 250px; margin: 5px;" | |
| 125 | - :src="img[0]" | |
| 126 | - :preview-src-list="img" | |
| 127 | - :z-index="2000"> | |
| 128 | - </el-image> | |
| 123 | + <el-dialog title="้ข่ง" :visible.sync="openImg" append-to-body width="300px"> | |
| 124 | + <div v-for="item in img" style="border: 1px black solid;text-align: center;"> | |
| 125 | + | |
| 126 | + <el-image style="width: 250px; height: 250px; margin: 5px;" | |
| 127 | + v-if="item.indexOf('.jpg')>-1||item.indexOf('.png')>-1||item.indexOf('.jpeg')>-1||item.indexOf('.gif')>-1" | |
| 128 | + :src="showFile(item)" | |
| 129 | + :preview-src-list="[showFile(item)]" | |
| 130 | + :z-index="2000"> | |
| 131 | + </el-image> | |
| 132 | + <div style="display: inline-block;margin: 5px;position: relative; width: 250px;height: 250px;overflow:hidden;" v-if="item.indexOf('.mp4')>-1||item.indexOf('.avi')>-1"> | |
| 133 | + <video width="100%" controls="controls" height="100%" :src="showFile(item)"></video> | |
| 134 | + </div> | |
| 135 | + <a @click="downloadFile(item);" style="color: blue;"> ไธ่ฝฝ: {{ item.split("/")[item.split("/").length - 1] }} </a> | |
| 136 | + </div> | |
| 129 | 137 | </el-dialog> |
| 130 | 138 | </el-form> |
| 131 | 139 | </template> |
| ... | ... | @@ -133,6 +141,7 @@ |
| 133 | 141 | <script> |
| 134 | 142 | import {getViolationWarningInformation} from "@/api/casefile/violationWarningInformation"; |
| 135 | 143 | import {listReplyApprovalProcess} from "@/api/casefile/replyApprovalProcess"; |
| 144 | + | |
| 136 | 145 | export default { |
| 137 | 146 | name: "violationWarningInformationInfo", |
| 138 | 147 | props: { |
| ... | ... | @@ -150,10 +159,10 @@ export default { |
| 150 | 159 | return { |
| 151 | 160 | form: {}, |
| 152 | 161 | fileEntityList: [], |
| 153 | - open:false, | |
| 154 | - replyApprovalProcessList:[], | |
| 155 | - openImg:false, | |
| 156 | - img:null, | |
| 162 | + open: false, | |
| 163 | + replyApprovalProcessList: [], | |
| 164 | + openImg: false, | |
| 165 | + img: [], | |
| 157 | 166 | showPic: null, |
| 158 | 167 | picImage: null, |
| 159 | 168 | slide1: [], |
| ... | ... | @@ -163,9 +172,9 @@ export default { |
| 163 | 172 | created() { |
| 164 | 173 | let id = this.idInfo.split(":"); |
| 165 | 174 | |
| 166 | - if(id.length == 2){ | |
| 175 | + if (id.length == 2) { | |
| 167 | 176 | this.idInfo = id[1]; |
| 168 | - }else{ | |
| 177 | + } else { | |
| 169 | 178 | this.idInfo = id; |
| 170 | 179 | } |
| 171 | 180 | this.init(); |
| ... | ... | @@ -185,7 +194,7 @@ export default { |
| 185 | 194 | } |
| 186 | 195 | }) |
| 187 | 196 | }); |
| 188 | - listReplyApprovalProcess({tableName:"violation_warning" + ":" + this.idInfo}).then(response => { | |
| 197 | + listReplyApprovalProcess({tableName: "violation_warning" + ":" + this.idInfo}).then(response => { | |
| 189 | 198 | this.replyApprovalProcessList = response.rows; |
| 190 | 199 | }); |
| 191 | 200 | }, |
| ... | ... | @@ -199,15 +208,23 @@ export default { |
| 199 | 208 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); |
| 200 | 209 | a.click() |
| 201 | 210 | }, |
| 202 | - openImage(base64){ | |
| 211 | + openImage(path) { | |
| 203 | 212 | this.img = []; |
| 204 | 213 | this.openImg = true; |
| 205 | - this.img.push(img); | |
| 206 | - } | |
| 214 | + let files = path.split(","); | |
| 215 | + for(let i=0;i<files.length;i++){ | |
| 216 | + this.img.push(files[i]); | |
| 217 | + } | |
| 218 | + }, | |
| 219 | + downloadFile(path) { | |
| 220 | + window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 221 | + }, | |
| 222 | + showFile(path) { | |
| 223 | + return process.env.VUE_APP_BASE_API + path; | |
| 224 | + }, | |
| 207 | 225 | } |
| 208 | 226 | } |
| 209 | 227 | </script> |
| 210 | - | |
| 211 | 228 | <style scoped> |
| 212 | 229 | |
| 213 | 230 | </style> | ... | ... |
trash-ui/src/views/h5/taskhistory/index.vue
| ... | ... | @@ -77,12 +77,12 @@ |
| 77 | 77 | |
| 78 | 78 | <!-- ๅนณๅฐ่ฟ่งไฟกๆฏ --> |
| 79 | 79 | <el-dialog :title="title" :visible.sync="violationCaseFile" width="300px" append-to-body :close-on-click-modal="false"> |
| 80 | - <violationCaseFileInfo :idInfo="businessKey" v-if="violationCaseFile"/> | |
| 80 | + <violationCaseFileInfo :idInfo="businessKey" v-if="violationCaseFile" :entryType="0"/> | |
| 81 | 81 | </el-dialog> |
| 82 | 82 | |
| 83 | 83 | <!-- ่ฟ่ง้ข่ญฆไฟกๆฏ --> |
| 84 | 84 | <el-dialog :title="title" :visible.sync="violationCaseFile1" width="300px" append-to-body :close-on-click-modal="false"> |
| 85 | - <violationWarningInformationInfo :idInfo="businessKey" v-if="violationCaseFile1"/> | |
| 85 | + <violationWarningInformationInfo :idInfo="businessKey" v-if="violationCaseFile1" :entryType="0"/> | |
| 86 | 86 | </el-dialog> |
| 87 | 87 | |
| 88 | 88 | <el-dialog :title="title" :visible.sync="supervisionOpen" width="300px" append-to-body :close-on-click-modal="false"> |
| ... | ... | @@ -90,9 +90,9 @@ |
| 90 | 90 | </el-dialog> |
| 91 | 91 | <el-dialog :title="title" :visible.sync="company" width="300px" append-to-body :close-on-click-modal="false"> |
| 92 | 92 | <companyInfo :businessKey="businessKey" :businessType="0" v-if="company"/> |
| 93 | - | |
| 93 | + | |
| 94 | 94 | <el-table :data="hisfromData" v-if="hisfromData != null"> |
| 95 | - | |
| 95 | + | |
| 96 | 96 | <el-table-column label="ๅฎกๆนๆ่ง" align="center" prop="controlValue"/> |
| 97 | 97 | <el-table-column label="ๅฎกๆนไบบ" align="center" prop="createName"/> |
| 98 | 98 | <el-table-column label="ๅฎกๆนๆถ้ด" align="center" prop="createTime"/> |
| ... | ... | @@ -136,7 +136,9 @@ |
| 136 | 136 | import '@riophae/vue-treeselect/dist/vue-treeselect.css' |
| 137 | 137 | |
| 138 | 138 | import { getSignByObjId, addSign, updateSign } from "@/api/sign/sign"; |
| 139 | - import pagination from '../Pagination'; | |
| 139 | + | |
| 140 | + | |
| 141 | + import h5Page from '@/views/h5/Pagination'; | |
| 140 | 142 | |
| 141 | 143 | import threestepInfo from "@/views/h5/task/threestepInfo"; |
| 142 | 144 | import taskCard from "@/views/h5/task/taskCard"; |
| ... | ... | @@ -182,7 +184,7 @@ |
| 182 | 184 | contractInfo, |
| 183 | 185 | caseOfflineInfo, |
| 184 | 186 | violationCaseFileInfo, |
| 185 | - pagination, | |
| 187 | + h5Page, | |
| 186 | 188 | violationWarningInformationInfo, |
| 187 | 189 | supervisionInfo, |
| 188 | 190 | companyInfo, | ... | ... |
trash-ui/src/views/h5/threestep/index.vue
| ... | ... | @@ -91,15 +91,15 @@ |
| 91 | 91 | </el-select> |
| 92 | 92 | </el-form-item> |
| 93 | 93 | <el-form-item :label="labelName" prop="name" v-if="form.type!=null"> |
| 94 | - <el-select v-model="form.name" filterable reserve-keyword @change="getObjId" v-el-select-loadmore="loadMore(rangeNumber)"> | |
| 95 | - <el-option v-for="item in remoteData.slice(0, rangeNumber)" :label="item.name" | |
| 94 | + <el-select v-model="form.name" filterable reserve-keyword @change="getObjId" :filter-method="getObjId"> | |
| 95 | + <el-option v-for="item in remoteData" :label="item.name" | |
| 96 | 96 | :value="item.name" :key="item.id" v-if="!form.place || item.areaCode == form.place"> |
| 97 | 97 | </el-option> |
| 98 | 98 | </el-select> |
| 99 | 99 | </el-form-item> |
| 100 | 100 | |
| 101 | 101 | |
| 102 | - <el-form-item label="่ฟ่พไผไธ" prop="companys" v-if="form.type==0"> | |
| 102 | + <!-- <el-form-item label="่ฟ่พไผไธ" prop="companys" v-if="form.type==0"> | |
| 103 | 103 | <el-select v-model="form.companys" filterable multiple @change="checkCompany" > |
| 104 | 104 | <el-option v-for="item in companyList" :label="item.name" :value="item.name" :key="item.id" |
| 105 | 105 | /> |
| ... | ... | @@ -107,10 +107,11 @@ |
| 107 | 107 | </el-form-item> |
| 108 | 108 | |
| 109 | 109 | <el-form-item label="่ฟ่พ่ฝฆ่พ" prop="trucks" > |
| 110 | - <el-checkbox-group v-model="form.trucks" style="max-height: 200px;overflow: auto;"> | |
| 111 | - <el-checkbox :label="item.licenseplateNo" v-for="item in truckList" v-if="form.companys && (form.companys.indexOf(item.companyName) > -1)"/> | |
| 110 | + <el-input v-model="truckName" /> | |
| 111 | + <el-checkbox-group v-model="form.trucks" style="max-height: 200px;overflow: auto;" @change="checkUpdate"> | |
| 112 | + <el-checkbox :label="item.licenseplateNo" v-for="item in truckList" v-if="(!truckName || item.licenseplateNo.indexOf(truckName) > -1) && form.companys && (form.companys.indexOf(item.companyName) > -1)"/> | |
| 112 | 113 | </el-checkbox-group> |
| 113 | - </el-form-item> | |
| 114 | + </el-form-item> --> | |
| 114 | 115 | |
| 115 | 116 | <el-form-item label="็ฐๅบ่ด่ดฃไบบ" prop="person" v-if="form.type!=null"> |
| 116 | 117 | <el-input v-model="form.person" :maxlength="20" show-word-limit /> | ... | ... |
trash-ui/src/views/h5/truckActivate/index.vue
| ... | ... | @@ -95,18 +95,20 @@ |
| 95 | 95 | <el-dialog :title="title" :visible.sync="open" width="400px" append-to-body> |
| 96 | 96 | <el-form ref="form" :model="form" :rules="rules" label-width="80px"> |
| 97 | 97 | <el-form-item label="ๆๅฑๅทฅๅฐ" prop="construction"> |
| 98 | - <el-select v-model="form.construction" placeholder="่ฏท้ๆฉๆๅฑๅทฅๅฐ" @change="getCompany"> | |
| 98 | + <el-select v-model="form.construction" placeholder="่ฏท้ๆฉๆๅฑๅทฅๅฐ" filterable reserve-keyword @change="getCompany"> | |
| 99 | 99 | <el-option v-for="item in constList" :label="item.name" :value="item.name" ></el-option> |
| 100 | 100 | </el-select> |
| 101 | 101 | </el-form-item> |
| 102 | 102 | <el-form-item label="ๆๅฑไผไธ" prop="company"> |
| 103 | - <el-select v-model="form.company" filterable reserve-keyword @change="clearTruck"> | |
| 104 | - <el-option v-for="item in companyList" :label="item.name" :value="item.name" /> | |
| 105 | - </el-select> | |
| 103 | + <el-select v-model="form.company" filterable reserve-keyword @change="clearTruck"> | |
| 104 | + <el-option v-for="item in companyList" :label="item.name" :value="item.name" | |
| 105 | + v-if="!simpleName || item.name.indexOf(simpleName) > -1" | |
| 106 | + /> | |
| 107 | + </el-select> | |
| 106 | 108 | </el-form-item> |
| 107 | 109 | <el-form-item label="่ฝฆ็ๅท" prop="licensePlate"> |
| 108 | 110 | <el-select v-model="form.licensePlate" placeholder="่ฏท้ๆฉ่ฝฆ่พ" multiple filterable> |
| 109 | - <el-option v-if="!form.company || form.company == item.companyName" | |
| 111 | + <el-option v-if="(form.company && form.company == item.companyName)" | |
| 110 | 112 | v-for="item in truckList" |
| 111 | 113 | :label="item.licenseplateNo" |
| 112 | 114 | :value="item.id"/> | ... | ... |
trash-ui/src/views/h5/violationCaseFile/index.vue
| ... | ... | @@ -139,8 +139,9 @@ |
| 139 | 139 | </el-col> |
| 140 | 140 | <el-col :span="11"> |
| 141 | 141 | <el-form-item label="่ฟ่งๅฏน่ฑก" prop="projectName"> |
| 142 | - <el-select v-model="form.projectName" :filterable="true" placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;"> | |
| 143 | - <el-option v-for="item in data" :key="item.name" :label="item.name" :value="item.name" @click.native="getObjId(item)" | |
| 142 | + <el-select v-model="form.projectName" :filterable="true" | |
| 143 | + placeholder="่ฏท่พๅ ฅ้กน็ฎๅ็งฐ" style="width: 100%;" @change="getRemoteDate"> | |
| 144 | + <el-option v-for="item in data" :key="item.name" :label="item.name" :value="item.name" | |
| 144 | 145 | v-if="form.place == item.areaCode" /> |
| 145 | 146 | </el-select> |
| 146 | 147 | </el-form-item> |
| ... | ... | @@ -149,7 +150,7 @@ |
| 149 | 150 | <el-row :gutter="2"> |
| 150 | 151 | <el-col :span="11"> |
| 151 | 152 | <el-form-item label="ๅ ฌๅธ" prop="violationGrade"> |
| 152 | - <el-select v-model="form.companyName" placeholder="่ฏท้ๆฉๅ ฌๅธ" style="width: 100%;"> | |
| 153 | + <el-select v-model="form.companyName" placeholder="่ฏท้ๆฉๅ ฌๅธ" style="width: 100%;" :filter-method="getCompanys"> | |
| 153 | 154 | <el-option v-for="item in companyList" :label="item.name" :value="item.name" /> |
| 154 | 155 | </el-select> |
| 155 | 156 | </el-form-item> | ... | ... |
trash-ui/src/views/office/handle/index.vue
trash-workFlow/src/main/java/com/trash/business/controller/SupervisionThreestepController.java
| ... | ... | @@ -106,7 +106,6 @@ public class SupervisionThreestepController extends BaseController |
| 106 | 106 | } |
| 107 | 107 | } |
| 108 | 108 | } |
| 109 | - | |
| 110 | 109 | } |
| 111 | 110 | } |
| 112 | 111 | |
| ... | ... | @@ -252,6 +251,40 @@ public class SupervisionThreestepController extends BaseController |
| 252 | 251 | @PostMapping("/todayDataList") |
| 253 | 252 | public List<SupervisionThreestep> todayDataList(@RequestBody SupervisionThreestep supervisionThreestep) |
| 254 | 253 | { |
| 254 | + | |
| 255 | + Map<String, String> map = new HashMap<String, String>(); | |
| 256 | + map.put("type", "CSUserDepartmentType"); | |
| 257 | + JSONArray depts = RemoteServerUtils.getDict(map); | |
| 258 | + | |
| 259 | + for(Object object :depts){ | |
| 260 | + JSONObject dept = (JSONObject) object; | |
| 261 | + List<String> roles = SecurityUtils.getLoginUser().getUser().getRoleIds(); | |
| 262 | + | |
| 263 | + for(String role:roles){ | |
| 264 | + if(dept.getString("code").equals(role)){ | |
| 265 | + if(dept.getString("name").contains("ๆธฃๅๅ")){ | |
| 266 | + String areaCode = dept.getString("code"); | |
| 267 | + if(!areaCode.isEmpty()){ | |
| 268 | + supervisionThreestep.setPlace(areaCode); | |
| 269 | + supervisionThreestep.setCreateBy(null); | |
| 270 | + supervisionThreestep.setType(0L); | |
| 271 | + supervisionThreestep.setStatus(1L); | |
| 272 | + | |
| 273 | + | |
| 274 | + List<SupervisionThreestep> threesteps = supervisionThreestepService.selectTodayDataList(supervisionThreestep); | |
| 275 | + | |
| 276 | + return supervisionThreestepService.selectTodayDataList(supervisionThreestep); | |
| 277 | + } | |
| 278 | + } | |
| 279 | + } | |
| 280 | + } | |
| 281 | + } | |
| 282 | + supervisionThreestep.setCompanys(SecurityUtils.getUsername()); | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 255 | 288 | return supervisionThreestepService.selectTodayDataList(supervisionThreestep); |
| 256 | 289 | } |
| 257 | 290 | ... | ... |
trash-workFlow/src/main/java/com/trash/business/controller/TruckActivateController.java
| 1 | 1 | package com.trash.business.controller; |
| 2 | 2 | |
| 3 | +import java.util.ArrayList; | |
| 4 | +import java.util.HashMap; | |
| 3 | 5 | import java.util.List; |
| 4 | 6 | import java.util.Map; |
| 5 | 7 | |
| ... | ... | @@ -19,8 +21,16 @@ import com.trash.common.annotation.Log; |
| 19 | 21 | import com.trash.common.core.controller.BaseController; |
| 20 | 22 | import com.trash.common.core.domain.AjaxResult; |
| 21 | 23 | import com.trash.common.enums.BusinessType; |
| 24 | +import com.alibaba.fastjson.JSONArray; | |
| 25 | +import com.alibaba.fastjson.JSONObject; | |
| 26 | +import com.trash.business.domain.SupervisionThreestep; | |
| 22 | 27 | import com.trash.business.domain.TruckActivate; |
| 28 | +import com.trash.business.mapper.SupervisionThreestepMapper; | |
| 29 | +import com.trash.business.mapper.TruckActivateMapper; | |
| 30 | +import com.trash.business.service.ISupervisionThreestepService; | |
| 23 | 31 | import com.trash.business.service.ITruckActivateService; |
| 32 | +import com.trash.common.utils.RemoteServerUtils; | |
| 33 | +import com.trash.common.utils.SecurityUtils; | |
| 24 | 34 | import com.trash.common.utils.poi.ExcelUtil; |
| 25 | 35 | import com.trash.common.core.page.TableDataInfo; |
| 26 | 36 | |
| ... | ... | @@ -37,6 +47,11 @@ public class TruckActivateController extends BaseController |
| 37 | 47 | @Autowired |
| 38 | 48 | private ITruckActivateService truckActivateService; |
| 39 | 49 | |
| 50 | + @Autowired | |
| 51 | + private ISupervisionThreestepService threestepService; | |
| 52 | + | |
| 53 | + @Autowired | |
| 54 | + private TruckActivateMapper truckActivateMapper; | |
| 40 | 55 | /** |
| 41 | 56 | * ๆฅ่ฏข่ฝฆ่พๆฟๆดปๅ่กจ |
| 42 | 57 | */ |
| ... | ... | @@ -44,7 +59,65 @@ public class TruckActivateController extends BaseController |
| 44 | 59 | public TableDataInfo list(TruckActivate truckActivate) |
| 45 | 60 | { |
| 46 | 61 | startPage(); |
| 47 | - List<TruckActivate> list = truckActivateService.selectTruckActivateList(truckActivate); | |
| 62 | + | |
| 63 | + List<TruckActivate> list = new ArrayList<>(); | |
| 64 | + | |
| 65 | + Map<String, String> map = new HashMap<String, String>(); | |
| 66 | + map.put("type", "CSUserDepartmentType"); | |
| 67 | + JSONArray depts = RemoteServerUtils.getDict(map); | |
| 68 | + | |
| 69 | + for(Object object :depts){ | |
| 70 | + JSONObject dept = (JSONObject) object; | |
| 71 | + List<String> roles = SecurityUtils.getLoginUser().getUser().getRoleIds(); | |
| 72 | + | |
| 73 | + for(String role:roles){ | |
| 74 | + if(dept.getString("code").equals(role)){ | |
| 75 | + | |
| 76 | +// if(dept.getString("name").equals("ไบๅกไธญๅฟ")){ | |
| 77 | +// list = truckActivateService.selectTruckActivateList(truckActivate); | |
| 78 | +// return getDataTable(list); | |
| 79 | +// } | |
| 80 | + | |
| 81 | + if(dept.getString("name").contains("ๆธฃๅๅ")){ | |
| 82 | + String areaCode = dept.getString("code"); | |
| 83 | + if(!areaCode.isEmpty()){ | |
| 84 | + SupervisionThreestep supervisionThreestep = new SupervisionThreestep(); | |
| 85 | + supervisionThreestep.setPlace(areaCode); | |
| 86 | + supervisionThreestep.setCreateBy(null); | |
| 87 | + supervisionThreestep.setType(0L); | |
| 88 | + supervisionThreestep.setStatus(1L); | |
| 89 | + | |
| 90 | + | |
| 91 | + List<SupervisionThreestep> threesteps = threestepService.selectTodayDataList(supervisionThreestep); | |
| 92 | + String names = null; | |
| 93 | + for(SupervisionThreestep three :threesteps){ | |
| 94 | + if(names == null){ | |
| 95 | + names = three.getName(); | |
| 96 | + }else{ | |
| 97 | + names += "," + three.getName(); | |
| 98 | + } | |
| 99 | + } | |
| 100 | + | |
| 101 | + if(names == null){ | |
| 102 | + return getDataTable(list); | |
| 103 | + } | |
| 104 | + | |
| 105 | + truckActivate.setcIds(names.split(",")); | |
| 106 | + | |
| 107 | + list = truckActivateMapper.selectTruckActivateListByConstructions(truckActivate); | |
| 108 | + | |
| 109 | + return getDataTable(list); | |
| 110 | + | |
| 111 | + } | |
| 112 | + } | |
| 113 | + } | |
| 114 | + } | |
| 115 | + } | |
| 116 | + | |
| 117 | + truckActivate.setCompany(SecurityUtils.getUsername()); | |
| 118 | + | |
| 119 | + | |
| 120 | + list = truckActivateService.selectTruckActivateList(truckActivate); | |
| 48 | 121 | return getDataTable(list); |
| 49 | 122 | } |
| 50 | 123 | |
| ... | ... | @@ -136,11 +209,13 @@ public class TruckActivateController extends BaseController |
| 136 | 209 | public AjaxResult getConractByObjectId(@PathVariable("id") String id) |
| 137 | 210 | { |
| 138 | 211 | |
| 139 | - | |
| 140 | - | |
| 141 | 212 | AjaxResult ajaxResult = AjaxResult.success(); |
| 213 | + try { | |
| 214 | + ajaxResult.put("result", truckActivateService.getConractByObjectId(id)); | |
| 215 | + } catch (Exception e) { | |
| 216 | + e.printStackTrace(); | |
| 217 | + } | |
| 142 | 218 | |
| 143 | - ajaxResult.put("result", truckActivateService.getConractByObjectId(id)); | |
| 144 | 219 | |
| 145 | 220 | |
| 146 | 221 | return ajaxResult; | ... | ... |
trash-workFlow/src/main/java/com/trash/business/domain/TruckActivate.java
| ... | ... | @@ -25,6 +25,7 @@ public class TruckActivate extends BaseEntity |
| 25 | 25 | @Excel(name = "ๅทฅๅฐๅ็งฐ") |
| 26 | 26 | private String construction; |
| 27 | 27 | |
| 28 | + private String constructionId; | |
| 28 | 29 | /** ่ฝฆ็ๅท |
| 29 | 30 | */ |
| 30 | 31 | @Excel(name = "่ฝฆ็ๅท") |
| ... | ... | @@ -66,7 +67,27 @@ public class TruckActivate extends BaseEntity |
| 66 | 67 | |
| 67 | 68 | private String activateStatus; |
| 68 | 69 | |
| 69 | - public String getActivateStatus() { | |
| 70 | + private String[] cIds; | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + public String getConstructionId() { | |
| 75 | + return constructionId; | |
| 76 | + } | |
| 77 | + | |
| 78 | + public void setConstructionId(String constructionId) { | |
| 79 | + this.constructionId = constructionId; | |
| 80 | + } | |
| 81 | + | |
| 82 | + public String[] getcIds() { | |
| 83 | + return cIds; | |
| 84 | + } | |
| 85 | + | |
| 86 | + public void setcIds(String[] cIds) { | |
| 87 | + this.cIds = cIds; | |
| 88 | + } | |
| 89 | + | |
| 90 | + public String getActivateStatus() { | |
| 70 | 91 | return activateStatus; |
| 71 | 92 | } |
| 72 | 93 | ... | ... |
trash-workFlow/src/main/java/com/trash/business/mapper/TruckActivateMapper.java
| ... | ... | @@ -60,6 +60,8 @@ public interface TruckActivateMapper |
| 60 | 60 | * @return ็ปๆ |
| 61 | 61 | */ |
| 62 | 62 | public int deleteTruckActivateByIds(Long[] ids); |
| 63 | + | |
| 64 | + public List<TruckActivate> selectTruckActivateListByConstructions(TruckActivate truckActivate); | |
| 63 | 65 | |
| 64 | 66 | public void endAllTurckUnActive(); |
| 65 | 67 | ... | ... |
trash-workFlow/src/main/java/com/trash/business/service/impl/SupervisionThreestepServiceImpl.java
| ... | ... | @@ -25,6 +25,7 @@ import com.trash.business.mapper.TruckActivateMapper; |
| 25 | 25 | import com.trash.business.service.ISupervisionThreestepService; |
| 26 | 26 | import com.trash.business.service.ITruckActivateService; |
| 27 | 27 | import com.trash.common.config.trashConfig; |
| 28 | +import com.trash.common.core.redis.RedisCache; | |
| 28 | 29 | import com.trash.common.utils.DateUtils; |
| 29 | 30 | import com.trash.common.utils.RemoteServerUtils; |
| 30 | 31 | import com.trash.common.utils.SecurityUtils; |
| ... | ... | @@ -220,12 +221,22 @@ public class SupervisionThreestepServiceImpl implements ISupervisionThreestepSer |
| 220 | 221 | } |
| 221 | 222 | } |
| 222 | 223 | |
| 223 | - Map param = new HashMap<>(); | |
| 224 | 224 | |
| 225 | - param.put("page", 1); | |
| 226 | - param.put("size", 99999); | |
| 227 | - | |
| 228 | - JSONArray contracts = RemoteServerUtils.getContractList(param); | |
| 225 | + JSONArray contracts = redis.getCacheObject("contractList"); | |
| 226 | + | |
| 227 | + if(contracts == null){ | |
| 228 | + Map param = new HashMap<>(); | |
| 229 | + | |
| 230 | + param.put("page", 1); | |
| 231 | + param.put("size", 99999); | |
| 232 | + param.put("contractStatus", 1); | |
| 233 | + param.put("auditStatus", 1); | |
| 234 | + | |
| 235 | + | |
| 236 | + contracts = RemoteServerUtils.getContractList(param); | |
| 237 | + redis.setCacheObject("contractList",contracts); | |
| 238 | + } | |
| 239 | + | |
| 229 | 240 | |
| 230 | 241 | List<SupervisionThreestep> allList = supervisionThreestepMapper.selectDayWorkList(supervisionThreestep); |
| 231 | 242 | |
| ... | ... | @@ -290,6 +301,7 @@ public class SupervisionThreestepServiceImpl implements ISupervisionThreestepSer |
| 290 | 301 | continue; |
| 291 | 302 | } |
| 292 | 303 | |
| 304 | + | |
| 293 | 305 | Map<String,String> map = new HashMap<String, String>(); |
| 294 | 306 | map.put("id", s.getId() + ""); |
| 295 | 307 | map.put("createTime", yearFomat.format(s.getCreateTime())); |
| ... | ... | @@ -398,8 +410,6 @@ public class SupervisionThreestepServiceImpl implements ISupervisionThreestepSer |
| 398 | 410 | List<Map> list = new ArrayList<>(); |
| 399 | 411 | |
| 400 | 412 | for(Map m : map){ |
| 401 | - | |
| 402 | - | |
| 403 | 413 | if(supervisionThreestep.getType() == 0){ |
| 404 | 414 | JSONObject object = RemoteServerUtils.getConstructionInfo(m.get("id").toString()); |
| 405 | 415 | |
| ... | ... | @@ -791,15 +801,13 @@ public class SupervisionThreestepServiceImpl implements ISupervisionThreestepSer |
| 791 | 801 | } |
| 792 | 802 | return null; |
| 793 | 803 | } |
| 804 | + | |
| 805 | + @Autowired | |
| 806 | + RedisCache redis; | |
| 794 | 807 | |
| 795 | 808 | @Override |
| 796 | 809 | public void updateTodayData(String token){ |
| 797 | - Map param = new HashMap<>(); | |
| 798 | - | |
| 799 | - param.put("page", 1); | |
| 800 | - param.put("size", 99999); | |
| 801 | - | |
| 802 | - JSONArray contracts = RemoteServerUtils.getContractList(param,token); | |
| 810 | + | |
| 803 | 811 | |
| 804 | 812 | SupervisionThreestep supervisionThreestep = new SupervisionThreestep(); |
| 805 | 813 | |
| ... | ... | @@ -826,48 +834,70 @@ public class SupervisionThreestepServiceImpl implements ISupervisionThreestepSer |
| 826 | 834 | |
| 827 | 835 | List<SupervisionThreestep> list = supervisionThreestepMapper.selectSupervisionThreestepList(supervisionThreestep); |
| 828 | 836 | |
| 837 | + | |
| 838 | + | |
| 839 | + JSONArray contracts = redis.getCacheObject("contractList"); | |
| 829 | 840 | |
| 841 | + if(contracts == null){ | |
| 842 | + Map param = new HashMap<>(); | |
| 843 | + | |
| 844 | + param.put("page", 1); | |
| 845 | + param.put("size", 99999); | |
| 846 | + param.put("contractStatus", 1); | |
| 847 | + param.put("auditStatus", 1); | |
| 848 | + | |
| 849 | + contracts = RemoteServerUtils.getContractList(param,token); | |
| 850 | + redis.setCacheObject("contractList",contracts); | |
| 851 | + } | |
| 830 | 852 | |
| 831 | 853 | |
| 832 | - for(SupervisionThreestep s: list){ | |
| 833 | - String cid = ""; | |
| 834 | - String cname = ""; | |
| 835 | - String eid = ""; | |
| 836 | - String ename = ""; | |
| 854 | + | |
| 855 | + | |
| 856 | + if(list.size() > 0){ | |
| 857 | + | |
| 858 | + | |
| 859 | + | |
| 837 | 860 | |
| 838 | - for(Object object : contracts){ | |
| 839 | - JSONObject jsonObject = (JSONObject) object; | |
| 861 | + | |
| 862 | + for(SupervisionThreestep s: list){ | |
| 863 | + String cid = ""; | |
| 864 | + String cname = ""; | |
| 865 | + String eid = ""; | |
| 866 | + String ename = ""; | |
| 840 | 867 | |
| 841 | - if(s.getObjectId().equals(jsonObject.getString("constructionSiteID"))){ | |
| 842 | - cid += jsonObject.getString("id") + ","; | |
| 843 | - cname += jsonObject.getString("contractNo")+ ","; | |
| 844 | - eid += jsonObject.getString("earthSiteID")+ ","; | |
| 845 | - ename += jsonObject.getString("earthSiteName")+ ","; | |
| 868 | + for(Object object : contracts){ | |
| 869 | + JSONObject jsonObject = (JSONObject) object; | |
| 870 | + | |
| 871 | + if(s.getObjectId().equals(jsonObject.getString("constructionSiteID"))){ | |
| 872 | + cid += jsonObject.getString("id") + ","; | |
| 873 | + cname += jsonObject.getString("contractNo")+ ","; | |
| 874 | + eid += jsonObject.getString("earthSiteID")+ ","; | |
| 875 | + ename += jsonObject.getString("earthSiteName")+ ","; | |
| 876 | + } | |
| 877 | + | |
| 878 | + } | |
| 879 | + if(cid.length() > 0){ | |
| 880 | + cid = cid.substring(0,cid.length()-1); | |
| 846 | 881 | } |
| 882 | + if(cname.length() > 0){ | |
| 883 | + cname = cname.substring(0,cname.length()-1); | |
| 884 | + } | |
| 885 | + if(eid.length() > 0){ | |
| 886 | + eid = eid.substring(0,eid.length()-1); | |
| 887 | + } | |
| 888 | + if(ename.length() > 0){ | |
| 889 | + ename = ename.substring(0,ename.length()-1); | |
| 890 | + } | |
| 891 | + s.setContractId(cid); | |
| 892 | + s.setContract(cname); | |
| 893 | + s.setEarthsitesId(eid); | |
| 894 | + s.setEarthsitesName(ename); | |
| 847 | 895 | |
| 896 | + supervisionThreestepMapper.updateSupervisionThreestep(s); | |
| 848 | 897 | } |
| 849 | - if(cid.length() > 0){ | |
| 850 | - cid = cid.substring(0,cid.length()-1); | |
| 851 | - } | |
| 852 | - if(cname.length() > 0){ | |
| 853 | - cname = cid.substring(0,cname.length()-1); | |
| 854 | - } | |
| 855 | - if(eid.length() > 0){ | |
| 856 | - eid = cid.substring(0,eid.length()-1); | |
| 857 | - } | |
| 858 | - if(ename.length() > 0){ | |
| 859 | - ename = cid.substring(0,ename.length()-1); | |
| 860 | - } | |
| 861 | - s.setContractId(cid); | |
| 862 | - s.setContract(cname); | |
| 863 | - s.setEarthsitesId(eid); | |
| 864 | - s.setEarthsitesName(ename); | |
| 865 | 898 | |
| 866 | - supervisionThreestepMapper.updateSupervisionThreestep(s); | |
| 867 | 899 | } |
| 868 | 900 | |
| 869 | - | |
| 870 | - | |
| 871 | 901 | } |
| 872 | 902 | |
| 873 | 903 | @Override | ... | ... |
trash-workFlow/src/main/java/com/trash/business/service/impl/TruckActivateServiceImpl.java
| ... | ... | @@ -8,6 +8,7 @@ import java.util.HashMap; |
| 8 | 8 | import java.util.List; |
| 9 | 9 | import java.util.Map; |
| 10 | 10 | |
| 11 | +import com.trash.common.core.redis.RedisCache; | |
| 11 | 12 | import com.trash.common.utils.DateUtils; |
| 12 | 13 | import com.trash.common.utils.RemoteServerUtils; |
| 13 | 14 | |
| ... | ... | @@ -38,6 +39,8 @@ public class TruckActivateServiceImpl implements ITruckActivateService |
| 38 | 39 | |
| 39 | 40 | @Autowired |
| 40 | 41 | SupervisionThreestepMapper threestepMapper; |
| 42 | + | |
| 43 | + | |
| 41 | 44 | /** |
| 42 | 45 | * ๆฅ่ฏข่ฝฆ่พๆฟๆดป |
| 43 | 46 | * |
| ... | ... | @@ -96,117 +99,135 @@ public class TruckActivateServiceImpl implements ITruckActivateService |
| 96 | 99 | end += " 4:00:00"; |
| 97 | 100 | start += " 8:00:00"; |
| 98 | 101 | |
| 99 | - | |
| 100 | - truckActivate.setCreateTime(DateUtils.getNowDate()); | |
| 101 | - | |
| 102 | - | |
| 103 | - TruckActivate oldDate = truckActivateMapper.selectTodayTruckByObjId(truckActivate.getObjectId()); | |
| 104 | - | |
| 105 | - if(oldDate != null){ | |
| 106 | - | |
| 107 | - SupervisionThreestep threestep = new SupervisionThreestep(); | |
| 108 | - | |
| 109 | - threestep.setName(oldDate.getConstruction()); | |
| 110 | - threestep.setEarthsitesName(oldDate.getEarthsite()); | |
| 111 | - threestep.setCompanyTrucks(oldDate.getObjectId()); | |
| 112 | - | |
| 113 | - try { | |
| 114 | - threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 115 | - threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 116 | - } catch (Exception e) { | |
| 117 | - // TODO Auto-generated catch block | |
| 118 | - e.printStackTrace(); | |
| 119 | - } | |
| 120 | - | |
| 121 | - threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 122 | - | |
| 123 | - if(threestep == null){ | |
| 124 | - truckActivate.setId(oldDate.getId()); | |
| 125 | - return truckActivateMapper.updateTruckActivate(truckActivate); | |
| 126 | - | |
| 127 | - } | |
| 128 | - | |
| 129 | - if(threestep.getName().equals(truckActivate.getConstruction())){ | |
| 130 | - truckActivate.setId(oldDate.getId()); | |
| 131 | - return truckActivateMapper.updateTruckActivate(truckActivate); | |
| 102 | + String[] objs = truckActivate.getObjectId().split(","); | |
| 103 | + String[] nos = truckActivate.getLicensePlate().split(","); | |
| 104 | + | |
| 105 | + for(int i =0 ;i<objs.length;i++){ | |
| 106 | + | |
| 107 | + TruckActivate active = new TruckActivate(); | |
| 108 | + | |
| 109 | + active.setObjectId(objs[i]); | |
| 110 | + active.setLicensePlate(nos[i]); | |
| 111 | + active.setConstruction(truckActivate.getConstruction()); | |
| 112 | + active.setConstructionId(truckActivate.getConstructionId()); | |
| 113 | + active.setEarthsite(truckActivate.getEarthsite()); | |
| 114 | + active.setCompany(truckActivate.getCompany()); | |
| 115 | +// active.setCreateBy(Secr); | |
| 116 | + | |
| 117 | + active.setCreateTime(DateUtils.getNowDate()); | |
| 118 | + | |
| 119 | + TruckActivate oldDate = truckActivateMapper.selectTodayTruckByObjId(active.getObjectId()); | |
| 120 | + | |
| 121 | + if(oldDate != null){ | |
| 122 | + | |
| 123 | + SupervisionThreestep threestep = new SupervisionThreestep(); | |
| 124 | + | |
| 125 | + threestep.setName(oldDate.getConstruction()); | |
| 126 | + threestep.setObjectId(oldDate.getConstructionId()); | |
| 127 | + | |
| 128 | + try { | |
| 129 | + threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 130 | + threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 131 | + } catch (Exception e) { | |
| 132 | + // TODO Auto-generated catch block | |
| 133 | + e.printStackTrace(); | |
| 134 | + } | |
| 135 | + | |
| 136 | + threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 137 | + | |
| 138 | + if(threestep == null || threestep.getName().equals(truckActivate.getConstruction())){ | |
| 139 | + active.setId(oldDate.getId()); | |
| 140 | + truckActivateMapper.updateTruckActivate(active); | |
| 141 | + }else{ | |
| 142 | + Long threeId = threestep.getId(); | |
| 143 | + String trucks = threestep.getCompanyTrucks(); | |
| 144 | + | |
| 145 | + threestep = new SupervisionThreestep(); | |
| 146 | + | |
| 147 | + threestep.setId(threeId); | |
| 148 | + | |
| 149 | + trucks = trucks.replace(oldDate.getObjectId(), "").replace(",,", ","); | |
| 150 | + | |
| 151 | + if(trucks.length() == 1){ | |
| 152 | + trucks = ""; | |
| 153 | + } | |
| 154 | + | |
| 155 | + threestep.setCompanyTrucks(trucks); | |
| 156 | + | |
| 157 | + //ๅป้คๅทฒๆไธๆฅๆฐๆฎ็่ฝฆ่พ็ปๅฎ | |
| 158 | + threestepMapper.updateSupervisionThreestep(threestep); | |
| 159 | + } | |
| 160 | + | |
| 161 | + //ๆดๆฐ็ปๅฎ็ไธๆฅๆฐๆฎ | |
| 162 | + threestep = new SupervisionThreestep(); | |
| 163 | + | |
| 164 | + threestep.setObjectId(active.getConstructionId()); | |
| 165 | + | |
| 166 | + try { | |
| 167 | + threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 168 | + threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 169 | + } catch (Exception e) { | |
| 170 | + // TODO Auto-generated catch block | |
| 171 | + e.printStackTrace(); | |
| 172 | + } | |
| 173 | + | |
| 174 | + threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 175 | + | |
| 176 | + String trucks = threestep.getCompanyTrucks(); | |
| 177 | + | |
| 178 | + if(trucks == null || trucks.isEmpty()){ | |
| 179 | + trucks = active.getObjectId(); | |
| 180 | + }else{ | |
| 181 | + if(!trucks.contains(active.getObjectId())){ | |
| 182 | + trucks += "," + active.getObjectId(); | |
| 183 | + } | |
| 184 | + } | |
| 185 | + | |
| 186 | + threestep.setCompanyTrucks(trucks); | |
| 187 | + | |
| 188 | + threestepMapper.updateSupervisionThreestep(threestep); | |
| 189 | + | |
| 190 | + active.setId(oldDate.getId());//ๆดๆฐๅทฒๆ่ฝฆ่พๆฟๆดปๆฐๆฎ | |
| 191 | + | |
| 192 | + truckActivateMapper.updateTruckActivate(active); | |
| 193 | + continue; | |
| 132 | 194 | }else{ |
| 133 | - Long threeId = threestep.getId(); | |
| 134 | - String trucks = threestep.getCompanyTrucks(); | |
| 135 | - | |
| 136 | - threestep = new SupervisionThreestep(); | |
| 137 | - | |
| 138 | - threestep.setId(threeId); | |
| 139 | - | |
| 140 | - trucks = trucks.replace(oldDate.getObjectId(), "").replace(",,", ","); | |
| 141 | - | |
| 142 | - threestep.setCompanyTrucks(trucks); | |
| 143 | - | |
| 144 | - //ๅป้คๅทฒๆไธๆฅๆฐๆฎ็่ฝฆ่พ็ปๅฎ | |
| 145 | - threestepMapper.updateSupervisionThreestep(threestep); | |
| 146 | - | |
| 147 | - //ๆดๆฐ็ปๅฎ็ไธๆฅๆฐๆฎ | |
| 148 | - threestep = new SupervisionThreestep(); | |
| 149 | - | |
| 150 | - threestep.setName(truckActivate.getConstruction()); | |
| 151 | - threestep.setEarthsitesName(truckActivate.getEarthsite()); | |
| 152 | - try { | |
| 153 | - threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 154 | - threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 155 | - } catch (Exception e) { | |
| 156 | - // TODO Auto-generated catch block | |
| 157 | - e.printStackTrace(); | |
| 158 | - } | |
| 159 | 195 | |
| 160 | - threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 161 | - | |
| 162 | - trucks = threestep.getCompanyTrucks(); | |
| 196 | + SupervisionThreestep threestep = new SupervisionThreestep(); | |
| 197 | + | |
| 198 | +// threestep.setName(truckActivate.getConstruction()); | |
| 199 | +// threestep.setCompanys(truckActivate.getCompany()); | |
| 200 | + threestep.setObjectId(active.getConstructionId()); | |
| 201 | + | |
| 202 | + try { | |
| 203 | + threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 204 | + threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 205 | + } catch (Exception e) { | |
| 206 | + // TODO Auto-generated catch block | |
| 207 | + e.printStackTrace(); | |
| 208 | + } | |
| 209 | + | |
| 210 | + threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 211 | + | |
| 212 | + String trucks = threestep.getCompanyTrucks(); | |
| 163 | 213 | |
| 164 | 214 | if(trucks == null || trucks.isEmpty()){ |
| 165 | - trucks = truckActivate.getObjectId(); | |
| 215 | + trucks = active.getObjectId(); | |
| 166 | 216 | }else{ |
| 167 | - trucks += "," + truckActivate.getObjectId(); | |
| 217 | + trucks += "," + active.getObjectId(); | |
| 168 | 218 | } |
| 169 | 219 | |
| 170 | 220 | threestep.setCompanyTrucks(trucks); |
| 171 | 221 | |
| 172 | 222 | threestepMapper.updateSupervisionThreestep(threestep); |
| 173 | - | |
| 174 | - truckActivate.setId(oldDate.getId());//ๆดๆฐๅทฒๆ่ฝฆ่พๆฟๆดปๆฐๆฎ | |
| 175 | - | |
| 176 | - return truckActivateMapper.updateTruckActivate(truckActivate); | |
| 177 | - } | |
| 178 | - }else{ | |
| 179 | - | |
| 180 | - SupervisionThreestep threestep = new SupervisionThreestep(); | |
| 181 | - | |
| 182 | - threestep.setName(truckActivate.getConstruction()); | |
| 183 | - threestep.setEarthsitesName(truckActivate.getEarthsite()); | |
| 184 | - | |
| 185 | - try { | |
| 186 | - threestep.setWorkStartTime(DateUtils.parseDate(start)); | |
| 187 | - threestep.setWorkEndTime(DateUtils.parseDate(end)); | |
| 188 | - } catch (Exception e) { | |
| 189 | - // TODO Auto-generated catch block | |
| 190 | - e.printStackTrace(); | |
| 191 | - } | |
| 192 | - | |
| 193 | - threestep = threestepMapper.selectThreestepByTruckDate(threestep); | |
| 194 | - | |
| 195 | - String trucks = threestep.getCompanyTrucks(); | |
| 196 | - | |
| 197 | - if(trucks == null || trucks.isEmpty()){ | |
| 198 | - trucks = truckActivate.getObjectId(); | |
| 199 | - }else{ | |
| 200 | - trucks += "," + truckActivate.getObjectId(); | |
| 201 | - } | |
| 202 | - | |
| 203 | - threestep.setCompanyTrucks(trucks); | |
| 204 | - | |
| 205 | - threestepMapper.updateSupervisionThreestep(threestep); | |
| 206 | - | |
| 207 | - return truckActivateMapper.insertTruckActivate(truckActivate); | |
| 208 | - } | |
| 223 | + | |
| 224 | + truckActivateMapper.insertTruckActivate(active); | |
| 225 | + continue; | |
| 226 | + } | |
| 227 | + } | |
| 209 | 228 | |
| 229 | + | |
| 230 | + return objs.length; | |
| 210 | 231 | |
| 211 | 232 | |
| 212 | 233 | } |
| ... | ... | @@ -250,7 +271,9 @@ public class TruckActivateServiceImpl implements ITruckActivateService |
| 250 | 271 | return truckActivateMapper.deleteTruckActivateById(id); |
| 251 | 272 | } |
| 252 | 273 | |
| 253 | - | |
| 274 | + @Autowired | |
| 275 | + RedisCache redis; | |
| 276 | + | |
| 254 | 277 | @Override |
| 255 | 278 | public String getConractByObjectId(String id){ |
| 256 | 279 | |
| ... | ... | @@ -297,13 +320,27 @@ public class TruckActivateServiceImpl implements ITruckActivateService |
| 297 | 320 | |
| 298 | 321 | List<String> ids =new ArrayList<>(); |
| 299 | 322 | |
| 300 | - ids.add(m.get("object_id")); | |
| 323 | + if(m == null)return null; | |
| 301 | 324 | |
| 302 | - param.put("constructionSiteID", ids); | |
| 303 | - param.put("page", 1); | |
| 304 | - param.put("size", 99999); | |
| 305 | 325 | |
| 306 | - JSONArray array = RemoteServerUtils.getContractList(param); | |
| 326 | + JSONArray contracts = redis.getCacheObject("contractList"); | |
| 327 | + | |
| 328 | + if(contracts == null){ | |
| 329 | + param.put("page", 1); | |
| 330 | + param.put("size", 99999); | |
| 331 | + | |
| 332 | + contracts = RemoteServerUtils.getContractList(param); | |
| 333 | + redis.setCacheObject("contractList",contracts); | |
| 334 | + } | |
| 335 | + | |
| 336 | + JSONArray array = new JSONArray(); | |
| 337 | + for(Object obj :array){ | |
| 338 | + JSONObject jsonObject = (JSONObject)obj; | |
| 339 | + | |
| 340 | + if(m.get("object_id").equals(jsonObject.getString("constructionSiteID"))){ | |
| 341 | + array.add(obj); | |
| 342 | + } | |
| 343 | + } | |
| 307 | 344 | |
| 308 | 345 | if(array == null || m.size() == 0){ |
| 309 | 346 | return null; |
| ... | ... | @@ -325,7 +362,9 @@ public class TruckActivateServiceImpl implements ITruckActivateService |
| 325 | 362 | } |
| 326 | 363 | } |
| 327 | 364 | |
| 328 | - | |
| 365 | + if(conractIds.length() == 0){ | |
| 366 | + return conractIds; | |
| 367 | + } | |
| 329 | 368 | return conractIds.substring(0,conractIds.length()-1); |
| 330 | 369 | } |
| 331 | 370 | ... | ... |
trash-workFlow/src/main/java/com/trash/caseOffline/domain/CaseOffline.java
| ... | ... | @@ -30,7 +30,7 @@ public class CaseOffline extends BaseEntity |
| 30 | 30 | + "่ฝฆ่ฝฎๅธฆๆณฅ,1=ๆชๆด่ฝฆๅบๅบๆ่ ๅบๅบๆธ ๆดไธๅฝปๅบ,2=ๆธฃๅ่ฟ่พ่ฝฆ่พ่ดง็ฎฑ้กถ็ๆชๆ่งๅฎๅ ณ้ญๅฐไฝๆๆชๆ่งๅฎๅๆ ๅ่ฃ ่ฝฝๆธฃๅๅบๅบ," |
| 31 | 31 | + "3=้ๆ ธๅ่ฝฆ่พ่ฟๅ ฅๆธฃๅๅค็ฝฎๅทฅๅฐ่ฟ่พๆธฃๅ,4=ๆธฃๅๅค็ฝฎๅทฅๅฐๆชๆ่งๅฎๆถ้ดๅผๅๅทฅ," |
| 32 | 32 | + "5=ๆธฃๅๅค็ฝฎๅทฅๅฐๆด่ฝฆ่ฎพๆฝ็ญ็ ดๆใๆชๆญฃๅธธไฝฟ็จๅๆชๆฝไธๅฐไฝ็,6=ๆธฃๅๅค็ฝฎๅทฅๅฐใๆถ็บณๅบ(ๅซๅๅกซๅบ๏ผๅบๅ ฅๅฃไธคไพง50็ฑณ่ๅดๅ ๅบ็ฐๆธฃๅๆฑกๆใๆฑกๆฐดๅคๆ็ญ็ฐ่ฑก" |
| 33 | - + "7=ๆ ่ฎธๅฏๆถ็บณ๏ผๅทฅ๏ผ,8=ๆ ่ฎธๅฏๆถ็บณ๏ผๆถ๏ผ,9=ๅ ถไป3") | |
| 33 | + + "7=ๆ ่ฎธๅฏๆถ็บณ๏ผๅทฅ๏ผ,8=ๆ ่ฎธๅฏๆถ็บณ๏ผๆถ๏ผ,9=ไฝฟ็จ้ไธ็จ่ฝฆ่พ") | |
| 34 | 34 | private String type; |
| 35 | 35 | |
| 36 | 36 | ... | ... |
trash-workFlow/src/main/java/com/trash/casefile/kafka/Consumer.java
| ... | ... | @@ -57,7 +57,10 @@ public class Consumer { |
| 57 | 57 | RedisCache redisCache; |
| 58 | 58 | |
| 59 | 59 | public void autoViolationWarning(String data,String id) throws InterruptedException, IOException { |
| 60 | - | |
| 60 | + | |
| 61 | + if(1==1) | |
| 62 | + return; | |
| 63 | + | |
| 61 | 64 | String[] code = {"44030020=ๅทฅๅฐ้ข่ญฆ-ๆชๆฅๅผๅทฅไฝไธ", "44030021=ๅทฅๅฐ้ข่ญฆ-่ง้ข่ฎพๅค็ฆป็บฟ่ถ ๆถๆฅ่ญฆ", "44030022=ๅทฅๅฐ้ข่ญฆ-ไธๆ ่ฝฆ่พ่ฟๅ ฅๅทฅๅฐ", "44030023=ๅทฅๅฐ้ข่ญฆ-ๆชๆๆถ้ดไฝไธ", |
| 62 | 65 | "44030024=ๆถ็บณๅบ้ข่ญฆ-ๆชๆฅๅผๅทฅไฝไธ", "44030025=ๆถ็บณๅบ้ข่ญฆ-่ง้ข่ฎพๅค็ฆป็บฟ่ถ ๆถๆฅ่ญฆ", "44030026=ๆถ็บณๅบ้ข่ญฆ-ไธๆ ่ฝฆ่พ่ฟๅ ฅๆถ็บณๅบ", "44030027=ๆถ็บณๅบ้ข่ญฆ-ๆชๅฐๆๅฎ็ๆถ็บณๅบไฝไธ", |
| 63 | 66 | "44030028=็ฆป็บฟ่ฟ่พๆฅ่ญฆ(ๅทฅ)", "44030029=็ฆป็บฟ่ฟ่พๆฅ่ญฆ(ๆถ)", "44030030=ๆชๆฟๆดป่ฝฆ่พไฝไธ", "44030031=ๆชๆ ธๅไฝไธ่ฝฆ่พไฝไธ", "44030032=ๆชๆ็บฟ่ทฏ่ก้ฉถ", | ... | ... |
trash-workFlow/src/main/java/com/trash/workflow/listener/baseDataListener.java
| ... | ... | @@ -47,8 +47,11 @@ public class baseDataListener implements ExecutionListener { |
| 47 | 47 | if(delegateExecution.getProcessInstanceBusinessKey().contains("driver")){ |
| 48 | 48 | object = (boolean)RemoteServerUtils.updateDriverAudit(list); |
| 49 | 49 | } |
| 50 | + | |
| 51 | + log.info("baseDataListener:" + delegateExecution.getProcessInstanceBusinessKey().split(":")[1] + "" + object); | |
| 52 | + | |
| 50 | 53 | } catch (Exception e) { |
| 51 | - // TODO: handle exception | |
| 54 | + e.printStackTrace(); | |
| 52 | 55 | } |
| 53 | 56 | |
| 54 | 57 | |
| ... | ... | @@ -59,30 +62,33 @@ public class baseDataListener implements ExecutionListener { |
| 59 | 62 | @Override |
| 60 | 63 | public void run() { |
| 61 | 64 | while(true){ |
| 62 | - | |
| 63 | - boolean object = false; | |
| 64 | - if(delegateExecution.getProcessInstanceBusinessKey().contains("company")){ | |
| 65 | - object = (boolean)RemoteServerUtils.updateCompanyAudit(list,token); | |
| 66 | - } | |
| 67 | - if(delegateExecution.getProcessInstanceBusinessKey().contains("vehicle")){ | |
| 68 | - object = (boolean)RemoteServerUtils.updateTruckAudit(list,token); | |
| 69 | - } | |
| 70 | - if(delegateExecution.getProcessInstanceBusinessKey().contains("driver")){ | |
| 71 | - object = (boolean)RemoteServerUtils.updateDriverAudit(list,token); | |
| 72 | - } | |
| 73 | - | |
| 74 | - | |
| 75 | - if(object){ | |
| 76 | - break; | |
| 77 | - } | |
| 78 | - | |
| 79 | - try { | |
| 80 | - log.info("baseDataListener:" + delegateExecution.getProcessInstanceBusinessKey().split(":")[1] + "" + object); | |
| 81 | - Thread.sleep(3000); | |
| 82 | - } catch (InterruptedException e) { | |
| 83 | - // TODO Auto-generated catch block | |
| 65 | + try { | |
| 66 | + | |
| 67 | + boolean object = false; | |
| 68 | + if(delegateExecution.getProcessInstanceBusinessKey().contains("company")){ | |
| 69 | + object = (boolean)RemoteServerUtils.updateCompanyAudit(list,token); | |
| 70 | + } | |
| 71 | + if(delegateExecution.getProcessInstanceBusinessKey().contains("vehicle")){ | |
| 72 | + object = (boolean)RemoteServerUtils.updateTruckAudit(list,token); | |
| 73 | + } | |
| 74 | + if(delegateExecution.getProcessInstanceBusinessKey().contains("driver")){ | |
| 75 | + object = (boolean)RemoteServerUtils.updateDriverAudit(list,token); | |
| 76 | + } | |
| 77 | + | |
| 78 | + try { | |
| 79 | + log.info("baseDataListener:" + delegateExecution.getProcessInstanceBusinessKey().split(":")[1] + "" + object); | |
| 80 | + Thread.sleep(3000); | |
| 81 | + } catch (InterruptedException e) { | |
| 82 | + // TODO Auto-generated catch block | |
| 83 | + e.printStackTrace(); | |
| 84 | + } | |
| 85 | + if(object){ | |
| 86 | + break; | |
| 87 | + } | |
| 88 | + | |
| 89 | + } catch (Exception e) { | |
| 84 | 90 | e.printStackTrace(); |
| 85 | - } | |
| 91 | + } | |
| 86 | 92 | |
| 87 | 93 | } |
| 88 | 94 | ... | ... |
trash-workFlow/src/main/java/com/trash/workflow/service/impl/WorkflowServiceImpl.java
| ... | ... | @@ -84,7 +84,8 @@ public class WorkflowServiceImpl implements IWorkflowService { |
| 84 | 84 | |
| 85 | 85 | String siteType[] = { "ๆถ็บณๅบ", "ๅปบ็ญๅๅพ่ตๆบๅๅค็ฝฎๅบ", "็พๆๅ็ฏไฟๅค็ฝฎๅบ", "็พๆๅๅบๆฅๆถ็บณๅบ", "ๅๅกซๅบ" }; |
| 86 | 86 | |
| 87 | - String outArea = "430201,430302,430624,430681"; | |
| 87 | + String outArea = "ๆ ชๆดฒๅธ,ๆนๆฝญๅธ,ๆฑจ็ฝๅธ,ๆน้ดๅฟ"; | |
| 88 | + | |
| 88 | 89 | |
| 89 | 90 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| 90 | 91 | |
| ... | ... | @@ -115,12 +116,19 @@ public class WorkflowServiceImpl implements IWorkflowService { |
| 115 | 116 | String endTime = map.get("endTime").toString(); |
| 116 | 117 | String areaCode = null; |
| 117 | 118 | int index = 0; |
| 119 | + JSONArray areas = RemoteServerUtils.getAreas(); | |
| 118 | 120 | if (map.get("area") != null){ |
| 119 | 121 | areaCode = map.get("area").toString(); |
| 120 | - | |
| 121 | - if(outArea.contains(areaCode)){ | |
| 122 | - index = 1; | |
| 122 | + for(Object obj : areas){ | |
| 123 | + JSONObject jsonObject = (JSONObject) obj; | |
| 124 | + if(areaCode.equals(jsonObject.getString("code"))){ | |
| 125 | + if(outArea.contains(jsonObject.getString("name"))){ | |
| 126 | + index = 1; | |
| 127 | + } | |
| 128 | + break; | |
| 129 | + } | |
| 123 | 130 | } |
| 131 | + | |
| 124 | 132 | } |
| 125 | 133 | |
| 126 | 134 | ProcessInstance processInstance = null; |
| ... | ... | @@ -253,7 +261,11 @@ public class WorkflowServiceImpl implements IWorkflowService { |
| 253 | 261 | String title = "ๆกๅทๅท:" + caseFile.getNumber(); |
| 254 | 262 | String flowType = "workflow_casefile"; |
| 255 | 263 | try { |
| 256 | - | |
| 264 | + | |
| 265 | + if(caseFile.getOwningRegion().contains("ๆนๆฑๆฐๅบ")){ | |
| 266 | + index += 3; | |
| 267 | + } | |
| 268 | + | |
| 257 | 269 | processInstance = processRuntime |
| 258 | 270 | .start(ProcessPayloadBuilder.start().withProcessDefinitionKey(flowType).withName(title) |
| 259 | 271 | .withBusinessKey(flowType + ":" + caseFile.getId()).withVariable("route", index).build()); |
| ... | ... | @@ -304,6 +316,11 @@ public class WorkflowServiceImpl implements IWorkflowService { |
| 304 | 316 | org.activiti.engine.runtime.ProcessInstance instance = null; |
| 305 | 317 | String title = "ๆกๅทๅท:" + caseFile.getNumber(); |
| 306 | 318 | String flowType = "violation_warning"; |
| 319 | + | |
| 320 | + if(caseFile.getOwningRegion().contains("ๆนๆฑๆฐๅบ")){ | |
| 321 | + index += 3; | |
| 322 | + } | |
| 323 | + | |
| 307 | 324 | try { |
| 308 | 325 | Map map = new HashedMap<>(); |
| 309 | 326 | ... | ... |
trash-workFlow/src/main/resources/mapper/SupervisionThreestepMapper.xml
| ... | ... | @@ -222,6 +222,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 222 | 222 | <where> |
| 223 | 223 | <if test="type != null"> and type = #{type} </if> |
| 224 | 224 | <if test="objectId != null and objectId != ''"> and object_id = #{objectId} </if> |
| 225 | + <if test="companyTrucks != null"> | |
| 226 | + and company_trucks like concat('%', #{companyTrucks}, '%') | |
| 227 | + </if> | |
| 225 | 228 | and self_check_time BETWEEN #{workStartTime} and #{workEndTime} |
| 226 | 229 | and status = 1 |
| 227 | 230 | </where> |
| ... | ... | @@ -230,11 +233,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 230 | 233 | |
| 231 | 234 | <select id="selectThreestepByTruckDate" parameterType="SupervisionThreestep" resultMap="SupervisionThreestepResult"> |
| 232 | 235 | select * from supervision_threestep |
| 233 | - where name = #{name} | |
| 234 | - and earthsites_name = #{earthsitesName} | |
| 235 | - <if test="companyTrucks != null"> | |
| 236 | - and company_trucks like concat('%', #{companyTrucks}, '%') | |
| 237 | - </if> | |
| 236 | + where object_id = #{objectId} | |
| 238 | 237 | and type = 0 |
| 239 | 238 | and status = 1 |
| 240 | 239 | and self_check_time BETWEEN #{workStartTime} and #{workEndTime} |
| ... | ... | @@ -263,7 +262,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 263 | 262 | resultMap="SupervisionThreestepResult"> |
| 264 | 263 | <include refid="selectSupervisionThreestepVo" /> |
| 265 | 264 | <where> |
| 266 | - <if test="status != null"> status = #{status}</if> | |
| 265 | + <if test="companys != null">and companys like concat('%', #{companys}, '%')</if> | |
| 266 | + <if test="place != null and place != ''"> and place = #{place}</if> | |
| 267 | + <if test="status != null">and status = #{status}</if> | |
| 267 | 268 | and type = #{type} |
| 268 | 269 | and self_check_time BETWEEN #{workStartTime} and #{workEndTime} |
| 269 | 270 | </where> | ... | ... |
trash-workFlow/src/main/resources/mapper/TruckActivateMapper.xml
| ... | ... | @@ -10,6 +10,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 10 | 10 | <result property="licensePlate" column="license_plate" /> |
| 11 | 11 | <result property="time" column="time" /> |
| 12 | 12 | <result property="construction" column="construction" /> |
| 13 | + <result property="constructionId" column="construction_id" /> | |
| 13 | 14 | <result property="status" column="status" /> |
| 14 | 15 | <result property="earthsite" column="earthsite" /> |
| 15 | 16 | <result property="objectId" column="object_id" /> |
| ... | ... | @@ -20,7 +21,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 20 | 21 | </resultMap> |
| 21 | 22 | |
| 22 | 23 | <sql id="selectTruckActivateVo"> |
| 23 | - select id, company, license_plate, time, construction, status, earthsite, object_id, create_by, create_type, activate_time, create_time from truck_activate | |
| 24 | + select id, company, license_plate, time, construction,construction_id, status, earthsite, object_id, create_by, create_type, activate_time, create_time from truck_activate | |
| 24 | 25 | </sql> |
| 25 | 26 | |
| 26 | 27 | <select id="selectTruckActivateList" parameterType="TruckActivate" resultMap="TruckActivateResult"> |
| ... | ... | @@ -30,6 +31,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 30 | 31 | <if test="licensePlate != null and licensePlate != ''"> and license_plate like concat('%', #{licensePlate}, '%')</if> |
| 31 | 32 | <if test="time != null "> and time = #{time}</if> |
| 32 | 33 | <if test="construction != null and construction != ''"> and construction = #{construction}</if> |
| 34 | + <if test="constructionId != null and constructionId != ''"> and construction_id = #{constructionId}</if> | |
| 33 | 35 | <if test="status != null "> and status = #{status}</if> |
| 34 | 36 | <if test="earthsite != null and earthsite != ''"> and earthsite = #{earthsite}</if> |
| 35 | 37 | <if test="objectId != null and objectId != ''"> and object_id = #{objectId}</if> |
| ... | ... | @@ -42,6 +44,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 42 | 44 | </where> |
| 43 | 45 | </select> |
| 44 | 46 | |
| 47 | + <select id="selectTruckActivateListByConstructions" parameterType="TruckActivate" resultMap="TruckActivateResult"> | |
| 48 | + <include refid="selectTruckActivateVo"/> | |
| 49 | + <where> construction in | |
| 50 | + <foreach item="id" collection="cIds" open="(" separator="," close=")"> | |
| 51 | + #{id} | |
| 52 | + </foreach> | |
| 53 | + <if test="activateStatus == 0 "> and activate_time is null</if> | |
| 54 | + <if test="activateStatus == 1 "> and activate_time is not null</if> | |
| 55 | + <if test="status != null "> and status = #{status}</if> | |
| 56 | + </where> | |
| 57 | + </select> | |
| 58 | + | |
| 45 | 59 | <select id="getActivedTruckList" parameterType="TruckActivate" resultMap="TruckActivateResult"> |
| 46 | 60 | select object_id,create_time,activate_time from truck_activate |
| 47 | 61 | <where> |
| ... | ... | @@ -97,6 +111,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 97 | 111 | <if test="licensePlate != null">license_plate,</if> |
| 98 | 112 | <if test="time != null">time,</if> |
| 99 | 113 | <if test="construction != null">construction,</if> |
| 114 | + <if test="constructionId != null and constructionId != ''">construction_id,</if> | |
| 100 | 115 | <if test="status != null">status,</if> |
| 101 | 116 | <if test="earthsite != null">earthsite,</if> |
| 102 | 117 | <if test="objectId != null">object_id,</if> |
| ... | ... | @@ -110,6 +125,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 110 | 125 | <if test="licensePlate != null">#{licensePlate},</if> |
| 111 | 126 | <if test="time != null">#{time},</if> |
| 112 | 127 | <if test="construction != null">#{construction},</if> |
| 128 | + <if test="constructionId != null and constructionId != ''"> #{constructionId},</if> | |
| 113 | 129 | <if test="status != null">#{status},</if> |
| 114 | 130 | <if test="earthsite != null">#{earthsite},</if> |
| 115 | 131 | <if test="objectId != null">#{objectId},</if> |
| ... | ... | @@ -127,6 +143,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| 127 | 143 | <if test="licensePlate != null">license_plate = #{licensePlate},</if> |
| 128 | 144 | <if test="time != null">time = #{time},</if> |
| 129 | 145 | <if test="construction != null">construction = #{construction},</if> |
| 146 | + <if test="constructionId != null and constructionId != ''"> construction_id = #{constructionId},</if> | |
| 130 | 147 | <if test="status != null">status = #{status},</if> |
| 131 | 148 | <if test="earthsite != null">earthsite = #{earthsite},</if> |
| 132 | 149 | <if test="objectId != null">object_id = #{objectId},</if> | ... | ... |