用户更改
This commit is contained in:
parent
309ee07859
commit
4cb02390ed
|
|
@ -5,6 +5,7 @@ import com.bonus.canteen.core.android.mapper.UserMapper;
|
||||||
import com.bonus.canteen.core.android.service.UserService;
|
import com.bonus.canteen.core.android.service.UserService;
|
||||||
import com.bonus.canteen.core.android.vo.UserInfoVo;
|
import com.bonus.canteen.core.android.vo.UserInfoVo;
|
||||||
import com.bonus.common.core.web.domain.AjaxResult;
|
import com.bonus.common.core.web.domain.AjaxResult;
|
||||||
|
import com.bonus.common.houqin.utils.SM4EncryptUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
|
@ -26,6 +27,9 @@ public class UserServiceImpl implements UserService {
|
||||||
List<UserInfoVo> moneyList = mapper.getMoneyList();
|
List<UserInfoVo> moneyList = mapper.getMoneyList();
|
||||||
if (!list.isEmpty()){
|
if (!list.isEmpty()){
|
||||||
list.forEach(userInfoVo -> {
|
list.forEach(userInfoVo -> {
|
||||||
|
if (userInfoVo.getPhone().length() != 11){
|
||||||
|
userInfoVo.setPhone(SM4EncryptUtils.sm4Decrypt(userInfoVo.getPhone()));
|
||||||
|
}
|
||||||
UserInfoVo money = moneyList.stream().filter(moneyVo -> moneyVo.getUserId().equals(userInfoVo.getUserId())).findFirst().orElse(null);
|
UserInfoVo money = moneyList.stream().filter(moneyVo -> moneyVo.getUserId().equals(userInfoVo.getUserId())).findFirst().orElse(null);
|
||||||
if (money != null){
|
if (money != null){
|
||||||
userInfoVo.setPersonalWalletBalance(money.getPersonalWalletBalance());
|
userInfoVo.setPersonalWalletBalance(money.getPersonalWalletBalance());
|
||||||
|
|
@ -38,4 +42,5 @@ public class UserServiceImpl implements UserService {
|
||||||
}
|
}
|
||||||
return AjaxResult.success(list);
|
return AjaxResult.success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,10 @@ public class UserInfoVo {
|
||||||
|
|
||||||
private String userName;
|
private String userName;
|
||||||
|
|
||||||
|
private String phone;
|
||||||
|
|
||||||
|
private String loginType;
|
||||||
|
|
||||||
private String accId;
|
private String accId;
|
||||||
/**
|
/**
|
||||||
* 卡号
|
* 卡号
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
ac.acc_id as accId,
|
ac.acc_id as accId,
|
||||||
ac.card_num as cardNum,
|
ac.card_num as cardNum,
|
||||||
ac.serial_num as serialNum,
|
ac.serial_num as serialNum,
|
||||||
ai.acc_status as accStatus
|
ai.acc_status as accStatus,
|
||||||
|
su.phone as phone,
|
||||||
|
su.login_type as loginType
|
||||||
from sys_user su
|
from sys_user su
|
||||||
left join acc_card ac on ac.user_id = su.user_id
|
left join acc_card ac on ac.user_id = su.user_id
|
||||||
left join acc_info ai on ai.user_id = su.user_id
|
left join acc_info ai on ai.user_id = su.user_id
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue