ソースを参照

元宇宙玩家登陆校验

sunkean 3 年 前
コミット
b776e99164

+ 1 - 1
src/main/java/com/izouma/nineth/domain/MetaUser.java

@@ -18,7 +18,7 @@ public class MetaUser extends BaseEntityNoID {
 
     @ApiModelProperty("用户手机号")
     @Id
-    private String phone;
+    private Long phone;
 
     @ApiModelProperty("是否允许登陆")
     private boolean allowLogin;

+ 1 - 1
src/main/java/com/izouma/nineth/repo/MetaUserRepo.java

@@ -6,5 +6,5 @@ import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
 
 public interface MetaUserRepo extends JpaRepository<MetaUser, Long>, JpaSpecificationExecutor<MetaUser> {
 
-    MetaUser findByPhone(String phone);
+    MetaUser findByPhone(Long phone);
 }

+ 1 - 1
src/main/java/com/izouma/nineth/web/MetaPlayerInfoController.java

@@ -72,7 +72,7 @@ public class MetaPlayerInfoController {
     }
 
     @GetMapping("/{phone}/allowLogin")
-    public MetaRestResult<Boolean> allowLogin(@PathVariable String phone) {
+    public MetaRestResult<Boolean> allowLogin(@PathVariable Long phone) {
         MetaUser metaUser = metaUserRepo.findByPhone(phone);
         if (Objects.isNull(metaUser)) {
             return MetaRestResult.returnSuccess(Boolean.FALSE);