Commit c18b21e5ed39fcf4d977edc12ce25e397f14e7f2
1 parent
4e50ae8e
临港二期
Showing
15 changed files
with
132 additions
and
33 deletions
Bsth-admin/src/main/java/com/ruoyi/controller/app/AppSignExceptionController.java
| ... | ... | @@ -11,6 +11,7 @@ import com.ruoyi.domain.scheduling.LinggangScheduling; |
| 11 | 11 | import com.ruoyi.domain.sign.in.exception.report.EquipmentExceptionReport; |
| 12 | 12 | import com.ruoyi.in.domain.SignIn; |
| 13 | 13 | import com.ruoyi.in.service.ISignInService; |
| 14 | +import com.ruoyi.service.BigViewServiceV1; | |
| 14 | 15 | import com.ruoyi.service.driver.NewDriverService; |
| 15 | 16 | import com.ruoyi.service.scheduling.LinggangSchedulingService; |
| 16 | 17 | import com.ruoyi.service.sign.in.exception.report.EquipmentExceptionReportService; |
| ... | ... | @@ -51,6 +52,8 @@ public class AppSignExceptionController extends BaseController { |
| 51 | 52 | private ISignInService signInService; |
| 52 | 53 | @Autowired |
| 53 | 54 | private ISysDictDataService dictDataService; |
| 55 | + @Autowired | |
| 56 | + private BigViewServiceV1 bigViewServiceV1; | |
| 54 | 57 | |
| 55 | 58 | @ApiOperation("酒测签到异常") |
| 56 | 59 | @PostMapping("/sign/exception/list") |
| ... | ... | @@ -127,7 +130,11 @@ public class AppSignExceptionController extends BaseController { |
| 127 | 130 | Optional<SignIn> optSign = signIns.stream().filter(s -> Objects.equals(s.getId(), r.getSignId())).findFirst(); |
| 128 | 131 | if (optSign.isPresent()) { |
| 129 | 132 | vo.setSignTime(optSign.get().getCreateTime()); |
| 130 | - vo.setSignStatus(optSign.get().getExType()); | |
| 133 | + if (bigViewServiceV1.isSignStatusWineEnum(optSign.get())) { | |
| 134 | + vo.setSignStatus(3); | |
| 135 | + } else { | |
| 136 | + vo.setSignStatus(optSign.get().getExType()); | |
| 137 | + } | |
| 131 | 138 | vo.setAlcoholIntake(optSign.get().getAlcoholIntake()); |
| 132 | 139 | |
| 133 | 140 | if (schedulingSize > 0) { | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/controller/dss/DssDriverController.java
| ... | ... | @@ -10,6 +10,7 @@ import com.ruoyi.common.core.domain.AjaxResult; |
| 10 | 10 | import com.ruoyi.common.core.domain.ResponseResult; |
| 11 | 11 | import com.ruoyi.common.core.domain.entity.SysDictData; |
| 12 | 12 | import com.ruoyi.common.core.redis.RedisCache; |
| 13 | +import com.ruoyi.domain.DriverScheduling; | |
| 13 | 14 | import com.ruoyi.domain.OrderEntity; |
| 14 | 15 | import com.ruoyi.domain.caiinfo.CarInfo; |
| 15 | 16 | import com.ruoyi.domain.driver.NewDriver; |
| ... | ... | @@ -246,11 +247,13 @@ public class DssDriverController extends BaseController { |
| 246 | 247 | |
| 247 | 248 | CalDriverScheduling calDriverScheduling = signInServiceV1.findSchedulingByDateTime(dto.getStaffCode(), new Date(), 1); |
| 248 | 249 | if(Objects.isNull(calDriverScheduling) || Objects.isNull(calDriverScheduling.getDriverScheduling()) || Objects.isNull(calDriverScheduling.getDriverScheduling().getSignInId())){ |
| 249 | - return ResponseResult.success(convertGetWineRecordVo(null)); | |
| 250 | + return ResponseResult.success(convertGetWineRecordVo(null,null,null)); | |
| 250 | 251 | } |
| 251 | 252 | |
| 253 | + | |
| 254 | + Integer count = signInService.count(calDriverScheduling.getDriverScheduling().getId()); | |
| 252 | 255 | SignIn dataSignIn = signInService.getById(calDriverScheduling.getDriverScheduling().getSignInId()); |
| 253 | - return ResponseResult.success(convertGetWineRecordVo(dataSignIn)); | |
| 256 | + return ResponseResult.success(convertGetWineRecordVo(dataSignIn,calDriverScheduling.getDriverScheduling(),count)); | |
| 254 | 257 | } |
| 255 | 258 | |
| 256 | 259 | @PostMapping(value = "/Info/GetBusPlanList") |
| ... | ... | @@ -627,19 +630,32 @@ public class DssDriverController extends BaseController { |
| 627 | 630 | return new SignOutVo(dto.getDevice(), dto.getDriverCode(), dto.getLogoutTime(), vo.getId()); |
| 628 | 631 | } |
| 629 | 632 | |
| 630 | - private GetWineRecordVo convertGetWineRecordVo(SignIn signIn) { | |
| 633 | + private GetWineRecordVo convertGetWineRecordVo(SignIn signIn, DriverScheduling scheduling,Integer count) { | |
| 631 | 634 | GetWineRecordVo vo = new GetWineRecordVo(); |
| 632 | 635 | if (Objects.isNull(signIn)) { |
| 633 | 636 | vo.setCheck(true); |
| 634 | 637 | return vo; |
| 635 | 638 | } |
| 636 | 639 | vo.setCheckTime(signIn.getCreateTime()); |
| 640 | + if(bigViewServiceV1.isSignStatusWineEnum(signIn)){ | |
| 641 | + vo.setCheck(Boolean.TRUE); | |
| 642 | + return vo; | |
| 643 | + } | |
| 637 | 644 | |
| 638 | - String key = REDIS_SIGN_IN_DRIVER_ALCOHOL_OVERFLOW + ConstDateUtil.formatDate("yyyyMMdd") + ":" + signIn.getJobCode()+":"+signIn.getSchedulingId(); | |
| 639 | - | |
| 640 | - Integer count = redisCache.getCacheObject(key); | |
| 641 | - if (Objects.nonNull(count) && SIGN_IN_ERROR_COUNT.compareTo(count) <= 0) { | |
| 642 | - vo.setCheck(Objects.equals(signIn.getType(), 0)); | |
| 645 | + Integer total = Objects.isNull(scheduling)||Objects.isNull(scheduling.getAlcoholCount())?SIGN_IN_ERROR_COUNT:scheduling.getAlcoholCount(); | |
| 646 | + if (Objects.isNull(count) || total.compareTo(count) >= 0) { | |
| 647 | + if(bigViewServiceV1.isSignStatusDelayEnum(signIn)){ | |
| 648 | + vo.setCheck(Boolean.FALSE); | |
| 649 | + return vo; | |
| 650 | + } | |
| 651 | + vo.setCheck(!Objects.equals(signIn.getType(), 0)); | |
| 652 | + return vo; | |
| 653 | + }else if(count > total){ | |
| 654 | + if(bigViewServiceV1.isSignStatusDelayEnum(signIn)){ | |
| 655 | + vo.setCheck(Boolean.FALSE); | |
| 656 | + return vo; | |
| 657 | + } | |
| 658 | + vo.setCheck(!Objects.equals(signIn.getType(), 0)); | |
| 643 | 659 | return vo; |
| 644 | 660 | } |
| 645 | 661 | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/controller/dss/KeyBoxController.java
| ... | ... | @@ -278,9 +278,34 @@ public class KeyBoxController extends BaseController { |
| 278 | 278 | List<LinggangKeyWorkLocation> schedulings = linggangKeyWorkLocationService.list(entity); |
| 279 | 279 | |
| 280 | 280 | List<KeyInfo> keyInfos = null; |
| 281 | - if (CollectionUtils.isNotEmpty(dto.getKeyItem())) { | |
| 282 | - Set<String> codes = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getKeyCode).filter(obj -> Objects.nonNull(obj)).collect(Collectors.toSet()); | |
| 283 | - keyInfos = keyInfoService.list(codes); | |
| 281 | +// if (CollectionUtils.isNotEmpty(dto.getKeyItem())) { | |
| 282 | +// Set<String> codes = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getKeyCode).filter(obj -> Objects.nonNull(obj)).collect(Collectors.toSet()); | |
| 283 | +// keyInfos = keyInfoService.list(codes); | |
| 284 | +// } | |
| 285 | + | |
| 286 | + Set<String> nbbms = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getPlate).filter(obj -> StringUtils.isNotEmpty(obj)).collect(Collectors.toSet()); | |
| 287 | + if (CollectionUtils.isNotEmpty(nbbms)) { | |
| 288 | + List<CarInfo> carInfos = carInfoService.list(nbbms); | |
| 289 | + if (CollectionUtils.isNotEmpty(nbbms)) { | |
| 290 | + Set<String> plateNums = carInfos.stream().map(CarInfo::getPlateNum).filter(obj -> StringUtils.isNotEmpty(obj)).collect(Collectors.toSet()); | |
| 291 | + if (CollectionUtils.isNotEmpty(plateNums)) { | |
| 292 | + keyInfos = keyInfoService.listPlateNums(plateNums); | |
| 293 | + if(CollectionUtils.isNotEmpty(keyInfos)){ | |
| 294 | + keyInfos = keyInfos.stream().map(k->{ | |
| 295 | + Optional<CarInfo> optCar = carInfos.stream().filter(c->Objects.equals(k.getPlateNum(),c.getPlateNum())).findFirst(); | |
| 296 | + optCar.ifPresent(c->k.setNmmb(c.getNbbm())); | |
| 297 | + | |
| 298 | + return k; | |
| 299 | + }).collect(Collectors.toList()); | |
| 300 | + } | |
| 301 | + } | |
| 302 | + } | |
| 303 | + } | |
| 304 | + | |
| 305 | + Equipment equipment = equipmentService.getOneByDeviceId(dto.getDevice()); | |
| 306 | + LinggangVenueInfo venueInfo = null; | |
| 307 | + if(Objects.nonNull(equipment)){ | |
| 308 | + venueInfo = venueInfoService.getById(equipment.getYardId()); | |
| 284 | 309 | } |
| 285 | 310 | |
| 286 | 311 | NewDriver driver = newDriverService.getOne(dto.getStaffCode()); |
| ... | ... | @@ -289,12 +314,11 @@ public class KeyBoxController extends BaseController { |
| 289 | 314 | // return ResponseResult.error404(); |
| 290 | 315 | // } |
| 291 | 316 | |
| 292 | - List<LinggangKeyWorkLocation> locations = convert(dto, schedulings, driver, keyInfos, 0); | |
| 293 | - ResponseResult<Boolean> responseResult = linggangKeyWorkLocationService.updateTakeKey(locations, LinggangKeyWorkLocation.LinggangKeyWorkLocationTypeEnum.TAKE_OUT); | |
| 317 | + List<LinggangKeyWorkLocation> locations = convert(dto, schedulings, driver, keyInfos, 1,venueInfo); | |
| 318 | + ResponseResult<Boolean> responseResult = linggangKeyWorkLocationService.saveAndDel(locations); | |
| 294 | 319 | if (Objects.isNull(responseResult)) { |
| 295 | 320 | return ResponseResult.error(); |
| 296 | 321 | } |
| 297 | - Equipment equipment = equipmentService.getOneByDeviceId(dto.getDevice()); | |
| 298 | 322 | |
| 299 | 323 | TakeKeyVo vo = convertTakeKeyVo(dto, responseResult, equipment); |
| 300 | 324 | |
| ... | ... | @@ -328,21 +352,36 @@ public class KeyBoxController extends BaseController { |
| 328 | 352 | } |
| 329 | 353 | |
| 330 | 354 | List<KeyInfo> keyInfos = null; |
| 331 | - if (CollectionUtils.isNotEmpty(dto.getKeyItem())) { | |
| 332 | - Set<String> codes = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getKeyCode).filter(obj -> Objects.nonNull(obj)).collect(Collectors.toSet()); | |
| 333 | - keyInfos = keyInfoService.list(codes); | |
| 334 | 355 | |
| 335 | - if (CollectionUtils.isEmpty(keyInfos)) { | |
| 336 | - codes = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getPlate).filter(obj -> Objects.nonNull(obj)).collect(Collectors.toSet()); | |
| 337 | - keyInfos = keyInfoService.list(null, codes); | |
| 356 | + | |
| 357 | + Set<String> nbbms = dto.getKeyItem().stream().map(TakeKeyKeyItemDTO::getPlate).filter(obj -> StringUtils.isNotEmpty(obj)).collect(Collectors.toSet()); | |
| 358 | + if (CollectionUtils.isNotEmpty(nbbms)) { | |
| 359 | + List<CarInfo> carInfos = carInfoService.list(nbbms); | |
| 360 | + if (CollectionUtils.isNotEmpty(nbbms)) { | |
| 361 | + Set<String> plateNums = carInfos.stream().map(CarInfo::getPlateNum).filter(obj -> StringUtils.isNotEmpty(obj)).collect(Collectors.toSet()); | |
| 362 | + if (CollectionUtils.isNotEmpty(plateNums)) { | |
| 363 | + keyInfos = keyInfoService.listPlateNums(plateNums); | |
| 364 | + if(CollectionUtils.isNotEmpty(keyInfos)){ | |
| 365 | + keyInfos = keyInfos.stream().map(k->{ | |
| 366 | + Optional<CarInfo> optCar = carInfos.stream().filter(c->Objects.equals(k.getPlateNum(),c.getPlateNum())).findFirst(); | |
| 367 | + optCar.ifPresent(c->k.setNmmb(c.getNbbm())); | |
| 368 | + | |
| 369 | + return k; | |
| 370 | + }).collect(Collectors.toList()); | |
| 371 | + } | |
| 372 | + } | |
| 338 | 373 | } |
| 339 | 374 | } |
| 340 | 375 | |
| 341 | - | |
| 342 | - List<LinggangKeyWorkLocation> locations = convert(dto, schedulings, driver, keyInfos, 1); | |
| 376 | + Equipment equipment = equipmentService.getOneByDeviceId(dto.getDevice()); | |
| 377 | + LinggangVenueInfo venueInfo = null; | |
| 378 | + if(Objects.nonNull(equipment)){ | |
| 379 | + venueInfo = venueInfoService.getById(equipment.getYardId()); | |
| 380 | + } | |
| 381 | + List<LinggangKeyWorkLocation> locations = convert(dto, schedulings, driver, keyInfos, 0,venueInfo); | |
| 343 | 382 | // List<LinggangKeyWorkLocation> errorLocations = locations.stream().filter(l -> Objects.isNull(l.getKeyInfoId())).collect(Collectors.toList()); |
| 344 | 383 | // locations = locations.stream().filter(l -> Objects.nonNull(l.getKeyInfoId())).collect(Collectors.toList()); |
| 345 | - ResponseResult<Boolean> responseResult = linggangKeyWorkLocationService.updateTakeKey(locations, LinggangKeyWorkLocation.LinggangKeyWorkLocationTypeEnum.REPAY); | |
| 384 | + ResponseResult<Boolean> responseResult = linggangKeyWorkLocationService.saveAndDel(locations); | |
| 346 | 385 | if (Objects.isNull(responseResult)) { |
| 347 | 386 | return ResponseResult.error(); |
| 348 | 387 | } |
| ... | ... | @@ -357,8 +396,6 @@ public class KeyBoxController extends BaseController { |
| 357 | 396 | // return ResponseResult.error(responseResult.getCode(), JSON.toJSONString(errorCode) + "归还失败,请归还到指定位置"); |
| 358 | 397 | // } |
| 359 | 398 | |
| 360 | - | |
| 361 | - Equipment equipment = equipmentService.getOneByDeviceId(dto.getDevice()); | |
| 362 | 399 | TakeKeyVo vo = convertTakeKeyVo(dto, responseResult, equipment); |
| 363 | 400 | |
| 364 | 401 | return new ResponseResult<>(responseResult.getCode(), responseResult.getMsg(), vo); |
| ... | ... | @@ -751,7 +788,7 @@ public class KeyBoxController extends BaseController { |
| 751 | 788 | return vo; |
| 752 | 789 | } |
| 753 | 790 | |
| 754 | - private List<LinggangKeyWorkLocation> convert(TakeKeyDTO dto, List<LinggangKeyWorkLocation> schedulings, NewDriver driver, List<KeyInfo> keyInfos, int ty) { | |
| 791 | + private List<LinggangKeyWorkLocation> convert(TakeKeyDTO dto, List<LinggangKeyWorkLocation> schedulings, NewDriver driver, List<KeyInfo> keyInfos, int ty,LinggangVenueInfo venueInfo) { | |
| 755 | 792 | if (CollectionUtils.isEmpty(dto.getKeyItem())) { |
| 756 | 793 | return Collections.emptyList(); |
| 757 | 794 | } |
| ... | ... | @@ -766,6 +803,7 @@ public class KeyBoxController extends BaseController { |
| 766 | 803 | location.setPlate(item.getPlate()); |
| 767 | 804 | location.setTime(dto.getTime()); |
| 768 | 805 | location.setType1(ty); |
| 806 | + location.setCabinetNo(item.getParkCode()); | |
| 769 | 807 | location.setJobCode(dto.getStaffCode()); |
| 770 | 808 | if (CollectionUtils.isNotEmpty(schedulings)) { |
| 771 | 809 | Optional<LinggangKeyWorkLocation> opt = schedulings.stream().filter(s -> Objects.equals(item.getKey(), s.getCabinetNo())).findFirst(); |
| ... | ... | @@ -778,7 +816,7 @@ public class KeyBoxController extends BaseController { |
| 778 | 816 | if (optional.isPresent()) { |
| 779 | 817 | location.setKeyInfoId(optional.get().getId()); |
| 780 | 818 | } else { |
| 781 | - optional = keyInfos.stream().filter(k -> Objects.equals(k.getPlateNum(), item.getPlate())).findFirst(); | |
| 819 | + optional = keyInfos.stream().filter(k -> Objects.equals(k.getNmmb(), item.getPlate())).findFirst(); | |
| 782 | 820 | if (optional.isPresent()) { |
| 783 | 821 | location.setKeyInfoId(optional.get().getId()); |
| 784 | 822 | } |
| ... | ... | @@ -788,6 +826,11 @@ public class KeyBoxController extends BaseController { |
| 788 | 826 | if (Objects.nonNull(driver)) { |
| 789 | 827 | location.setCreateBy(Convert.toLong(driver.getId())); |
| 790 | 828 | } |
| 829 | + | |
| 830 | + if(Objects.nonNull(venueInfo)){ | |
| 831 | + location.setYardId(venueInfo.getId()); | |
| 832 | + location.setYardName(venueInfo.getName()); | |
| 833 | + } | |
| 791 | 834 | location.setCreateTime(new Date()); |
| 792 | 835 | |
| 793 | 836 | return location; | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/domain/dss/key/box/dto/TakeKeyDTO.java
| ... | ... | @@ -52,7 +52,7 @@ public class TakeKeyDTO implements java.io.Serializable { |
| 52 | 52 | |
| 53 | 53 | // @NotEmpty(message = "选择的钥匙位车牌 不能为空") |
| 54 | 54 | // @ApiModelProperty(value = "选择的钥匙位车牌", required = true) |
| 55 | -// private String plate; | |
| 55 | + private String plate; | |
| 56 | 56 | @ApiModelProperty(value = "领取钥匙信息集合") |
| 57 | 57 | private List<TakeKeyKeyItemDTO> keyItem; |
| 58 | 58 | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/domain/key/info/KeyInfo.java
Bsth-admin/src/main/java/com/ruoyi/in/domain/SignInV1.java
Bsth-admin/src/main/java/com/ruoyi/in/service/ISignInService.java
Bsth-admin/src/main/java/com/ruoyi/in/service/impl/SignInServiceImpl.java
| ... | ... | @@ -413,6 +413,14 @@ public class SignInServiceImpl extends ServiceImpl<SignInMapper, SignIn> impleme |
| 413 | 413 | return 0; |
| 414 | 414 | } |
| 415 | 415 | |
| 416 | + @Override | |
| 417 | + public int count(Long scheduleId) { | |
| 418 | + LambdaQueryWrapper<SignIn> countWrapper = new LambdaQueryWrapper<>(); | |
| 419 | + countWrapper.select(SignIn::getId); | |
| 420 | + countWrapper.eq(SignIn::getSchedulingId,scheduleId); | |
| 421 | + return count(countWrapper); | |
| 422 | + } | |
| 423 | + | |
| 416 | 424 | |
| 417 | 425 | private String handleDate(String dateString) { |
| 418 | 426 | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyMMdd"); | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/in/service/impl/SignInServiceV1Impl.java
| ... | ... | @@ -2,6 +2,7 @@ package com.ruoyi.in.service.impl; |
| 2 | 2 | |
| 3 | 3 | import cn.hutool.core.convert.Convert; |
| 4 | 4 | import com.alibaba.fastjson2.JSON; |
| 5 | +import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; | |
| 5 | 6 | import com.baomidou.mybatisplus.extension.conditions.update.LambdaUpdateChainWrapper; |
| 6 | 7 | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| 7 | 8 | import com.ruoyi.common.ConstDriverProperties; |
| ... | ... | @@ -295,7 +296,7 @@ public class SignInServiceV1Impl extends ServiceImpl<SignInMapperV1, SignInV1> i |
| 295 | 296 | signInResource.setCreateBy(Convert.toLong(signIn.getCreateBy())); |
| 296 | 297 | signInResourceService.save(signInResource); |
| 297 | 298 | } |
| 298 | - signInV1.setId(signInV1.getId()); | |
| 299 | + signInV1.setId(signIn.getId()); | |
| 299 | 300 | // 更新考勤 |
| 300 | 301 | if (Objects.nonNull(calDriverScheduling)) { |
| 301 | 302 | schedulingService.computedSignInBySignIn(scheduling, calDriverScheduling.getIndex(), signIn, true, signInService); |
| ... | ... | @@ -305,6 +306,10 @@ public class SignInServiceV1Impl extends ServiceImpl<SignInMapperV1, SignInV1> i |
| 305 | 306 | TempCache.updateSignStatus(signIn.getJobCode()); |
| 306 | 307 | } |
| 307 | 308 | |
| 309 | + LambdaUpdateWrapper<SignInV1> updateWrapper = new LambdaUpdateWrapper<>(); | |
| 310 | + updateWrapper.set(SignInV1::getSchedulingId, scheduling.getId()); | |
| 311 | + updateWrapper.eq(SignInV1::getId, signIn.getId()); | |
| 312 | + update(updateWrapper); | |
| 308 | 313 | // 异常保存到异常异常中 |
| 309 | 314 | threadJobService.asyncInsertExceptionRecord(signIn, driver, scheduling); |
| 310 | 315 | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/scheduling/service/impl/SchedulingServiceV1Impl.java
| ... | ... | @@ -24,7 +24,8 @@ public class SchedulingServiceV1Impl extends ServiceImpl<SchedulingMapperV1, Dri |
| 24 | 24 | SchedulingDateEntity entity = switchSchedulingDate(date); |
| 25 | 25 | wrapper.eq(DriverSchedulingV1::getJobCode, jobCode); |
| 26 | 26 | wrapper.and(wr -> { |
| 27 | - wr.eq(DriverSchedulingV1::getScheduleDate, date).or().between(DriverSchedulingV1::getFcsjT, entity.getStartDate().getTime(), entity.getEndDate().getTime()); | |
| 27 | + String dateStr = DateUtils.YYYY_MM_DD.format(date); | |
| 28 | + wr.likeRight(DriverSchedulingV1::getScheduleDate, dateStr).or().between(DriverSchedulingV1::getFcsjT, entity.getStartDate().getTime(), entity.getEndDate().getTime()); | |
| 28 | 29 | }); |
| 29 | 30 | wrapper.orderByAsc(DriverSchedulingV1::getFcsjT); |
| 30 | 31 | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/service/impl/BigViewServiceV1Impl.java
| ... | ... | @@ -107,8 +107,10 @@ public class BigViewServiceV1Impl implements BigViewServiceV1 { |
| 107 | 107 | if (Objects.isNull(count) || count.equals(0)) { |
| 108 | 108 | count = 1; |
| 109 | 109 | redisCache.setCacheObject(key, count, 1, TimeUnit.DAYS); |
| 110 | + redisCache.setCacheObject(key1, count, 1, TimeUnit.DAYS); | |
| 110 | 111 | } else { |
| 111 | 112 | redisCache.setCacheObject(key, ++count, 1, TimeUnit.DAYS); |
| 113 | + redisCache.setCacheObject(key1, count, 1, TimeUnit.DAYS); | |
| 112 | 114 | } |
| 113 | 115 | if (driverScheduling.getAlcoholCount() - count <= 0) { |
| 114 | 116 | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/service/impl/key/location/LinggangKeyWorkLocationServiceImpl.java
| ... | ... | @@ -440,6 +440,12 @@ public class LinggangKeyWorkLocationServiceImpl extends ServiceImpl<LinggangKeyW |
| 440 | 440 | return ResponseResult.error(resultStr.toString()); |
| 441 | 441 | } |
| 442 | 442 | |
| 443 | + @Override | |
| 444 | + public ResponseResult<Boolean> saveAndDel(List<LinggangKeyWorkLocation> locations) { | |
| 445 | + boolean flag = saveBatch(locations); | |
| 446 | + return ResponseResult.success(flag); | |
| 447 | + } | |
| 448 | + | |
| 443 | 449 | public boolean update(LinggangKeyWorkLocation location) { |
| 444 | 450 | LambdaUpdateWrapper<LinggangKeyWorkLocation> wrapper = new LambdaUpdateWrapper<>(); |
| 445 | 451 | wrapper.set(LinggangKeyWorkLocation::getEventType, location.getEventType()).set(LinggangKeyWorkLocation::getUpdateTime, new Date()) | ... | ... |
Bsth-admin/src/main/java/com/ruoyi/service/key/location/LinggangKeyWorkLocationService.java
| ... | ... | @@ -77,6 +77,8 @@ public interface LinggangKeyWorkLocationService extends IService<LinggangKeyWork |
| 77 | 77 | */ |
| 78 | 78 | ResponseResult<Boolean> updateTakeKey(List<LinggangKeyWorkLocation> locations, LinggangKeyWorkLocation.LinggangKeyWorkLocationTypeEnum typeEnum); |
| 79 | 79 | |
| 80 | + ResponseResult<Boolean> saveAndDel(List<LinggangKeyWorkLocation> locations); | |
| 81 | + | |
| 80 | 82 | boolean deleteById(Long id); |
| 81 | 83 | |
| 82 | 84 | boolean removeBySchedulingId(Set<Long> schedulingId ); | ... | ... |
Bsth-admin/src/main/resources/application-druid-dev.yml
Bsth-admin/src/main/resources/mapper/in/SignInMapper.xml
| ... | ... | @@ -172,6 +172,7 @@ |
| 172 | 172 | <if test="remark != null">remark,</if> |
| 173 | 173 | <if test="exType != null">ex_type,</if> |
| 174 | 174 | <if test="null!=schedulingId">scheduling_id,</if> |
| 175 | + <if test="null!=exType1">ex_type1,</if> | |
| 175 | 176 | </trim> |
| 176 | 177 | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| 177 | 178 | <if test="createTime != null">#{createTime},</if> |
| ... | ... | @@ -189,6 +190,7 @@ |
| 189 | 190 | <if test="remark != null">#{remark},</if> |
| 190 | 191 | <if test="exType != null">#{exType},</if> |
| 191 | 192 | <if test="null!=schedulingId">#{schedulingId,jdbcType=INTEGER},</if> |
| 193 | + <if test="null!=exType1">#{exType1,jdbcType=INTEGER},</if> | |
| 192 | 194 | </trim> |
| 193 | 195 | </insert> |
| 194 | 196 | ... | ... |