-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from AnnaEleeva/auth_v8(refactoring_delete_com…
…ments) удалены комментарии
- Loading branch information
Showing
14 changed files
with
66 additions
and
114 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
backend/auth/src/main/java/ru/naumen/ectmauth/entity/Provider.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
package ru.naumen.ectmauth.entity; | ||
|
||
public enum Provider { | ||
LOCAL, FACEBOOK, VK | ||
LOCAL, FACEBOOK, VK | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,16 +10,16 @@ | |
import org.hibernate.annotations.CreationTimestamp; | ||
|
||
@Entity | ||
@Table(name="users") | ||
@Table(name = "users") | ||
public class User { | ||
|
||
@Id | ||
@Column(name="user_id") | ||
@Column(name = "user_id") | ||
@GeneratedValue(strategy = GenerationType.IDENTITY) | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY) | ||
private Long user_id; | ||
@CreationTimestamp | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY,description = "Дата создания пользователя") | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY, description = "Дата создания пользователя") | ||
private Date created; | ||
@Schema(description = "Почта", example = "[email protected]") | ||
private String email; | ||
|
@@ -33,17 +33,16 @@ public class User { | |
private String phone; | ||
|
||
@Enumerated(EnumType.STRING) | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY,description = "Провайдер", example = "VK") | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY, description = "Провайдер", example = "VK") | ||
private Provider provider; | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY) | ||
private boolean enabled; | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY,description = "Идентификатор пользователя Вконтакте") | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY, description = "Идентификатор пользователя Вконтакте") | ||
private String vk_id; | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY,description = "Идентификатор пользователя Вконтакте") | ||
@Schema(accessMode = Schema.AccessMode.READ_ONLY, description = "Идентификатор пользователя Вконтакте") | ||
private String fb_id; | ||
|
||
|
||
|
||
@Schema(accessMode = Schema.AccessMode.READ_ONLY) | ||
@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER) | ||
@JoinTable( | ||
|
@@ -66,7 +65,6 @@ public void setTokens(Set<Token> tokens) { | |
} | ||
|
||
|
||
|
||
public Long getUser_id() { | ||
return user_id; | ||
} | ||
|
@@ -107,9 +105,10 @@ public void setPassword(String password) { | |
this.password = password; | ||
} | ||
|
||
public String getPhone() { | ||
public String getPhone() { | ||
return phone; | ||
} | ||
|
||
public void setPhone(String phone) { | ||
this.phone = phone; | ||
} | ||
|
@@ -146,11 +145,19 @@ public void setProvider(Provider provider) { | |
this.provider = provider; | ||
} | ||
|
||
public String getVk_id() { return vk_id; } | ||
public String getVk_id() { | ||
return vk_id; | ||
} | ||
|
||
public void setVk_id(String vk_id) { this.vk_id = vk_id; } | ||
public void setVk_id(String vk_id) { | ||
this.vk_id = vk_id; | ||
} | ||
|
||
public String getFb_id() { return fb_id; } | ||
public String getFb_id() { | ||
return fb_id; | ||
} | ||
|
||
public void setFb_id(String fb_id) { this.fb_id = fb_id; } | ||
public void setFb_id(String fb_id) { | ||
this.fb_id = fb_id; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.