生产单管理

This commit is contained in:
lym
2024-05-11 10:23:46 +08:00
parent d9735d3e49
commit 3cef4142fe
30 changed files with 499 additions and 907 deletions
@@ -20,4 +20,8 @@ public interface PlateApi {
@Parameter(name = "id", description = "编号", required = true, example = "1024")
CommonResult<Boolean> getPlate(@RequestParam("id") Long id);
@GetMapping(PREFIX +"/getGoodsId")
@Operation(summary = "判断板材是否存在")
@Parameter(name = "id", description = "客户的商品编号", required = true, example = "1024")
CommonResult<Long> getPlateGoods(@RequestParam("id") Long goodsId);
}
@@ -21,4 +21,16 @@ public class PlateServiceImpl implements PlateApi{
}
return success(true);
}
@Override
public CommonResult<Long> getPlateGoods(Long goodsId) {
if (goodsId == null) {
return success(0L);
}
PlateDO plateDO = plateService.getPlateGoods(goodsId);
if (plateDO == null) {
return success(0L);
}
return success(plateDO.getId());
}
}
@@ -48,6 +48,14 @@ public interface PlateService {
*/
PlateDO getPlate(Long id);
/**
* 获得板材信息表 plate_{N}
*
* @param id 编号
* @return 板材信息表 plate_{N}
*/
PlateDO getPlateGoods(Long id);
/**
* 获得板材信息表 plate_{N}分页
*
@@ -98,6 +98,11 @@ public class PlateServiceImpl implements PlateService {
return plateMapper.selectById(id);
}
@Override
public PlateDO getPlateGoods(Long id) {
return plateMapper.selectOne(PlateDO::getGoodsId,id);
}
@Override
public PageResult<PlateDO> getPlatePage(PlatePageReqVO pageReqVO) {
if (pageReqVO.getOrganId() == null || pageReqVO.getOrganId() == 0){