huliguo
2025-04-08 07de03ccae02d00be243911a003115fe9b24f863
ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/service/impl/GoodsServiceImpl.java
@@ -258,7 +258,7 @@
    @Override
    @Transactional(rollbackFor = Exception.class)
    public void addGoods(Goods goods) {
        goods.setSaleNum(0);
       /* goods.setSaleNum(0);
        goods.setStatus(GoodsStatus.DOWN.getCode());
        goodsMapper.insert(goods);
@@ -270,18 +270,18 @@
                throw new NullPointerException("请选择指定门店");
            }
            saveGoodsShopList(goodsShopList, goods.getId());
        }
        }*/
    }
    @Override
    public void updateManageGoods(Goods goods) {
        this.updateById(goods);
       /* this.updateById(goods);
        //修改个别字段
        this.update(new LambdaUpdateWrapper<Goods>().eq(Goods::getId, goods.getId()).set(Goods::getSellingPrice, goods.getSellingPrice())
                .set(Goods::getIntegral, goods.getIntegral()));
        // 指定门店
        List<GoodsShop> goodsShopList = goods.getGoodsShopList();
        saveGoodsShopList(goodsShopList, goods.getId());
        saveGoodsShopList(goodsShopList, goods.getId());*/
    }
@@ -322,7 +322,7 @@
                goodsShop.setAddress(shop.getAddress());
            }
        }
        goods.setGoodsShopList(goodsShops);
//        goods.setGoodsShopList(goodsShops);
        return goods;
    }