Commit 1ec5bfb6490a5ab42f5e5fecffdc2db7c40dc0c0
1 parent
637ebf97
bf
Showing
4 changed files
with
15 additions
and
6 deletions
bsthLineProfiles/src/main/java/com/ruoyi/project/system/line/controller/BsthTLineAddController.java
| @@ -138,6 +138,7 @@ public class BsthTLineAddController extends BaseController | @@ -138,6 +138,7 @@ public class BsthTLineAddController extends BaseController | ||
| 138 | User loginUser = ShiroUtils.getSysUser(); | 138 | User loginUser = ShiroUtils.getSysUser(); |
| 139 | bsthTLine.setUpdateBy(loginUser.getUserName()); | 139 | bsthTLine.setUpdateBy(loginUser.getUserName()); |
| 140 | bsthTLine.setLineUpdateType("3"); | 140 | bsthTLine.setLineUpdateType("3"); |
| 141 | + bsthTLine.setExamineStatus("0"); | ||
| 141 | return toAjax(bsthTLineService.updateBsthTLineExamine(bsthTLine)); | 142 | return toAjax(bsthTLineService.updateBsthTLineExamine(bsthTLine)); |
| 142 | } | 143 | } |
| 143 | 144 |
bsthLineProfiles/src/main/java/com/ruoyi/project/system/line/controller/BsthTLineHistoryController.java
| @@ -115,6 +115,7 @@ public class BsthTLineHistoryController extends BaseController | @@ -115,6 +115,7 @@ public class BsthTLineHistoryController extends BaseController | ||
| 115 | BsthTLine bsthTLineExamine=bsthTLineService.selectBsthTLineExamineByLineName(lineName); | 115 | BsthTLine bsthTLineExamine=bsthTLineService.selectBsthTLineExamineByLineName(lineName); |
| 116 | if(bsthTLineExamine!=null){//有没审核的直接覆盖 | 116 | if(bsthTLineExamine!=null){//有没审核的直接覆盖 |
| 117 | bsthTLine.setId(bsthTLineExamine.getId()); | 117 | bsthTLine.setId(bsthTLineExamine.getId()); |
| 118 | + bsthTLine.setExamineStatus("0"); | ||
| 118 | ajaxResult= toAjax(bsthTLineService.updateBsthTLineExamine(bsthTLine)); | 119 | ajaxResult= toAjax(bsthTLineService.updateBsthTLineExamine(bsthTLine)); |
| 119 | }else {//没有新增 | 120 | }else {//没有新增 |
| 120 | bsthTLine.setExamineType("1"); | 121 | bsthTLine.setExamineType("1"); |
bsthLineProfiles/src/main/java/com/ruoyi/project/system/line/service/impl/BsthTLineServiceImpl.java
| 1 | package com.ruoyi.project.system.line.service.impl; | 1 | package com.ruoyi.project.system.line.service.impl; |
| 2 | 2 | ||
| 3 | import java.time.LocalDateTime; | 3 | import java.time.LocalDateTime; |
| 4 | +import java.time.ZoneId; | ||
| 4 | import java.time.format.DateTimeFormatter; | 5 | import java.time.format.DateTimeFormatter; |
| 5 | -import java.util.ArrayList; | ||
| 6 | -import java.util.Date; | ||
| 7 | -import java.util.HashMap; | ||
| 8 | -import java.util.List; | ||
| 9 | -import java.util.Map; | 6 | +import java.util.*; |
| 10 | import java.util.stream.Collectors; | 7 | import java.util.stream.Collectors; |
| 11 | 8 | ||
| 12 | import com.ruoyi.common.utils.DateUtils; | 9 | import com.ruoyi.common.utils.DateUtils; |
| @@ -260,7 +257,7 @@ public class BsthTLineServiceImpl implements IBsthTLineService | @@ -260,7 +257,7 @@ public class BsthTLineServiceImpl implements IBsthTLineService | ||
| 260 | lineEditReport.setVehiclesNumber(history.getVehiclesNumber()); | 257 | lineEditReport.setVehiclesNumber(history.getVehiclesNumber()); |
| 261 | lineEditReport.setNumberPerson(history.getNumberPerson()); | 258 | lineEditReport.setNumberPerson(history.getNumberPerson()); |
| 262 | if(history.getStartDate()==null){ | 259 | if(history.getStartDate()==null){ |
| 263 | - lineEditReport.setStartDate(new Date()); | 260 | + lineEditReport.setStartDate(initDateByDay()); |
| 264 | }else { | 261 | }else { |
| 265 | lineEditReport.setStartDate(history.getStartDate()); | 262 | lineEditReport.setStartDate(history.getStartDate()); |
| 266 | } | 263 | } |
| @@ -448,4 +445,13 @@ public class BsthTLineServiceImpl implements IBsthTLineService | @@ -448,4 +445,13 @@ public class BsthTLineServiceImpl implements IBsthTLineService | ||
| 448 | return bsthTLineMapper.selectCompany(); | 445 | return bsthTLineMapper.selectCompany(); |
| 449 | } | 446 | } |
| 450 | 447 | ||
| 448 | + public static Date initDateByDay(){ | ||
| 449 | + Calendar calendar = Calendar.getInstance(); | ||
| 450 | + calendar.setTime(new Date()); | ||
| 451 | + calendar.set(Calendar.HOUR_OF_DAY, 0); | ||
| 452 | + calendar.set(Calendar.MINUTE, 0); | ||
| 453 | + calendar.set(Calendar.SECOND, 0); | ||
| 454 | + return calendar.getTime(); | ||
| 455 | + } | ||
| 456 | + | ||
| 451 | } | 457 | } |
bsthLineProfiles/src/main/resources/templates/system/lineAdd/line.html
| @@ -268,6 +268,7 @@ | @@ -268,6 +268,7 @@ | ||
| 268 | } | 268 | } |
| 269 | function queryParams(params) { | 269 | function queryParams(params) { |
| 270 | var search = $.table.queryParams(params); | 270 | var search = $.table.queryParams(params); |
| 271 | + search.examineType='0'; | ||
| 271 | search.company=$('#company').select2('val'); | 272 | search.company=$('#company').select2('val'); |
| 272 | search.fCompany=$('#fCompany').select2('val'); | 273 | search.fCompany=$('#fCompany').select2('val'); |
| 273 | return search; | 274 | return search; |