|
|
|
@ -48,7 +48,7 @@ public class InvProductService extends ServiceImpl<InvProductDao, InvProductEnti
|
|
|
|
|
return invProductDao.selectOne(new QueryWrapper<InvProductEntity>().eq("relIdFk", relId)
|
|
|
|
|
.eq(StrUtil.isNotBlank(batchNo), "batchNo", batchNo).isNull(StrUtil.isEmpty(batchNo), "batchNo")
|
|
|
|
|
.eq("supId", supId)
|
|
|
|
|
.eq(StrUtil.isNotBlank(deptCode),"deptCode", deptCode)
|
|
|
|
|
.eq(StrUtil.isNotBlank(deptCode), "deptCode", deptCode)
|
|
|
|
|
.eq("invCode", invCode)
|
|
|
|
|
.eq(price != null, "price", price).isNull(price == null, "price").last("limit 1")
|
|
|
|
|
);
|
|
|
|
@ -62,6 +62,15 @@ public class InvProductService extends ServiceImpl<InvProductDao, InvProductEnti
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public List<InvProductEntity> selectByBatchNo(Long relId, String supId, String deptCode, String invCode, String batchNo) {
|
|
|
|
|
return invProductDao.selectList(new QueryWrapper<InvProductEntity>().eq("relIdFk", relId)
|
|
|
|
|
.eq("supId", supId)
|
|
|
|
|
.eq(StrUtil.isNotEmpty(deptCode), "deptCode", deptCode)
|
|
|
|
|
.eq(StrUtil.isNotEmpty(batchNo), "batchNo", batchNo)
|
|
|
|
|
.eq("invCode", invCode).gt("reCount", 0).orderByAsc("inBatchNo")
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public InvProductEntity selectByUnique(Long relId, String batchNo, String supId) {
|
|
|
|
|
return invProductDao.selectOne(new QueryWrapper<InvProductEntity>().eq("relIdFk", relId).eq(StrUtil.isNotEmpty(batchNo), "batchNo", batchNo)
|
|
|
|
|