liuleilei
2023-12-25 daccfb7928e41005e8e31073100442e1e423ea5c
server/service/src/main/java/com/doumee/service/business/impl/GoodsServiceImpl.java
@@ -793,8 +793,8 @@
            if(brand == null){
                throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对不起,第【"+(num)+"】行商品品牌无效,请检查输入!");
            }
            if(goodsMapper.selectCount(new QueryWrapper<Goods>().eq("ISDELETED",Constants.ZERO).eq("name",m.getName()))>0){
                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"第【"+(num)+"】行【"+m.getName()+"】已存在");
            if(goodsMapper.selectCount(new QueryWrapper<Goods>().eq("COMPANY_ID",user.getCompanyId()).eq("ISDELETED",Constants.ZERO).eq("name",m.getName()))>0){
                    throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"第【"+(num)+"】行【"+m.getName()+"】已存在");
            }
            Goods newModel = new Goods();
            newModel.setRemark(m.getId());