diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/controller/admin/DlRepairSoController.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/controller/admin/DlRepairSoController.java index c0e01b64..a3abfca6 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/controller/admin/DlRepairSoController.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/controller/admin/DlRepairSoController.java @@ -5,19 +5,19 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult; import cn.iocoder.yudao.module.stockOperate.entity.DlRepairSo; import cn.iocoder.yudao.module.stockOperate.service.DlRepairSoService; import cn.iocoder.yudao.module.stockOperate.vo.DlRepairSoReqVO; +import cn.iocoder.yudao.module.stockOperate.vo.DlRepairSoRespVO; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestParam; -import org.springframework.web.bind.annotation.RestController; +import io.swagger.v3.oas.annotations.Operation; +import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; /** * 采购单领料单(DlRepairSo)表控制层 + * * @author 小李 * @date 9:13 2024/9/13 -**/ + **/ @RestController @RequestMapping("/repair/so") public class DlRepairSoController { @@ -28,19 +28,16 @@ public class DlRepairSoController { private DlRepairSoService dlRepairSoService; /** - * 分页查询所有数据 + * 采购单/领料单 新增 * @author 小李 - * @date 16:12 2024/9/13 - * @param repairSoReqVO 查询对象 - * @param pageNo 页码 - * @param pageSize 条数 + * @date 10:49 2024/9/14 + * @param repairSoRespVO 采购单对象 **/ - @GetMapping("/page") - public CommonResult getDlRepairSoPage(DlRepairSoReqVO repairSoReqVO, - @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, - @RequestParam(value = "pageSize", defaultValue = "10") Integer pageSize) { - Page page = new Page<>(pageNo, pageSize); - return null; + @PostMapping("/create") + @Operation(summary = "采购单/领料单新增") + public CommonResult createRepairSo(@RequestBody DlRepairSoRespVO repairSoRespVO) { + dlRepairSoService.createRepairSo(repairSoRespVO); + return CommonResult.ok(); } } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/DlRepairSoService.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/DlRepairSoService.java index 24e4a6a6..d0102bb1 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/DlRepairSoService.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/DlRepairSoService.java @@ -1,6 +1,7 @@ package cn.iocoder.yudao.module.stockOperate.service; import cn.iocoder.yudao.module.stockOperate.entity.DlRepairSo; +import cn.iocoder.yudao.module.stockOperate.vo.DlRepairSoRespVO; import com.baomidou.mybatisplus.extension.service.IService; /** @@ -9,4 +10,12 @@ import com.baomidou.mybatisplus.extension.service.IService; * @date 9:09 2024/9/13 **/ public interface DlRepairSoService extends IService { + + /** + * 采购单/领料单 新增 + * @author 小李 + * @date 10:49 2024/9/14 + * @param repairSoRespVO 采购单对象 + **/ + void createRepairSo(DlRepairSoRespVO repairSoRespVO); } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/impl/DlRepairSoServiceImpl.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/impl/DlRepairSoServiceImpl.java index 95380949..d624f12b 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/impl/DlRepairSoServiceImpl.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/service/impl/DlRepairSoServiceImpl.java @@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.stockOperate.service.impl; import cn.iocoder.yudao.module.stockOperate.entity.DlRepairSo; import cn.iocoder.yudao.module.stockOperate.mapper.DlRepairSoMapper; import cn.iocoder.yudao.module.stockOperate.service.DlRepairSoService; +import cn.iocoder.yudao.module.stockOperate.vo.DlRepairSoRespVO; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import org.springframework.stereotype.Service; @@ -16,6 +17,16 @@ import org.springframework.stereotype.Service; public class DlRepairSoServiceImpl extends ServiceImpl implements DlRepairSoService { + /** + * 采购单/领料单 新增 + * @author 小李 + * @date 10:49 2024/9/14 + * @param repairSoRespVO 采购单对象 + **/ + @Override + public void createRepairSo(DlRepairSoRespVO repairSoRespVO){ + return; + } } diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/vo/DlRepairSoRespVO.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/vo/DlRepairSoRespVO.java index 6d402f29..6c3c3bd0 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/vo/DlRepairSoRespVO.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/stockOperate/vo/DlRepairSoRespVO.java @@ -2,6 +2,9 @@ package cn.iocoder.yudao.module.stockOperate.vo; import cn.iocoder.yudao.module.stockOperate.entity.DlRepairSo; import lombok.Data; +import org.apache.poi.ss.formula.functions.T; + +import java.util.List; /** * 采购单/领料单 响应VO @@ -10,4 +13,7 @@ import lombok.Data; **/ @Data public class DlRepairSoRespVO extends DlRepairSo { + + // 商品List + private List partList; }