添加前端传递数据校验
This commit is contained in:
parent
90501ccfb1
commit
7214d9d4fc
|
|
@ -120,16 +120,11 @@ public class TbProskuConServiceImpl implements TbProskuConService {
|
|||
throw new BadRequestException("对应的耗材信息不存在");
|
||||
}
|
||||
|
||||
|
||||
|
||||
TbProductSku tbProductSku= tbProductSkuRepository.findById(skuInfo.getSkuId()).orElseGet(TbProductSku::new);
|
||||
if(ObjectUtil.isNull(tbProductSku)||ObjectUtil.isNull(tbProductSku.getId())){
|
||||
throw new BadRequestException("规格信息不存在");
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
int count=tbProskuConRepository.countByConInfoIdAndProductSkuIdAndShopId(resource.getConsInfoId(), skuInfo.getSkuId(), skuInfo.getShopId(), resource.getProductId());
|
||||
if(count<=0){
|
||||
TbProskuCon tbProskuCon=new TbProskuCon();
|
||||
|
|
|
|||
Loading…
Reference in New Issue