public ZfdServiceApply findByAllId(String id); | public ZfdServiceApply findByAllId(String id); | ||||
@Query(nativeQuery=true,value="select * from zfd_service_apply where AUDIT_TIME<=?1") | |||||
@Query(nativeQuery=true,value="select * from zfd_service_apply where AUDIT_TIME<=?1 and STATUS ='PASSED'") | |||||
public List<ZfdServiceApply> listByApplyAuditTime(LocalDateTime auditTime); | public List<ZfdServiceApply> listByApplyAuditTime(LocalDateTime auditTime); | ||||
* @param zfdServiceApply | * @param zfdServiceApply | ||||
* @throws ManagerException | * @throws ManagerException | ||||
*/ | */ | ||||
void update(@Valid ZfdServiceApply zfdServiceApply,User user) throws ManagerException; | |||||
void approval(@Valid ZfdServiceApply zfdServiceApply,User user) throws ManagerException; | |||||
/** | /** | ||||
* 服务结束 | * 服务结束 | ||||
* @param zfdServiceApply | * @param zfdServiceApply | ||||
*/ | */ | ||||
void updateFinish(@Valid ZfdServiceApply zfdServiceApply); | |||||
void serviceFinish(@Valid ZfdServiceApply zfdServiceApply); | |||||
List<ZfdServiceApply> findAll(); | List<ZfdServiceApply> findAll(); |
*/ | */ | ||||
@Transactional | @Transactional | ||||
@Override | @Override | ||||
public void update(@Valid ZfdServiceApply zfdServiceApply,User user) throws ManagerException { | |||||
public void approval(@Valid ZfdServiceApply zfdServiceApply,User user) throws ManagerException { | |||||
//业务校验 | //业务校验 | ||||
ZfdServiceApply applyInDb = zfdServiceApplyRepo.findByAllId(zfdServiceApply.getId()); | ZfdServiceApply applyInDb = zfdServiceApplyRepo.findByAllId(zfdServiceApply.getId()); | ||||
if(applyInDb == null) throw new ManagerException("未找到该申请,申请编号:"+ zfdServiceApply.getId()); | if(applyInDb == null) throw new ManagerException("未找到该申请,申请编号:"+ zfdServiceApply.getId()); | ||||
*/ | */ | ||||
@Transactional | @Transactional | ||||
@Override | @Override | ||||
public void updateFinish(@Valid ZfdServiceApply zfdServiceApply) { | |||||
public void serviceFinish(@Valid ZfdServiceApply zfdServiceApply) { | |||||
ZfdServiceApply zfdServiceApplys = zfdServiceApplyRepo.findByAllId(zfdServiceApply.getId()); | ZfdServiceApply zfdServiceApplys = zfdServiceApplyRepo.findByAllId(zfdServiceApply.getId()); | ||||
//将从库里面查询的值进行非空校验 | //将从库里面查询的值进行非空校验 | ||||
if(zfdServiceApplys !=null){ | if(zfdServiceApplys !=null){ |
private String ssoTicket = "24 1/6 * * * ?"; | private String ssoTicket = "24 1/6 * * * ?"; | ||||
private String test = "1/5 * * * * ?"; | private String test = "1/5 * * * * ?"; | ||||
private String test2 = "0/5 * * * * ?"; | private String test2 = "0/5 * * * * ?"; | ||||
private String zfdServiceApply = "* * * 1/1 * ?";//每天跑一次 | |||||
private String zfdServiceApply = "0 0 2 * * ?";//每天2点触发 | |||||
public String getZfdServiceApply() { | public String getZfdServiceApply() { | ||||
return zfdServiceApply; | return zfdServiceApply; |
HttpServletResponse response) throws IOException, ManagerException | HttpServletResponse response) throws IOException, ManagerException | ||||
{ | { | ||||
logger.info(zfdServiceApply.toJson()); | logger.info(zfdServiceApply.toJson()); | ||||
serviceRequestInquiryManager.update(zfdServiceApply,LoginHelper.getLoginUser(request)); | |||||
serviceRequestInquiryManager.approval(zfdServiceApply,LoginHelper.getLoginUser(request)); | |||||
model.addAttribute("model", zfdServiceApply); | model.addAttribute("model", zfdServiceApply); | ||||
addSuccess(response, "审批完成!"); | addSuccess(response, "审批完成!"); | ||||
addLog(request, LogType.SERVICE_APPROVAL, "用户({})审批{}完成", LoginHelper.getLoginUser(request).getName(),zfdServiceApply.getId()); | addLog(request, LogType.SERVICE_APPROVAL, "用户({})审批{}完成", LoginHelper.getLoginUser(request).getName(),zfdServiceApply.getId()); | ||||
public String processFinish(@Valid @ModelAttribute("pageModel") ZfdServiceApply zfdServiceApply, Model model,HttpServletRequest request, | public String processFinish(@Valid @ModelAttribute("pageModel") ZfdServiceApply zfdServiceApply, Model model,HttpServletRequest request, | ||||
HttpServletResponse response) throws IOException, ManagerException | HttpServletResponse response) throws IOException, ManagerException | ||||
{ | { | ||||
serviceRequestInquiryManager.updateFinish(zfdServiceApply); | |||||
serviceRequestInquiryManager.serviceFinish(zfdServiceApply); | |||||
model.addAttribute("model", zfdServiceApply); | model.addAttribute("model", zfdServiceApply); | ||||
addSuccess(response, "服务结束!"); | addSuccess(response, "服务结束!"); | ||||
addLog(request, LogType.END_OF_SERVICE, "用户({})服务结束", LoginHelper.getLoginUser(request).getName(),zfdServiceApply.getId()); | addLog(request, LogType.END_OF_SERVICE, "用户({})服务结束", LoginHelper.getLoginUser(request).getName(),zfdServiceApply.getId()); |
<tr> | <tr> | ||||
<td> | <td> | ||||
${fn:escapeXml(vo.id)} | |||||
${fn:escapeXml(voStatus.count)} | |||||
</td> | </td> | ||||
<td> | <td> | ||||
${fn:escapeXml(vo.vehiclePalte) }_${fn:escapeXml(vo.vehiclePlatecolor.value) } | ${fn:escapeXml(vo.vehiclePalte) }_${fn:escapeXml(vo.vehiclePlatecolor.value) } |