|
@@ -12,17 +12,15 @@ import java.sql.Timestamp;
|
|
|
*/
|
|
|
@Data
|
|
|
public class EnterpriseAuthentication {
|
|
|
-
|
|
|
private Long id;
|
|
|
private Long userId;
|
|
|
- private String sex;
|
|
|
- private String IDCardPositivePhoto;//身份证正面照片
|
|
|
- private String IDCardBackPhoto;//身份证反面
|
|
|
+ private String IDCardNum;//身份证号码
|
|
|
private String legalPersonName;
|
|
|
private String businessLicensePhoto;
|
|
|
private String unifiedSocialCreditCode;
|
|
|
-
|
|
|
- private String address;
|
|
|
+ private String sex;//2.0新加性别
|
|
|
+ private String IDcardPositivePhoto;//身份证正面照
|
|
|
+ private String IDCardBackPhoto;//身份证反面照
|
|
|
private int isDeleted;
|
|
|
private int isAuthentication;
|
|
|
private String explain;
|
|
@@ -34,12 +32,9 @@ public class EnterpriseAuthentication {
|
|
|
return "CompanyAuth{" +
|
|
|
"id=" + id +
|
|
|
", userId=" + userId +
|
|
|
-
|
|
|
", legalPersonName='" + legalPersonName + '\'' +
|
|
|
", businessLicensePhoto='" + businessLicensePhoto + '\'' +
|
|
|
", unifiedSocialCreditCode='" + unifiedSocialCreditCode + '\'' +
|
|
|
-
|
|
|
- ", address='" + address + '\'' +
|
|
|
", isDeleted=" + isDeleted +
|
|
|
", isAuthentication=" + isAuthentication +
|
|
|
", explain=" + explain +
|
|
@@ -59,11 +54,11 @@ public class EnterpriseAuthentication {
|
|
|
}
|
|
|
|
|
|
public EnterpriseAuthentication passAuthentication() {
|
|
|
- if (this.getIsAuthentication() == AuthenticationStatus.isNotAuthenticated) {
|
|
|
+ if(this.getIsAuthentication() == AuthenticationStatus.isNotAuthenticated){
|
|
|
throw new BaseException("当前是未通过认证状态,不可通过认证,需对认证信息进行修改后再提交认证申请");
|
|
|
- } else if (this.getIsAuthentication() == AuthenticationStatus.isAuthenticated) {
|
|
|
+ }else if(this.getIsAuthentication() == AuthenticationStatus.isAuthenticated){
|
|
|
throw new BaseException("当前已通过认证,不可再次进行认证");
|
|
|
- } else {
|
|
|
+ }else{
|
|
|
this.setIsAuthentication(AuthenticationStatus.isAuthenticated);
|
|
|
this.setCheckTime(new Timestamp(System.currentTimeMillis()));
|
|
|
this.setExplain("");
|
|
@@ -73,14 +68,14 @@ public class EnterpriseAuthentication {
|
|
|
}
|
|
|
|
|
|
public EnterpriseAuthentication rejectAuthentication(String explain) {
|
|
|
- if (this.getIsDeleted() == DeletedStatus.isDeleted) {
|
|
|
+ if(this.getIsDeleted() == DeletedStatus.isDeleted){
|
|
|
throw new BaseException("当前认证信息已被删除,不可做认证状态改变操作");
|
|
|
- } else {
|
|
|
- if (this.getIsAuthentication() == AuthenticationStatus.isNotAuthenticated) {
|
|
|
+ }else {
|
|
|
+ if(this.getIsAuthentication() == AuthenticationStatus.isNotAuthenticated){
|
|
|
throw new BaseException("当前已是未通过认证状态,不可再次拒绝认证");
|
|
|
- } else if (this.getIsAuthentication() == AuthenticationStatus.isAuthenticated) {
|
|
|
+ }else if(this.getIsAuthentication() == AuthenticationStatus.isAuthenticated){
|
|
|
throw new BaseException("当前已通过认证,不可拒绝认证");
|
|
|
- } else {
|
|
|
+ }else {
|
|
|
this.setIsAuthentication(AuthenticationStatus.isNotAuthenticated);
|
|
|
this.setExplain(explain);
|
|
|
this.setCheckTime(new Timestamp(System.currentTimeMillis()));
|
|
@@ -92,7 +87,7 @@ public class EnterpriseAuthentication {
|
|
|
public EnterpriseAuthentication updateAuthInfo(EnterpriseAuthentication modifyAuth) {
|
|
|
modifyAuth.userId = this.userId;
|
|
|
modifyAuth.id = this.id;
|
|
|
- BeanUtils.copyProperties(modifyAuth, this);
|
|
|
+ BeanUtils.copyProperties(modifyAuth,this);
|
|
|
this.setIsAuthentication(AuthenticationStatus.isAuthenIng);
|
|
|
this.setIsDeleted(DeletedStatus.isNotDeleted);
|
|
|
this.setApplyTime(new Timestamp(System.currentTimeMillis()));
|