bug修复

This commit is contained in:
mashuai 2025-04-15 09:52:37 +08:00
parent c26ae71d3e
commit c1e851ac14
3 changed files with 0 additions and 33 deletions

View File

@ -214,13 +214,6 @@ public interface BackReceiveMapper {
int finishBackCheckDetails(BackApplyInfo record);
/**
* 修改退料记录表back_check_details为完成退料
* @param id
* @return
*/
int updateBackCheckDetails(Long id);
/**
* 根据查询协议id
* @param record

View File

@ -303,35 +303,12 @@ public class BackReceiveServiceImpl implements BackReceiveService {
int postStoreNum = backReceiveMapper.getmaChineByCt(record);
record.setPostStoreNum(postStoreNum);
}
// 修改退料记录表back_check_details为完成退料1
if (StringUtils.isNotBlank(record.getBadId())) {
res = updateBackCheckDetails(record);
if (res == 0) {
throw new RuntimeException("修改back_check_details表异常");
}
}
} else {
throw new RuntimeException("typeId为空");
}
return res;
}
/**
* 修改退料记录表back_check_details为完成退料1
*
* @param record
* @return
*/
private int updateBackCheckDetails(BackApplyInfo record) {
int res = 0;
// 对record中的badId进行分割
String[] split = record.getBadId().split(",");
for (String s : split) {
long id = Long.parseLong(s);
res += backReceiveMapper.updateBackCheckDetails(id);
}
return res;
}
private int selectTaskStatus(int taskId) {
int taskStatus = backReceiveMapper.selectTaskStatus(taskId);

View File

@ -627,9 +627,6 @@
update back_check_details set is_finished = 1 where parent_id = #{parentId} and type_id = #{typeId} and (is_finished is null or is_finished != 1)
</update>
<update id="updateBackCheckDetails">
update back_check_details set status = '1' where id = #{id}
</update>
<update id="updateMtNum">
UPDATE ma_type
SET num = (IFNULL(num, 0)) - #{backNum}