Browse Source

feat: 用户余额

xdd 1 month ago
parent
commit
66388a902f

+ 6 - 580
fs-service/src/main/java/com/fs/hisStore/domain/FsUserScrm.java

@@ -7,6 +7,7 @@ import com.fs.common.annotation.Excel;
 import com.fs.common.core.domain.BaseEntity;
 import com.vdurmont.emoji.EmojiParser;
 import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
 import org.apache.commons.lang3.StringUtils;
 
 import java.math.BigDecimal;
@@ -18,6 +19,7 @@ import java.util.Date;
  * @author fs
  * @date 2022-03-15
  */
+@Data
 @TableName("fs_user")
 public class FsUserScrm extends BaseEntity
 {
@@ -218,13 +220,6 @@ public class FsUserScrm extends BaseEntity
      */
     private Long projectId;
 
-    public Long getProjectId() {
-        return projectId;
-    }
-
-    public void setProjectId(Long projectId) {
-        this.projectId = projectId;
-    }
 
     // 是否已购0 否 1程序内下单 2程序外下单
     private Integer payOrder;
@@ -233,577 +228,8 @@ public class FsUserScrm extends BaseEntity
     @Excel(name = "是否点过注册链接 0:否 1:是")
     private Integer isBecomeMember;
 
-    public String getRank() {
-        return rank;
-    }
-
-    public FsUserScrm setRank(String rank) {
-        this.rank = rank;
-        return this;
-    }
-
-    public String getReact() {
-        return react;
-    }
-
-    public FsUserScrm setReact(String react) {
-        this.react = react;
-        return this;
-    }
-
-    public Integer getPayOrder() {
-        return payOrder;
-    }
-
-    public void setPayOrder(Integer payOrder) {
-        this.payOrder = payOrder;
-    }
-
-    public Long getQwExtId() {
-        return qwExtId;
-    }
-
-    public void setQwExtId(Long qwExtId) {
-        this.qwExtId = qwExtId;
-    }
-
-    public String getCourseMaOpenId() {
-        return courseMaOpenId;
-    }
-
-    public void setCourseMaOpenId(String courseMaOpenId) {
-        this.courseMaOpenId = courseMaOpenId;
-    }
-    public String getStatusText() {
-        return statusText;
-    }
-
-    public void setStatusText(String statusText) {
-        this.statusText = statusText;
-    }
-
-    public String getCompanyUserName() {
-        return companyUserName;
-    }
-
-    public void setCompanyUserName(String companyUserName) {
-        this.companyUserName = companyUserName;
-    }
-    public Integer getIsAddQw() {
-        return isAddQw;
-    }
-
-    public void setIsAddQw(Integer isAddQw) {
-        this.isAddQw = isAddQw;
-    }
-
-    public Integer getIsShow() {
-        return isShow;
-    }
-
-    public void setIsShow(Integer isShow) {
-        this.isShow = isShow;
-    }
-
-    public String getPassword() {
-        return password;
-    }
-
-    public Long getBirthday() {
-        return birthday;
-    }
-
-    public FsUserScrm setBirthday(Long birthday) {
-        this.birthday = birthday;
-        return this;
-    }
-
-    public String getIdCard() {
-        return idCard;
-    }
-
-    public FsUserScrm setIdCard(String idCard) {
-        this.idCard = idCard;
-        return this;
-    }
-
-    @Override
-    public String getRemark() {
-        return remark;
-    }
-
-    public String getTuiUserId() {
-        return tuiUserId;
-    }
-
-    public FsUserScrm setTuiUserId(String tuiUserId) {
-        this.tuiUserId = tuiUserId;
-        return this;
-    }
-
-    public Date getSpreadTime() {
-        return spreadTime;
-    }
-
-    public FsUserScrm setSpreadTime(Date spreadTime) {
-        this.spreadTime = spreadTime;
-        return this;
-    }
-
-    public Date getTuiTime() {
-        return tuiTime;
-    }
-
-    public FsUserScrm setTuiTime(Date tuiTime) {
-        this.tuiTime = tuiTime;
-        return this;
-    }
-
-    public String getUserType() {
-        return userType;
-    }
-
-    public FsUserScrm setUserType(String userType) {
-        this.userType = userType;
-        return this;
-    }
-
-    public Long getPayCount() {
-        return payCount;
-    }
-
-    public FsUserScrm setPayCount(Long payCount) {
-        this.payCount = payCount;
-        return this;
-    }
-
-    public Long getSpreadCount() {
-        return spreadCount;
-    }
-
-    public FsUserScrm setSpreadCount(Long spreadCount) {
-        this.spreadCount = spreadCount;
-        return this;
-    }
-
-    public String getAddres() {
-        return addres;
-    }
-
-    public FsUserScrm setAddres(String addres) {
-        this.addres = addres;
-        return this;
-    }
-
-    public Long getTuiUserCount() {
-        return tuiUserCount;
-    }
-
-    public FsUserScrm setTuiUserCount(Long tuiUserCount) {
-        this.tuiUserCount = tuiUserCount;
-        return this;
-    }
-
-    public Integer getIsDel() {
-        return isDel;
-    }
-
-    public FsUserScrm setIsDel(Integer isDel) {
-        this.isDel = isDel;
-        return this;
-    }
-
-    public BigDecimal getBalance() {
-        return balance;
-    }
-
-    public FsUserScrm setBalance(BigDecimal balance) {
-        this.balance = balance;
-        return this;
-    }
-
-    public Integer getIntegralStatus() {
-        return integralStatus;
-    }
-
-    public FsUserScrm setIntegralStatus(Integer integralStatus) {
-        this.integralStatus = integralStatus;
-        return this;
-    }
-
-    public Integer getIsBuy() {
-        return isBuy;
-    }
-
-    public FsUserScrm setIsBuy(Integer isBuy) {
-        this.isBuy = isBuy;
-        return this;
-    }
-
-    public String getStoreOpenId() {
-        return storeOpenId;
-    }
-
-    public FsUserScrm setStoreOpenId(String storeOpenId) {
-        this.storeOpenId = storeOpenId;
-        return this;
-    }
-
-    public Integer getIsOfficialAccountAuth() {
-        return isOfficialAccountAuth;
-    }
-
-    public FsUserScrm setIsOfficialAccountAuth(Integer isOfficialAccountAuth) {
-        this.isOfficialAccountAuth = isOfficialAccountAuth;
-        return this;
-    }
-
-    public Integer getIsPush() {
-        return isPush;
-    }
-
-    public FsUserScrm setIsPush(Integer isPush) {
-        this.isPush = isPush;
-        return this;
-    }
-
-    public Integer getIsIndividuationPush() {
-        return isIndividuationPush;
-    }
-
-    public FsUserScrm setIsIndividuationPush(Integer isIndividuationPush) {
-        this.isIndividuationPush = isIndividuationPush;
-        return this;
-    }
-
-    public String getLoginDevice() {
-        return loginDevice;
-    }
-
-    public FsUserScrm setLoginDevice(String loginDevice) {
-        this.loginDevice = loginDevice;
-        return this;
-    }
-
-    public Long getParentId() {
-        return parentId;
-    }
-
-    public FsUserScrm setParentId(Long parentId) {
-        this.parentId = parentId;
-        return this;
-    }
-
-    public Long getQwUserId() {
-        return qwUserId;
-    }
-
-    public FsUserScrm setQwUserId(Long qwUserId) {
-        this.qwUserId = qwUserId;
-        return this;
-    }
-
-    public Date getStartCreateTime() {
-        return startCreateTime;
-    }
-
-    public FsUserScrm setStartCreateTime(Date startCreateTime) {
-        this.startCreateTime = startCreateTime;
-        return this;
-    }
-
-    public Date getEndCreateTime() {
-        return endCreateTime;
-    }
-
-    public FsUserScrm setEndCreateTime(Date endCreateTime) {
-        this.endCreateTime = endCreateTime;
-        return this;
-    }
-
-    public Integer getIsBecomeMember() {
-        return isBecomeMember;
-    }
-
-    public FsUserScrm setIsBecomeMember(Integer isBecomeMember) {
-        this.isBecomeMember = isBecomeMember;
-        return this;
-    }
-
-    public String getUsername() {
-        return username;
-    }
-
-    public FsUserScrm setPassword(String password) {
-        this.password = password;
-        return this;
-    }
-
-    public String getJpushId() {
-        return jpushId;
-    }
-
-    public void setJpushId(String jpushId) {
-        this.jpushId = jpushId;
-    }
-
-    public Integer getSex() {
-        return sex;
-    }
-
-    public void setSex(Integer sex) {
-        this.sex = sex;
-    }
-
-    public Integer getIsVip() {
-        return isVip;
-    }
-
-    public void setIsVip(Integer isVip) {
-        this.isVip = isVip;
-    }
-
-    public Date getVipEndDate() {
-        return vipEndDate;
-    }
-
-    public void setVipEndDate(Date vipEndDate) {
-        this.vipEndDate = vipEndDate;
-    }
-
-    public BigDecimal getNowMoney() {
-        return nowMoney;
-    }
-
-    public String getRealName() {
-        return realName;
-    }
-
-    public FsUserScrm setRealName(String realName) {
-        this.realName = realName;
-        return this;
-    }
-
-    public String getLastIp() {
-        return lastIp;
-    }
-
-    public FsUserScrm setLastIp(String lastIp) {
-        this.lastIp = lastIp;
-        return this;
-    }
-
-    public String getAvatar() {
-        return avatar;
-    }
-
-    public FsUserScrm setAvatar(String avatar) {
-        this.avatar = avatar;
-        return this;
-    }
-
-    public Long getSignNum() {
-        return signNum;
-    }
-
-    public FsUserScrm setSignNum(Long signNum) {
-        this.signNum = signNum;
-        return this;
-    }
-
-    public String getPhone() {
-        return phone;
-    }
-
-    public FsUserScrm setPhone(String phone) {
-        this.phone = phone;
-        return this;
-    }
-
-    public Long getIntegral() {
-        return integral;
-    }
-
-    public FsUserScrm setIntegral(Long integral) {
-        this.integral = integral;
-        return this;
-    }
-
-    public FsUserScrm setNowMoney(BigDecimal nowMoney) {
-        this.nowMoney = nowMoney;
-        return this;
-    }
-
-    public Long getSpreadUserId() {
-        return spreadUserId;
-    }
-
-    public FsUserScrm setSpreadUserId(Long spreadUserId) {
-        this.spreadUserId = spreadUserId;
-        return this;
-    }
-
-    public Integer getIsPromoter() {
-        return isPromoter;
-    }
-
-    public FsUserScrm setIsPromoter(Integer isPromoter) {
-        this.isPromoter = isPromoter;
-        return this;
-    }
-
-    public Date getVipStartDate() {
-        return vipStartDate;
-    }
-
-    public void setVipStartDate(Date vipStartDate) {
-        this.vipStartDate = vipStartDate;
-    }
-
-    public Integer getVipLevel() {
-        return vipLevel;
-    }
-
-    public void setVipLevel(Integer vipLevel) {
-        this.vipLevel = vipLevel;
-    }
-
-    public Integer getVipStatus() {
-        return vipStatus;
-    }
-
-    public void setVipStatus(Integer vipStatus) {
-        this.vipStatus = vipStatus;
-    }
-
-    public String getUserCode() {
-        return userCode;
-    }
-
-    public void setUserCode(String userCode) {
-        this.userCode = userCode;
-    }
-
-    public String getMaOpenId() {
-        return maOpenId;
-    }
-
-    public void setMaOpenId(String maOpenId) {
-        this.maOpenId = maOpenId;
-    }
-
-    public String getMpOpenId() {
-        return mpOpenId;
-    }
-
-    public void setMpOpenId(String mpOpenId) {
-        this.mpOpenId = mpOpenId;
-    }
-
-    public String getUnionId() {
-        return unionId;
-    }
-
-    public void setUnionId(String unionId) {
-        this.unionId = unionId;
-    }
-
-    public Date getRegisterDate() {
-        return registerDate;
-    }
-
-    public void setRegisterDate(Date registerDate) {
-        this.registerDate = registerDate;
-    }
-
-    public String getRegisterCode() {
-        return registerCode;
-    }
-
-    public void setRegisterCode(String registerCode) {
-        this.registerCode = registerCode;
-    }
-
-    public String getSource() {
-        return source;
-    }
-
-    public void setSource(String source) {
-        this.source = source;
-    }
-
-    public Long getCompanyId() {
-        return companyId;
-    }
-
-    public void setCompanyId(Long companyId) {
-        this.companyId = companyId;
-    }
-
-    public Long getCompanyUserId() {
-        return companyUserId;
-    }
-
-    public void setCompanyUserId(Long companyUserId) {
-        this.companyUserId = companyUserId;
-    }
-
-    public Integer getIsWeixinAuth() {
-        return isWeixinAuth;
-    }
-
-    public void setIsWeixinAuth(Integer isWeixinAuth) {
-        this.isWeixinAuth = isWeixinAuth;
-    }
-
-    public void setUserId(Long userId)
-    {
-        this.userId = userId;
-    }
-
-    public Long getUserId()
-    {
-        return userId;
-    }
-    public void setUsername(String username)
-    {
-        this.username = username;
-    }
-
-
-    public String getNickname() {
-        return nickname;
-    }
-
-    public void setNickname(String nickname) {
-        this.nickname = nickname;
-    }
-
-    public Integer getLevel() {
-        return level;
-    }
-
-    public FsUserScrm setLevel(Integer level) {
-        this.level = level;
-        return this;
-    }
-
-    public Integer getStatus() {
-        return status;
-    }
-
-    public FsUserScrm setStatus(Integer status) {
-        this.status = status;
-        return this;
-    }
-
-    public BigDecimal getBrokeragePrice() {
-        return brokeragePrice;
-    }
-
-    public FsUserScrm setBrokeragePrice(BigDecimal brokeragePrice) {
-        this.brokeragePrice = brokeragePrice;
-        return this;
-    }
-
+    /**
+     * 用户余额
+     */
+    private BigDecimal money;
 }

