From ac25a0cac87f6a3c4b840f240ae1413d9d1aa3f3 Mon Sep 17 00:00:00 2001 From: Vinjor Date: Tue, 12 Nov 2024 17:36:04 +0800 Subject: [PATCH] 1 --- .../admin/DlRepairTitemController.java | 2 +- .../app/ApiRepairTitemController.java | 2 +- .../tickets/mapper/DlRepairTitemMapper.java | 11 ++++ .../tickets/service/DlRepairTitemService.java | 2 +- .../impl/DlRepairTitemServiceImpl.java | 11 ++-- .../tickets/vo/DlRepairTitemRespVO.java | 7 +++ .../mapper/tickets/DlRepairTitemMapper.xml | 53 +++++++++++++++++++ 7 files changed, 79 insertions(+), 9 deletions(-) diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/admin/DlRepairTitemController.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/admin/DlRepairTitemController.java index eadcf5ef..09957768 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/admin/DlRepairTitemController.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/admin/DlRepairTitemController.java @@ -163,7 +163,7 @@ public class DlRepairTitemController { @GetMapping("/getProjList") @Operation(summary = "查某工单维修项目进度") public CommonResult getProjList(@RequestParam("ticketId") String ticketId){ - return success(dlRepairTitemService.getProjList(ticketId)); + return success(dlRepairTitemService.getProjList(ticketId,null)); } } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/app/ApiRepairTitemController.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/app/ApiRepairTitemController.java index 7452f3bd..1798a6db 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/app/ApiRepairTitemController.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/controller/app/ApiRepairTitemController.java @@ -37,7 +37,7 @@ public class ApiRepairTitemController { @Operation(summary = "查某工单维修项目进度") @TenantIgnore public CommonResult getProjList(@RequestParam("ticketId") String ticketId){ - return success(dlRepairTitemService.getProjList(ticketId)); + return success(dlRepairTitemService.getProjList(ticketId,"1")); } } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/mapper/DlRepairTitemMapper.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/mapper/DlRepairTitemMapper.java index a17f4976..c3ac254b 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/mapper/DlRepairTitemMapper.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/mapper/DlRepairTitemMapper.java @@ -8,6 +8,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; +import java.util.List; + /** * 针对表【dl_repair_titem(维修工单子表)】的数据库操作Mapper * @@ -31,6 +33,15 @@ public interface DlRepairTitemMapper extends BaseMapper { * @param dlRepairTitem */ void updateRepairAndSale(DlRepairTitem dlRepairTitem); + + /** + * 查某工单维修项目进度 + * @author vinjor-M + * @date 15:33 2024/11/12 + * @param ticketId 工单id + * @return java.util.List + **/ + List selectProjList(@Param("ticketId")String ticketId,@Param("isOpen")String isOpen); } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/DlRepairTitemService.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/DlRepairTitemService.java index a0c126b3..9c2d3977 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/DlRepairTitemService.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/DlRepairTitemService.java @@ -82,5 +82,5 @@ public interface DlRepairTitemService extends IService { * @param ticketId 工单ID * @return java.util.List **/ - List getProjList(String ticketId); + List getProjList(String ticketId,String isOpen); } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTitemServiceImpl.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTitemServiceImpl.java index 14e735d6..a15315ac 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTitemServiceImpl.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTitemServiceImpl.java @@ -11,6 +11,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import javax.annotation.Resource; @@ -31,6 +32,8 @@ public class DlRepairTitemServiceImpl extends ServiceImpl getProjList(String ticketId) { - LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper() - .eq(DlRepairTitem::getTicketId,ticketId) - .eq(DlRepairTitem::getItemType,"01") - .orderByDesc(DlRepairTitem::getItemStatus); - return this.list(queryWrapper); + public List getProjList(String ticketId,String isOpen) { + return dlRepairTitemMapper.selectProjList(ticketId,isOpen); } } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/vo/DlRepairTitemRespVO.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/vo/DlRepairTitemRespVO.java index 4788e3d4..e79b78f1 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/vo/DlRepairTitemRespVO.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/vo/DlRepairTitemRespVO.java @@ -1,9 +1,11 @@ package cn.iocoder.yudao.module.tickets.vo; +import cn.iocoder.yudao.module.base.entity.RepairRecordsItem; import cn.iocoder.yudao.module.tickets.entity.DlRepairTitem; import lombok.Data; import java.util.Date; +import java.util.List; /** * 维修工单子表 响应VO @@ -24,4 +26,9 @@ public class DlRepairTitemRespVO extends DlRepairTitem { private String corpId; private String ticketNo; + + /** + * 维修项目的维修过程图片 + **/ + private List recordsItemList; } diff --git a/dl-module-repair/src/main/resources/mapper/tickets/DlRepairTitemMapper.xml b/dl-module-repair/src/main/resources/mapper/tickets/DlRepairTitemMapper.xml index 73d98ddd..ff4e32fd 100644 --- a/dl-module-repair/src/main/resources/mapper/tickets/DlRepairTitemMapper.xml +++ b/dl-module-repair/src/main/resources/mapper/tickets/DlRepairTitemMapper.xml @@ -3,6 +3,32 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> + + + + + + + + + + + + + + + + + + + + + + + + + UPDATE dl_repair_titem @@ -56,4 +82,31 @@ FROM dl_repair_titem drti LEFT JOIN dl_repair_tickets drt ON drti.ticket_id = drt.id +