phpcjl
2024-12-13 fab078bcf99eeef5813a9c797147eb2dc18434d4
1.后台管理-评论
2.后台管理-门店特殊价
3个文件已修改
1个文件已添加
66 ■■■■■ 已修改文件
ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/model/UserPoint.java 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/UserPointController.java 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/vo/UserPointStatistics.java 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopController.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-api/ruoyi-api-account/src/main/java/com/ruoyi/account/api/model/UserPoint.java
@@ -60,5 +60,13 @@
    @TableField("object_id")
    private Long objectId;
    @ApiModelProperty(value = "用户名称")
    @TableField(exist = false)
    private String userName;
    @ApiModelProperty(value = "联系电话")
    @TableField(exist = false)
    private String phone;
}
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/controller/UserPointController.java
@@ -1,9 +1,12 @@
package com.ruoyi.account.controller;
import com.ruoyi.account.api.model.AppUser;
import com.ruoyi.account.api.model.UserPoint;
import com.ruoyi.account.service.AppUserService;
import com.ruoyi.account.service.UserPointService;
import com.ruoyi.account.vo.UserPointDetailVO;
import com.ruoyi.account.vo.UserPointStatistics;
import com.ruoyi.account.vo.UserPointVO;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.common.core.web.controller.BaseController;
@@ -12,6 +15,7 @@
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import io.swagger.models.auth.In;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.*;
@@ -37,6 +41,8 @@
public class UserPointController extends BaseController {
    @Resource
    private UserPointService userPointService;
    @Resource
    private AppUserService appUserService;
    /**
@@ -98,5 +104,23 @@
        userPointService.save(userPoint);
        return R.ok();
    }
    /**
     * 积分统计
     */
    @GetMapping("/statistics")
    public R<UserPointStatistics> statistics(UserPoint userPoint) {
        List<AppUser> appUserList = appUserService.list();
        Integer totalPoint = 0;
        Integer consumePoint = 0;
        Integer sharePoint = 0;
        List<UserPoint> userPointList = userPointService.list();
        UserPointStatistics userPointStatistics = new UserPointStatistics();
        userPointStatistics.setTotalPoint(totalPoint);
        userPointStatistics.setConsumePoint(consumePoint);
        userPointStatistics.setSharePoint(sharePoint);
        return null;
    }
}
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/vo/UserPointStatistics.java
New file
@@ -0,0 +1,32 @@
package com.ruoyi.account.vo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
@Data
@Api("积分统计")
public class UserPointStatistics {
    @ApiModelProperty(value = "总积分")
    private Integer totalPoint;
    @ApiModelProperty(value = "消费积分总数")
    private Integer consumePoint;
    @ApiModelProperty(value = "返佣积分总数")
    private Integer sharePoint;
    @ApiModelProperty(value = "拉新人积分总数")
    private Integer pullNewPoint;
    @ApiModelProperty(value = "注册积分总数")
    private Integer registerPoint;
    @ApiModelProperty(value = "做工积分总数")
    private Integer workPoint;
    @ApiModelProperty(value = "技师业绩积分总数")
    private Integer shopAchievementPoint;
}
ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/ShopController.java
@@ -107,7 +107,7 @@
    }
    @PutMapping("/editShop")
    @ApiOperation(value = "门店管理-编辑门店", tags = {"管理后台"})
    @ApiOperation(value = "门店管理-编辑门店", tags = {"管理后台-门店管理"})
    public R<Void> editShop(@RequestBody Shop shop){
        shopService.updateById(shop);
        return R.ok();