+ 1 - 1
fs-service/src/main/resources/mapper/hisStore/FsUserScrmMapper.xml

@@ -72,7 +72,7 @@
     </resultMap>
 
     <sql id="selectFsUserVo">
-        select user_id, username, nick_name, avatar, phone, integral, status, `level`, spread_user_id, spread_time, user_type, is_promoter, pay_count, spread_count, addres, tui_user_id, tui_time, tui_user_count, ma_open_id, mp_open_id, union_id, is_del, user_code, remark, nickname, create_time, update_time, last_ip, now_money, brokerage_price, balance, sign_num, integral_status, is_buy, password, real_name, birthday, id_card, jpush_id, is_vip, vip_start_date, vip_end_date, vip_level, vip_status, sex, store_open_id, is_official_account_auth, is_push, is_individuation_push, is_weixin_auth, company_id, company_user_id, register_date, register_code, test, login_device, source, is_add_qw, qw_user_id, is_show, parent_id, course_ma_open_id, history_app, qw_ext_id, `rank`, react from fs_user
+        select user_id, username, nick_name, avatar, phone, integral, status, `level`, spread_user_id, spread_time, user_type, is_promoter, pay_count, spread_count, addres, tui_user_id, tui_time, tui_user_count, ma_open_id, mp_open_id, union_id, is_del, user_code, remark, nickname, create_time, update_time, last_ip, now_money, brokerage_price, balance, sign_num, integral_status, is_buy, password, real_name, birthday, id_card, jpush_id, is_vip, vip_start_date, vip_end_date, vip_level, vip_status, sex, store_open_id, is_official_account_auth, is_push, is_individuation_push, is_weixin_auth, company_id, company_user_id, register_date, register_code, test, login_device, source, is_add_qw, qw_user_id, is_show, parent_id, course_ma_open_id, history_app, qw_ext_id, `rank`, react,money from fs_user
     </sql>
 
     <select id="selectFsUserList" parameterType="FsUserScrm" resultMap="FsUserResult">

