Commit e699c3d7 authored by 李健华's avatar 李健华

productLogin和wechatUserInfo获取手机号方式

parent 991fd783
......@@ -99,7 +99,7 @@ public class ProductLoginEntity extends PartitionEntity implements Serializable
}
public String getPhoneNo() {
return this.getEncryptedPhoneNo();
return getEncryptedPhoneNo();
}
public void setPhoneNo(String phoneNo) {
......@@ -205,7 +205,7 @@ public class ProductLoginEntity extends PartitionEntity implements Serializable
}
public String getEncryptedPhoneNo() {
return encryptedPhoneNo == null ? phoneNo : encryptedPhoneNo;
return org.apache.commons.lang.StringUtils.isBlank(encryptedPhoneNo) ? phoneNo : encryptedPhoneNo;
}
public void setEncryptedPhoneNo(String encryptedPhoneNo) {
......
......@@ -3,6 +3,7 @@ package cn.quantgroup.xyqb.entity;
import cn.quantgroup.xyqb.entity.converter.EncryptConverter;
import cn.quantgroup.xyqb.util.EmojiUtil;
import lombok.Data;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.BeanUtils;
import javax.persistence.*;
......@@ -50,6 +51,14 @@ public class WechatUserInfo extends BaseEntity implements Serializable {
@Convert(converter = EncryptConverter.class)
private String encryptedPhoneNo;
public String getEncryptedPhoneNo() {
return StringUtils.isBlank(encryptedPhoneNo) ? phoneNo : encryptedPhoneNo;
}
public String getPhoneNo() {
return StringUtils.isBlank(encryptedPhoneNo) ? phoneNo : encryptedPhoneNo;
}
public WechatUserInfo convertEmoji() {
WechatUserInfo wechatUserInfo = new WechatUserInfo();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment