Commit aba59a0df6d9abac2275dc8820ecf3632f37eacd
1 parent
02e1576d
设备和场地
Showing
6 changed files
with
40 additions
and
7 deletions
Bsth-admin/src/main/java/com/ruoyi/controller/dss/DssDriverController.java
| @@ -355,7 +355,7 @@ public class DssDriverController extends BaseController { | @@ -355,7 +355,7 @@ public class DssDriverController extends BaseController { | ||
| 355 | SignIn signIn = new SignIn(); | 355 | SignIn signIn = new SignIn(); |
| 356 | Boolean flag = Boolean.TRUE; | 356 | Boolean flag = Boolean.TRUE; |
| 357 | if (Objects.nonNull(dto.getCheckTime())) { | 357 | if (Objects.nonNull(dto.getCheckTime())) { |
| 358 | - signIn.setCreateTime(dto.getCheckTime()); | 358 | + signIn.setStartCreateTime(dto.getCheckTime()); |
| 359 | flag = false; | 359 | flag = false; |
| 360 | } | 360 | } |
| 361 | 361 | ||
| @@ -527,6 +527,10 @@ public class DssDriverController extends BaseController { | @@ -527,6 +527,10 @@ public class DssDriverController extends BaseController { | ||
| 527 | GetBusPlanListVo vo = new GetBusPlanListVo(); | 527 | GetBusPlanListVo vo = new GetBusPlanListVo(); |
| 528 | vo.setDriverName(scheduling.getName()); | 528 | vo.setDriverName(scheduling.getName()); |
| 529 | vo.setSelfCode(scheduling.getNbbm()); | 529 | vo.setSelfCode(scheduling.getNbbm()); |
| 530 | + vo.setStartStation(scheduling.getQdzname()); | ||
| 531 | + | ||
| 532 | + String upDown = Objects.equals(0,scheduling.getUpdown())?"1":Objects.equals(1,scheduling.getUpdown())?"2":null; | ||
| 533 | + vo.setUpDown(upDown); | ||
| 530 | if (CollectionUtils.isNotEmpty(carInfos)) { | 534 | if (CollectionUtils.isNotEmpty(carInfos)) { |
| 531 | Optional<CarInfo> optional = carInfos.stream().filter(c -> Objects.equals(c.getNbbm(), scheduling.getNbbm())).findFirst(); | 535 | Optional<CarInfo> optional = carInfos.stream().filter(c -> Objects.equals(c.getNbbm(), scheduling.getNbbm())).findFirst(); |
| 532 | if (optional.isPresent()) { | 536 | if (optional.isPresent()) { |
| @@ -555,6 +559,7 @@ public class DssDriverController extends BaseController { | @@ -555,6 +559,7 @@ public class DssDriverController extends BaseController { | ||
| 555 | Optional<LinggangScheduling> optional = schedulings.stream().filter(sc -> Objects.equals(sc.getId(), s.getSchedulingId())).findFirst(); | 559 | Optional<LinggangScheduling> optional = schedulings.stream().filter(sc -> Objects.equals(sc.getId(), s.getSchedulingId())).findFirst(); |
| 556 | if (optional.isPresent()) { | 560 | if (optional.isPresent()) { |
| 557 | vo.setRouteName(optional.get().getLineName()); | 561 | vo.setRouteName(optional.get().getLineName()); |
| 562 | + vo.setYarnName(optional.get().getQdzname()); | ||
| 558 | } | 563 | } |
| 559 | } | 564 | } |
| 560 | 565 | ||
| @@ -576,6 +581,17 @@ public class DssDriverController extends BaseController { | @@ -576,6 +581,17 @@ public class DssDriverController extends BaseController { | ||
| 576 | vo.setCheckResult(Convert.toStr(s.getStatus())); | 581 | vo.setCheckResult(Convert.toStr(s.getStatus())); |
| 577 | vo.setDrunkNum(Convert.toStr(s.getAlcoholIntake())); | 582 | vo.setDrunkNum(Convert.toStr(s.getAlcoholIntake())); |
| 578 | 583 | ||
| 584 | + switch (s.getExType()){ | ||
| 585 | + case 44: | ||
| 586 | + vo.setDrunkStatus("11"); | ||
| 587 | + break; | ||
| 588 | + case 3: | ||
| 589 | + vo.setDrunkStatus("12"); | ||
| 590 | + break; | ||
| 591 | + default: | ||
| 592 | + vo.setDrunkStatus("0"); | ||
| 593 | + } | ||
| 594 | + | ||
| 579 | return vo; | 595 | return vo; |
| 580 | }).collect(Collectors.toList()); | 596 | }).collect(Collectors.toList()); |
| 581 | } | 597 | } |
Bsth-admin/src/main/java/com/ruoyi/domain/dss/driver/dto/GetBusPlanListDTO.java
| @@ -8,6 +8,7 @@ import lombok.EqualsAndHashCode; | @@ -8,6 +8,7 @@ import lombok.EqualsAndHashCode; | ||
| 8 | import lombok.experimental.Accessors; | 8 | import lombok.experimental.Accessors; |
| 9 | 9 | ||
| 10 | import javax.validation.constraints.NotEmpty; | 10 | import javax.validation.constraints.NotEmpty; |
| 11 | +import javax.validation.constraints.NotNull; | ||
| 11 | 12 | ||
| 12 | /** | 13 | /** |
| 13 | * @author liujun | 14 | * @author liujun |
| @@ -27,17 +28,17 @@ public class GetBusPlanListDTO implements java.io.Serializable{ | @@ -27,17 +28,17 @@ public class GetBusPlanListDTO implements java.io.Serializable{ | ||
| 27 | 28 | ||
| 28 | @NotEmpty(message = "卡号不能为空") | 29 | @NotEmpty(message = "卡号不能为空") |
| 29 | @ApiModelProperty(value = "卡号",required = true) | 30 | @ApiModelProperty(value = "卡号",required = true) |
| 30 | - private Integer driverCode; | 31 | + private String driverCode; |
| 31 | 32 | ||
| 32 | - @NotEmpty(message = "数据类型为空") | 33 | + @NotNull(message = "数据类型为空") |
| 33 | @ApiModelProperty(value = "数据类型;0今天,1明天,2/null全部",required = true,example = "1") | 34 | @ApiModelProperty(value = "数据类型;0今天,1明天,2/null全部",required = true,example = "1") |
| 34 | private Integer dateType; | 35 | private Integer dateType; |
| 35 | 36 | ||
| 36 | - @NotEmpty(message = "第几页为空") | 37 | + @NotNull(message = "第几页为空") |
| 37 | @ApiModelProperty(value = "第几页",required = true,example = "1") | 38 | @ApiModelProperty(value = "第几页",required = true,example = "1") |
| 38 | private Integer pageNumber; | 39 | private Integer pageNumber; |
| 39 | 40 | ||
| 40 | - @NotEmpty(message = "每页条数为空") | 41 | + @NotNull(message = "每页条数为空") |
| 41 | @ApiModelProperty(value = "每页条数",required = true,example = "1") | 42 | @ApiModelProperty(value = "每页条数",required = true,example = "1") |
| 42 | private Integer pageRow; | 43 | private Integer pageRow; |
| 43 | 44 |
Bsth-admin/src/main/java/com/ruoyi/in/domain/SignIn.java
| @@ -10,6 +10,7 @@ import lombok.Data; | @@ -10,6 +10,7 @@ import lombok.Data; | ||
| 10 | import javax.validation.constraints.NotBlank; | 10 | import javax.validation.constraints.NotBlank; |
| 11 | import javax.validation.constraints.NotNull; | 11 | import javax.validation.constraints.NotNull; |
| 12 | import java.math.BigDecimal; | 12 | import java.math.BigDecimal; |
| 13 | +import java.util.Date; | ||
| 13 | 14 | ||
| 14 | /** | 15 | /** |
| 15 | * 签到对象 sign_in | 16 | * 签到对象 sign_in |
| @@ -94,7 +95,6 @@ public class SignIn extends BaseEntity { | @@ -94,7 +95,6 @@ public class SignIn extends BaseEntity { | ||
| 94 | @ApiModelProperty("酒精摄入量 52.12") | 95 | @ApiModelProperty("酒精摄入量 52.12") |
| 95 | private BigDecimal alcoholIntake; | 96 | private BigDecimal alcoholIntake; |
| 96 | @Excel(name = "异常类型",readConverterExp = "0=无异常,1=超时异常,2=无排班异常,3=酒精超标异常,44饮酒") | 97 | @Excel(name = "异常类型",readConverterExp = "0=无异常,1=超时异常,2=无排班异常,3=酒精超标异常,44饮酒") |
| 97 | - | ||
| 98 | @ApiModelProperty("异常类型") | 98 | @ApiModelProperty("异常类型") |
| 99 | private Integer exType; | 99 | private Integer exType; |
| 100 | 100 | ||
| @@ -105,5 +105,11 @@ public class SignIn extends BaseEntity { | @@ -105,5 +105,11 @@ public class SignIn extends BaseEntity { | ||
| 105 | /***资源类型:1图片;2视频*/ | 105 | /***资源类型:1图片;2视频*/ |
| 106 | @Excel(name = "资源类型:1图片;2视频") | 106 | @Excel(name = "资源类型:1图片;2视频") |
| 107 | private java.lang.Integer resourceType; | 107 | private java.lang.Integer resourceType; |
| 108 | + | ||
| 109 | + @TableField(exist = false) | ||
| 110 | + private Date startCreateTime; | ||
| 111 | + | ||
| 112 | + @TableField(exist = false) | ||
| 113 | + private Date endCreateTime; | ||
| 108 | } | 114 | } |
| 109 | 115 |
Bsth-admin/src/main/java/com/ruoyi/in/service/impl/SignInServiceImpl.java
| @@ -117,6 +117,14 @@ public class SignInServiceImpl extends ServiceImpl<SignInMapper, SignIn> impleme | @@ -117,6 +117,14 @@ public class SignInServiceImpl extends ServiceImpl<SignInMapper, SignIn> impleme | ||
| 117 | if (CollectionUtils.isNotEmpty(jobCodes)) { | 117 | if (CollectionUtils.isNotEmpty(jobCodes)) { |
| 118 | wrapper.in(SignIn::getJobCode, jobCodes); | 118 | wrapper.in(SignIn::getJobCode, jobCodes); |
| 119 | } | 119 | } |
| 120 | + | ||
| 121 | + if(Objects.nonNull(signIn.getStartCreateTime()) && Objects.nonNull(signIn.getEndCreateTime())){ | ||
| 122 | + wrapper.between(SignIn::getCreateTime,signIn.getStartCreateTime(),signIn.getEndCreateTime()); | ||
| 123 | + }else if(Objects.nonNull(signIn.getStartCreateTime())){ | ||
| 124 | + wrapper.ge(SignIn::getCreateTime,signIn.getStartCreateTime()); | ||
| 125 | + }else if(Objects.nonNull(signIn.getEndCreateTime())){ | ||
| 126 | + wrapper.le(SignIn::getCreateTime,signIn.getEndCreateTime()); | ||
| 127 | + } | ||
| 120 | return list(wrapper); | 128 | return list(wrapper); |
| 121 | } | 129 | } |
| 122 | 130 |
Bsth-admin/src/main/java/com/ruoyi/service/ThreadJobService.java
| @@ -2,6 +2,7 @@ package com.ruoyi.service; | @@ -2,6 +2,7 @@ package com.ruoyi.service; | ||
| 2 | 2 | ||
| 3 | 3 | ||
| 4 | import cn.hutool.core.collection.CollectionUtil; | 4 | import cn.hutool.core.collection.CollectionUtil; |
| 5 | +import cn.hutool.core.convert.Convert; | ||
| 5 | import cn.hutool.http.HttpUtil; | 6 | import cn.hutool.http.HttpUtil; |
| 6 | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; | 7 | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| 7 | import com.ruoyi.common.cache.NowSchedulingCache; | 8 | import com.ruoyi.common.cache.NowSchedulingCache; |
| @@ -523,6 +524,7 @@ public class ThreadJobService { | @@ -523,6 +524,7 @@ public class ThreadJobService { | ||
| 523 | .map(item -> { | 524 | .map(item -> { |
| 524 | DriverScheduling scheduling = new DriverScheduling(); | 525 | DriverScheduling scheduling = new DriverScheduling(); |
| 525 | BeanUtils.copyProperties(item, scheduling, "id"); | 526 | BeanUtils.copyProperties(item, scheduling, "id"); |
| 527 | + scheduling.setUpDown(Convert.toInt(item.getUpDown())); | ||
| 526 | return scheduling; | 528 | return scheduling; |
| 527 | }) | 529 | }) |
| 528 | .sorted(Comparator.comparing(DriverScheduling::getFcsjT)) | 530 | .sorted(Comparator.comparing(DriverScheduling::getFcsjT)) |
Bsth-admin/src/main/java/com/ruoyi/service/impl/key/location/LinggangKeyWorkLocationServiceImpl.java
| @@ -411,7 +411,7 @@ public class LinggangKeyWorkLocationServiceImpl extends ServiceImpl<LinggangKeyW | @@ -411,7 +411,7 @@ public class LinggangKeyWorkLocationServiceImpl extends ServiceImpl<LinggangKeyW | ||
| 411 | Objects.equals(d.getDevice(), l.getDevice()) && DateUtils.isSameDay(d.getScheduleDate(), l.getScheduleDate())).findFirst(); | 411 | Objects.equals(d.getDevice(), l.getDevice()) && DateUtils.isSameDay(d.getScheduleDate(), l.getScheduleDate())).findFirst(); |
| 412 | if (optional.isPresent()) { | 412 | if (optional.isPresent()) { |
| 413 | l.setId(optional.get().getId()); | 413 | l.setId(optional.get().getId()); |
| 414 | - if (Objects.equals(l.getEventType(), optional.get().getEventType())) { | 414 | + if (Objects.equals(l.getType(), optional.get().getType())) { |
| 415 | locationList.add(l); | 415 | locationList.add(l); |
| 416 | return null; | 416 | return null; |
| 417 | } | 417 | } |