+ 3 - 3
fs-user-app/src/main/java/com/fs/app/controller/store/UserScrmController.java

@@ -164,7 +164,7 @@ public class UserScrmController extends AppBaseController {
                 log.error("未找到用户信息,用户ID: {}", userId);
                 return R.error("用户信息不存在");
             }
-            log.info("查询到用户信息: 用户ID={}, 昵称={}", userId, user.getNickname());
+            log.info("查询到用户信息: 用户ID={}, 昵称={}", userId, user.getNickName());
 
             // 确保用户有邀请码
             if(StringUtils.isEmpty(user.getUserCode())){
@@ -328,7 +328,7 @@ public class UserScrmController extends AppBaseController {
         g2d.setFont(font);
         g2d.setColor(Color.BLACK);
 
-        String nickname = StringUtils.isEmpty(user.getNickname()) ? "用户" : user.getNickname();
+        String nickname = StringUtils.isEmpty(user.getNickName()) ? "用户" : user.getNickName();
         FontMetrics fm = g2d.getFontMetrics();
 
         // 绘制邀请文本
@@ -502,7 +502,7 @@ public class UserScrmController extends AppBaseController {
         FsUserScrm user=new FsUserScrm();
         user.setUserId(Long.parseLong(getUserId()));
         user.setAvatar(param.getAvatar());
-        user.setNickname(param.getNickname());
+        user.setNickName(param.getNickname());
         if(userService.updateFsUser(user)>0){
             return R.ok("修改成功");
         }