多次出库bug修改

pro
郑明梁 2 years ago
parent 374f8261f8
commit 487473f91c

@ -94,6 +94,18 @@ public class IoOrderMutiController {
}
return ResultVOUtils.success(ioOrderMutiEntityOne.getId());
} else {
if(StrUtil.isNotBlank(ioOrderMutiEntity.getMark())){
QueryWrapper<IoOrderMutiEntity> ew1=new QueryWrapper<>();
ew1.eq("mark",ioOrderMutiEntity.getMark());
long count = ioOrderMutiService.count(ew1);
if(count>0){
return ResultVOUtils.error(999, "标志位已存在!");
}
}else{
return ResultVOUtils.error(999, "标志位不能为空!");
}
ioOrderMutiEntityOne = new IoOrderMutiEntity();
ioOrderMutiEntityOne.setId(IdUtil.getSnowflakeNextId());
ioOrderMutiEntityOne.setRelIdFk(udiProductEntity.getRelId());
@ -161,6 +173,18 @@ public class IoOrderMutiController {
}
}
if(StrUtil.isNotBlank(ioOrderMutiEntity.getMark())){
QueryWrapper<IoOrderMutiEntity> ew=new QueryWrapper<>();
ew.eq("mark",ioOrderMutiEntity.getMark());
long count = ioOrderMutiService.count(ew);
if(count>0){
return ResultVOUtils.error(999, "标志位已存在!");
}
}else{
return ResultVOUtils.error(999, "标志位不能为空!");
}
IoOrderMutiEntity ioOrderMutiEntity1 = new IoOrderMutiEntity();
ioOrderMutiEntity1.setId(IdUtil.getSnowflakeNextId());
ioOrderMutiEntity1.setRelIdFk(udiProductEntity.getRelId());
@ -200,7 +224,8 @@ public class IoOrderMutiController {
ioOrderMutiEntity.setTotalCount(totalCount);
ioOrderMutiEntity.setUseCount(useCount);
ioOrderMutiEntity.setStatus(status);
if (StrUtil.isBlank(ioOrderMutiEntity.getOrderIdFk())) {
System.out.println("1111111111111111");
if (StrUtil.isBlank(ioOrderMutiEntity.getOrderIdFk()) && ioOrderMutiEntity.getStatus() == 1) {
IoOrderEntity orderEntity = new IoOrderEntity();
//查询补单条件
AuthAdmin authAdmin = customerService.getUserBean();
@ -263,7 +288,7 @@ public class IoOrderMutiController {
ioOrderMutiEntity.setUpdateUser(customerService.getUserId() + "");
boolean falg = ioOrderMutiService.updateById(ioOrderMutiEntity);
System.out.println("22222222222222222222222");
QueryWrapper<IoOrderMutiUseEntity> ew = new QueryWrapper<>();
ew.eq("mutiIdFk", ioOrderMutiEntity.getId());
List<IoOrderMutiUseEntity> ioOrderMutiUseEntityList = ioOrderMutiUseService.list(ew);
@ -271,7 +296,7 @@ public class IoOrderMutiController {
ioOrderMutiUseEntity.setStatus(1);
}
ioOrderMutiUseService.updateBatchById(ioOrderMutiUseEntityList);
System.out.println("33333333333333333333333");
if (falg) {
return ResultVOUtils.success();
} else {

@ -23,9 +23,4 @@ public class IntUtil {
else return value;
}
public static boolean value(Boolean value) {
if (value == null)
return false;
else return value;
}
}

@ -17,6 +17,9 @@
<if test=" udiCode!= '' and udiCode != null">
and io.udiCode = #{udiCode}
</if>
<if test=" relIdFk!= '' and relIdFk != null">
and b1.nameCode = #{relIdFk}
</if>
<if test=" mark!= '' and mark != null">
and io.mark = #{mark}
</if>
@ -43,7 +46,7 @@
'%Y-%m-%d') and date_format(#{endDate}, '%Y-%m-%d')
</if>
</where>
GROUP BY io.orderIdFk
GROUP BY io.id
</select>
</mapper>

Loading…
Cancel
Save