luodangjia
2025-02-08 69f4e7bafd3d81696aa00affd6b9ddfa6b50503f
ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopController.java
@@ -823,8 +823,12 @@
    @GetMapping("/getShopStatistics")
    public R<Map<String, BigDecimal> > getShopStatistics(){
        List<Shop> shopList = shopService.list();
    public R<Map<String, BigDecimal> > getShopStatistics(@RequestParam("shopId") Integer shopId){
        LambdaQueryWrapper<Shop> queryWrapper = new LambdaQueryWrapper<Shop>().eq(Shop::getDelFlag, 0).eq(Shop::getStatus, 1);
        if(null != shopId && 0 != shopId){
            queryWrapper.eq(Shop::getId, shopId);
        }
        List<Shop> shopList = shopService.list(queryWrapper);
        BigDecimal serverGiveawayMoney = BigDecimal.ZERO;
        BigDecimal giveawayMoney = BigDecimal.ZERO;
        for (Shop shop : shopList) {