From efcccd9a97bfd1e60a292f25b66c8a2c318c8434 Mon Sep 17 00:00:00 2001 From: tyty Date: Mon, 21 Aug 2023 14:51:39 +0800 Subject: [PATCH 1/8] =?UTF-8?q?=E5=AF=B9=E5=B9=B3=E5=8F=B0=E8=BF=94?= =?UTF-8?q?=E5=9B=9E=E7=9A=84=E6=8E=A5=E5=8F=A3=E5=81=9A=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../operational/duty/service/impl/ImsAnalyseExampleServiceImpl.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsAnalyseExampleServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsAnalyseExampleServiceImpl.java index 46dfbd9..162ba11 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsAnalyseExampleServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsAnalyseExampleServiceImpl.java @@ -65,6 +65,9 @@ public class ImsAnalyseExampleServiceImpl extends BaseServiceImpl> analyzeDataByAnalyzeCode = searchClient.getAnalyzeDataByAnalyzeCode(analyzeDataCondition); + if(!analyzeDataByAnalyzeCode.isSuccess()) { + throw new ServiceException("设备数据查询异常,请检查好配置后重试!"); + } return analyzeDataByAnalyzeCode; } @@ -131,6 +134,9 @@ public class ImsAnalyseExampleServiceImpl extends BaseServiceImpl Date: Tue, 22 Aug 2023 11:22:17 +0800 Subject: [PATCH 2/8] =?UTF-8?q?=E5=B7=A1=E6=A3=80=E8=AE=A1=E5=88=92?= =?UTF-8?q?=E5=8F=AF=E6=92=A4=E9=94=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hnac/hzims/operational/OperationalConstants.java | 2 +- .../inspect/plan/controller/PlanController.java | 19 +++++++++---------- .../hzinfo/inspect/plan/service/IPlanService.java | 2 ++ .../inspect/plan/service/impl/PlanServiceImpl.java | 15 +++++++++++++++ 4 files changed, 27 insertions(+), 11 deletions(-) diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java index 93810fc..16f31e5 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java @@ -4,7 +4,7 @@ import lombok.Getter; public class OperationalConstants { - public final static String APP_NAME = "hzims-operational"; + public final static String APP_NAME = "hzims-operational-ty"; diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java index df2452c..bc04f66 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java @@ -1,15 +1,11 @@ package com.hnac.hzinfo.inspect.plan.controller; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; -import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; import com.hnac.hzims.common.logs.annotation.OperationAnnotation; import com.hnac.hzims.common.logs.enums.BusinessType; import com.hnac.hzims.common.logs.enums.OperatorType; -import com.hnac.hzinfo.inspect.Constants; -import com.hnac.hzinfo.inspect.invalid.DictInvalid; import com.hnac.hzinfo.inspect.obj.utils.CodeUtils; import com.hnac.hzinfo.inspect.plan.PlanContants; import com.hnac.hzinfo.inspect.plan.entity.PlanEntity; @@ -24,7 +20,6 @@ import org.springblade.core.boot.ctrl.BladeController; import org.springblade.core.log.exception.ServiceException; import org.springblade.core.mp.support.Query; import org.springblade.core.secure.BladeUser; -import org.springblade.core.secure.utils.AuthUtil; import org.springblade.core.tool.api.R; import org.springblade.core.tool.constant.BladeConstant; import org.springblade.core.tool.utils.Func; @@ -32,11 +27,7 @@ import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.*; import javax.validation.Valid; -import javax.validation.constraints.Max; -import javax.validation.constraints.Min; -import javax.validation.constraints.Size; import java.time.LocalDate; -import java.time.LocalDateTime; import java.util.List; @@ -113,7 +104,15 @@ public class PlanController extends BladeController { public R> addAndChecked(@Valid @RequestBody PlanVO plan) { return R.data(planService.addAndChecked(plan)); } - + /** + * 撤销 + */ + @PostMapping("/revoke") + @ApiOperationSupport(order = 6) + @ApiOperation(value = "撤销", notes = "传入plan") + public R revoke(@Valid @RequestBody Long planId) { + return R.data(planService.revoke(planId)); + } /** * 删除 diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/IPlanService.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/IPlanService.java index e3ce4ec..bf491d2 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/IPlanService.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/IPlanService.java @@ -59,4 +59,6 @@ public interface IPlanService extends BaseService { Boolean deletePlanAndRelatives(Long id); List getPlans(List planIds); + + Boolean revoke(Long planId); } diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java index 6c1b0b7..81ae5a8 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java @@ -109,6 +109,21 @@ public class PlanServiceImpl extends BaseServiceImpl imp } /** + *巡检计划撤销 + * @param planId + * @return + */ + @Override + public Boolean revoke(Long planId) { + boolean re; + LambdaUpdateWrapper uw = new UpdateWrapper().lambda(); + uw.set(PlanEntity::getStatus, PlanContants.PlanStatusEnum.PLAN_SUBMIT); + uw.eq(PlanEntity::getId, planId); + re = update(uw); + return re; + } + + /** * 保存巡检计划 */ @Transactional(rollbackFor = Exception.class) From 6960dacf4cab878943499932f35239482cecea66 Mon Sep 17 00:00:00 2001 From: tyty Date: Tue, 22 Aug 2023 11:24:24 +0800 Subject: [PATCH 3/8] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/hnac/hzims/operational/OperationalConstants.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java index 16f31e5..93810fc 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/OperationalConstants.java @@ -4,7 +4,7 @@ import lombok.Getter; public class OperationalConstants { - public final static String APP_NAME = "hzims-operational-ty"; + public final static String APP_NAME = "hzims-operational"; From c5ba0661d5d83f75fc6c433a656e951d9a6767a6 Mon Sep 17 00:00:00 2001 From: tyty Date: Tue, 22 Aug 2023 12:01:26 +0800 Subject: [PATCH 4/8] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=8E=92=E7=8F=AD?= =?UTF-8?q?=E5=AF=BC=E5=87=BA=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../operational/duty/service/impl/ImsDutyMainServiceImpl.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyMainServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyMainServiceImpl.java index 3901698..ecc07ca 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyMainServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyMainServiceImpl.java @@ -1409,6 +1409,7 @@ public class ImsDutyMainServiceImpl extends BaseServiceImpl personWrapper = new LambdaQueryWrapper(); personWrapper.eq(ImsDutyMainPersonEntity::getCreateDept, deptId); + personWrapper.like(ImsDutyMainPersonEntity::getDutyDate, yearAndMonth); List deptPersonList = imsDutyMainPersonMapper.selectList(personWrapper); // 获取本月天数 @@ -1438,13 +1439,15 @@ public class ImsDutyMainServiceImpl extends BaseServiceImpl list = imsDutyGroupPService.list(groupPWrapper); managerName = deptUserMap.get(deptDutyGroupMap.get(imsDutyMainEntity.getDutyGroupId()).getManagerId()); - personIds = list.stream().map(ImsDutyGroupPEntity::getPersonId).collect(Collectors.toList()); + personIds = list.stream() +// 过滤出组长 + .filter(s->!s.getPersonId().equals(deptDutyGroupMap.get(imsDutyMainEntity.getDutyGroupId()).getManagerId())) + .map(ImsDutyGroupPEntity::getPersonId).collect(Collectors.toList()); } else { // 不存在分组id从排班人员中获取组长和组员 List personList = deptPersonList.stream().filter(var -> var.getDutyMainId().equals(imsDutyMainEntity.getId())).collect(Collectors.toList()); - managerName = deptUserMap.get(personList.get(0).getDutyChargePerson()); - personIds = personList.stream().map(ImsDutyMainPersonEntity::getDutyPerson).collect(Collectors.toList()); + personIds = personList.stream().filter(s->!s.getDutyPerson().equals(personList.get(0).getDutyChargePerson())).map(ImsDutyMainPersonEntity::getDutyPerson).collect(Collectors.toList()); } String personNames = ""; From 39095d5090136278173bb1d8da4d6a4ea63ff4aa Mon Sep 17 00:00:00 2001 From: tyty Date: Tue, 22 Aug 2023 16:50:24 +0800 Subject: [PATCH 5/8] =?UTF-8?q?=E5=B7=A1=E6=A3=80=E6=92=A4=E9=94=80?= =?UTF-8?q?=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hnac/hzinfo/inspect/plan/controller/PlanController.java | 11 +++++------ .../hzinfo/inspect/plan/service/impl/PlanServiceImpl.java | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java index bc04f66..00ca26a 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/controller/PlanController.java @@ -7,7 +7,6 @@ import com.hnac.hzims.common.logs.annotation.OperationAnnotation; import com.hnac.hzims.common.logs.enums.BusinessType; import com.hnac.hzims.common.logs.enums.OperatorType; import com.hnac.hzinfo.inspect.obj.utils.CodeUtils; -import com.hnac.hzinfo.inspect.plan.PlanContants; import com.hnac.hzinfo.inspect.plan.entity.PlanEntity; import com.hnac.hzinfo.inspect.plan.service.IPlanObjectTemplateService; import com.hnac.hzinfo.inspect.plan.service.IPlanService; @@ -74,9 +73,9 @@ public class PlanController extends BladeController { if(plan.getEndTime()!=null){ queryWrapper.le(PlanEntity::getEndTime,plan.getEndTime()); } - if(plan.getStatus()==null){ - queryWrapper.ne(PlanEntity::getStatus, PlanContants.PlanStatusEnum.PLAN_AUTH.getStatus()); - } +// if(plan.getStatus()==null){ +// queryWrapper.ne(PlanEntity::getStatus, PlanContants.PlanStatusEnum.PLAN_AUTH.getStatus()); +// } if(plan.getCreateDept()!=null){ queryWrapper.eq(PlanEntity::getCreateDept,plan.getCreateDept()); } @@ -107,10 +106,10 @@ public class PlanController extends BladeController { /** * 撤销 */ - @PostMapping("/revoke") + @GetMapping("/revoke") @ApiOperationSupport(order = 6) @ApiOperation(value = "撤销", notes = "传入plan") - public R revoke(@Valid @RequestBody Long planId) { + public R revoke(@RequestParam Long planId) { return R.data(planService.revoke(planId)); } diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java index 81ae5a8..b060ace 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/plan/service/impl/PlanServiceImpl.java @@ -117,7 +117,7 @@ public class PlanServiceImpl extends BaseServiceImpl imp public Boolean revoke(Long planId) { boolean re; LambdaUpdateWrapper uw = new UpdateWrapper().lambda(); - uw.set(PlanEntity::getStatus, PlanContants.PlanStatusEnum.PLAN_SUBMIT); + uw.set(PlanEntity::getStatus, PlanContants.PlanStatusEnum.PLAN_SUBMIT.getStatus()); uw.eq(PlanEntity::getId, planId); re = update(uw); return re; From cf6064baa3863c942d420f42030c66aa8d97187a Mon Sep 17 00:00:00 2001 From: tyty Date: Wed, 23 Aug 2023 10:03:03 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=E7=BC=BA=E9=99=B7=E5=AE=9E=E4=BE=8B?= =?UTF-8?q?=E7=B1=BB=E7=94=9F=E6=88=90bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wrapper/OperDefectStatisticsWrapper.java | 31 +++++++++++----------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/wrapper/OperDefectStatisticsWrapper.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/wrapper/OperDefectStatisticsWrapper.java index 326bb0b..5cac3e6 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/wrapper/OperDefectStatisticsWrapper.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/defect/wrapper/OperDefectStatisticsWrapper.java @@ -1,12 +1,10 @@ package com.hnac.hzims.operational.defect.wrapper; -import com.baomidou.mybatisplus.core.metadata.IPage; import com.hnac.hzims.operational.defect.entity.OperDefectStatisticsEntity; import com.hnac.hzims.operational.defect.vo.OperDefectStatisticsVO; import org.springblade.core.mp.support.BaseEntityWrapper; import org.springblade.core.tool.utils.BeanUtil; import org.springblade.core.tool.utils.Func; -import org.springblade.system.entity.Dept; import org.springblade.system.user.cache.UserCache; import org.springblade.system.user.entity.User; @@ -30,19 +28,22 @@ public class OperDefectStatisticsWrapper extends BaseEntityWrapper Date: Wed, 23 Aug 2023 11:47:38 +0800 Subject: [PATCH 7/8] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=A3=80=E4=BF=AE?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../access/controller/OperAccessStatisticsController.java | 4 ++-- .../operational/access/controller/OperAccessTaskController.java | 7 +++++-- .../com/hnac/hzims/operational/access/dto/OperAccessTaskDTO.java | 7 ++++++- .../hzims/operational/access/mapper/OperAccessStatisticsMapper.xml | 6 ------ .../hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml | 6 ++++++ 5 files changed, 19 insertions(+), 11 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessStatisticsController.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessStatisticsController.java index 92435c4..13b9364 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessStatisticsController.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessStatisticsController.java @@ -80,13 +80,13 @@ public class OperAccessStatisticsController extends BladeController { * 分页 */ @ApiLog - @PostMapping("/list") + @GetMapping("/list") @ApiOperationSupport(order = 50) @ApiOperation(value = "分页 查询参数:pid,taskId,manager") @OperationAnnotation(moduleName = "检修管理",title = "检修记录",operatorType = OperatorType.MOBILE,businessType = BusinessType.GENCODE, action = "分页查询检修记录列表") - public R> list(@RequestBody OperAccessStatisticsDTO req, Query query) { + public R> list(OperAccessStatisticsDTO req, Query query) { return service.list(req, Condition.getPage(query)); } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java index 9e40bf2..c5df91c 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java @@ -91,13 +91,16 @@ public class OperAccessTaskController extends BladeController { * 分页 */ @ApiLog - @GetMapping("/list") + @PostMapping("/list") @ApiOperationSupport(order = 50) @OperationAnnotation(moduleName = "检修管理",title = "我的检修任务",operatorType = OperatorType.MOBILE,businessType = BusinessType.GENCODE, action = "分页查询我的检修任务列表") @ApiOperation(value = "分页 查询参数:name,code,handler,status,planId,planCode") - public R> list(OperAccessTaskDTO req, Query query) { + public R> list(@RequestBody OperAccessTaskDTO req) { + Query query=new Query(); + query.setCurrent(req.getCurrent()); + query.setSize(req.getSize()); return service.list(req, query); } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/dto/OperAccessTaskDTO.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/dto/OperAccessTaskDTO.java index ae0d3b3..a3a3508 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/dto/OperAccessTaskDTO.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/dto/OperAccessTaskDTO.java @@ -21,7 +21,8 @@ public class OperAccessTaskDTO extends OperAccessTaskEntity { @ApiModelProperty(value = "创建机构集合") private List deptIds; - + @ApiModelProperty(value = "ids") + private List ids; @ApiModelProperty(value = "工作流Key") private String procDefId; @@ -39,4 +40,8 @@ public class OperAccessTaskDTO extends OperAccessTaskEntity { @ApiModelProperty("结束时间") private String endTime; + @ApiModelProperty("当前页") + private Integer current; + @ApiModelProperty("每页的数量") + private Integer size; } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessStatisticsMapper.xml b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessStatisticsMapper.xml index 994ab75..e390f35 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessStatisticsMapper.xml +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessStatisticsMapper.xml @@ -28,12 +28,6 @@ JOIN hzims_oper_access_task OT ON OS.`TASK_ID` = OT.`ID` WHERE OS.IS_DELETED = 0 - - and OS.id in - - #{item} - - and OT.`NAME` like concat('%',#{dto.taskName},'%') diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml index 640690d..13cbc3b 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml @@ -65,6 +65,12 @@ AND t.`CODE` LIKE CONCAT('%',#{req.code},'%') + + AND t.id in + + #{item} + + AND t.`HANDLER`=#{req.handler} From 25ce94c2600d32ac138e88a43566ac585ef6c4fb Mon Sep 17 00:00:00 2001 From: tyty Date: Wed, 23 Aug 2023 14:03:39 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=A3=80=E4=BF=AE?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E7=BB=9F=E8=AE=A1=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/OperAccessTaskController.java | 19 ++++++-- .../access/mapper/OperAccessTaskMapper.java | 3 ++ .../access/mapper/OperAccessTaskMapper.xml | 50 +++++++++++++++++++--- .../access/service/IOperAccessTaskService.java | 1 + .../service/impl/OperAccessTaskServiceImpl.java | 8 ++++ 5 files changed, 71 insertions(+), 10 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java index c5df91c..de3219d 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/controller/OperAccessTaskController.java @@ -87,24 +87,37 @@ public class OperAccessTaskController extends BladeController { return service.detail(id); } + /** * 分页 */ @ApiLog - @PostMapping("/list") + @GetMapping("/list") @ApiOperationSupport(order = 50) @OperationAnnotation(moduleName = "检修管理",title = "我的检修任务",operatorType = OperatorType.MOBILE,businessType = BusinessType.GENCODE, action = "分页查询我的检修任务列表") @ApiOperation(value = "分页 查询参数:name,code,handler,status,planId,planCode") + public R> list(OperAccessTaskDTO req, Query query) { + return service.list(req, query); + } + /** + * 分页 + */ + @ApiLog + @PostMapping("/listByStatus") + @ApiOperationSupport(order = 50) + @OperationAnnotation(moduleName = "检修管理",title = "检修任务",operatorType = OperatorType.MOBILE,businessType = + BusinessType.GENCODE, + action = "分页查询我的检修任务列表") + @ApiOperation(value = "分页 查询参数:name,code,handler,status,planId,planCode") public R> list(@RequestBody OperAccessTaskDTO req) { Query query=new Query(); query.setCurrent(req.getCurrent()); query.setSize(req.getSize()); - return service.list(req, query); + return service.listByStatus(req, query); } - /** * 获取检修台账 */ diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.java index b9ca2b3..b45f846 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.java @@ -28,6 +28,9 @@ public interface OperAccessTaskMapper extends UserDataScopeBaseMapper pageCondition(IPage page, @Param("req") OperAccessTaskDTO req); + + List pageConditionByStatus(IPage page, @Param("req") OperAccessTaskDTO req); + List selectByEmCode(String emCode,List list); @SqlParser(filter = true) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml index 13cbc3b..6efe664 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/access/mapper/OperAccessTaskMapper.xml @@ -65,12 +65,7 @@ AND t.`CODE` LIKE CONCAT('%',#{req.code},'%') - - AND t.id in - - #{item} - - + AND t.`HANDLER`=#{req.handler} @@ -97,7 +92,48 @@ ORDER BY t.create_time DESC - +