fix:查询是否开模件的待办

This commit is contained in:
2026-03-11 16:28:22 +08:00
parent 3ae6e6b80a
commit 4c87aaaca5
7 changed files with 15 additions and 14 deletions

View File

@@ -128,13 +128,12 @@ public class SimulationDemandController {
/** /**
* 给 MES系统使用 查询是否开模件的待办列表 * 给 MES系统使用 查询是否开模件的待办列表
* @param req
* @return * @return
*/ */
@GetMapping("/queryTodoList") @GetMapping("/queryTodoList")
@Operation(summary = "条件查询待办(需求)列表", description = "条件查询待办(需求)列表") @Operation(summary = "条件查询待办(需求)列表", description = "条件查询待办(需求)列表")
public SdmResponse queryTodoList(@RequestBody DemandQryReq req) { public SdmResponse queryTodoList(@RequestParam String isMoldMaking) {
return demandService.queryTodoList(req); return demandService.queryTodoList(isMoldMaking);
} }
/** /**

View File

@@ -45,7 +45,7 @@ public interface SimulationDemandMapper extends BaseMapper<SimulationDemand> {
Set<String> getAllCodeList(); Set<String> getAllCodeList();
List<SpdmDemandVo> getDemandListWithCondition(@Param("req") DemandQryReq req); List<SpdmDemandVo> getDemandListWithCondition(@Param("isMoldMaking") String isMoldMaking);
List<SpdmDemandVo> getDemandListByProjectId(@Param("nodeId") String nodeId); List<SpdmDemandVo> getDemandListByProjectId(@Param("nodeId") String nodeId);

View File

@@ -8,8 +8,5 @@ public class DemandQryReq {
* 是否开模件 Y/N * 是否开模件 Y/N
*/ */
private String isMoldMaking; private String isMoldMaking;
/**
* 物料号
*/
private String materialNo;
} }

View File

@@ -178,6 +178,10 @@ public class SpdmDemandVo extends BaseEntity {
* 物料号 * 物料号
*/ */
private String materialNo; private String materialNo;
/**
* 是否开模件
*/
private String isMoldMaking;
/** /**
* 需求附件id列表 * 需求附件id列表
*/ */

View File

@@ -45,7 +45,7 @@ public interface IDemandService {
SdmResponse<PageDataResp<List<FileMetadataInfoResp>>> queryDemandFiles(QueryDirReq req); SdmResponse<PageDataResp<List<FileMetadataInfoResp>>> queryDemandFiles(QueryDirReq req);
SdmResponse queryTodoList(DemandQryReq req); SdmResponse queryTodoList(String isMoldMaking);
SdmResponse addDemandNoPermission(SpdmAddDemandReq req); SdmResponse addDemandNoPermission(SpdmAddDemandReq req);

View File

@@ -1250,8 +1250,8 @@ public class DemandServiceImpl extends BaseService implements IDemandService {
} }
@Override @Override
public SdmResponse queryTodoList(DemandQryReq req) { public SdmResponse queryTodoList(String isMoldMaking) {
List<SpdmDemandVo> demandVoList = mapper.getDemandListWithCondition(req); List<SpdmDemandVo> demandVoList = mapper.getDemandListWithCondition(isMoldMaking);
if (CollectionUtils.isNotEmpty(demandVoList)) { if (CollectionUtils.isNotEmpty(demandVoList)) {
for (SpdmDemandVo demandVo : demandVoList) { for (SpdmDemandVo demandVo : demandVoList) {
QueryDirReq dirReq = new QueryDirReq(); QueryDirReq dirReq = new QueryDirReq();

View File

@@ -187,13 +187,14 @@
<select id="getDemandListWithCondition" resultType="com.sdm.project.model.vo.SpdmDemandVo"> <select id="getDemandListWithCondition" resultType="com.sdm.project.model.vo.SpdmDemandVo">
SELECT SELECT
sd.*, sd.*,
mold_material.property_value AS materialNo mold_material.property_value AS materialNo,
is_mold.property_value AS isMoldMaking
FROM simulation_demand sd FROM simulation_demand sd
INNER JOIN simulation_demand_extra is_mold INNER JOIN simulation_demand_extra is_mold
ON sd.uuid = is_mold.demand_id ON sd.uuid = is_mold.demand_id
AND is_mold.property_name = 'isMoldMaking' AND is_mold.property_name = 'isMoldMaking'
<if test="req.isMoldMaking != null"> <if test="isMoldMaking != null">
AND is_mold.property_value = #{req.isMoldMaking} AND is_mold.property_value = #{isMoldMaking}
</if> </if>
LEFT JOIN simulation_demand_extra mold_material LEFT JOIN simulation_demand_extra mold_material
ON sd.uuid = mold_material.demand_id ON sd.uuid = mold_material.demand_id