Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/Add field 'Social network' to user's profile #325

Merged
merged 1 commit into from
Jun 1, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/main/java/com/softserveinc/dokazovi/dto/user/UserDTO.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ public class UserDTO {

private String bio;

private String socialNetwork;

private Set<DirectionDTO> directions;

private UserInstitutionDTO mainInstitution;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ public class DoctorEntity {
@Column(columnDefinition = "TEXT")
private String bio;

@Column(columnDefinition = "TEXT")
private String socialNetwork;

@ColumnDefault("1.0")
private Double promotionScale;

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ALTER TABLE DOCTORS
ADD COLUMN SOCIAL_NETWORK VARCHAR DEFAULT '';
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
UPDATE DOCTORS SET SOCIAL_NETWORK='https://www.instagram.com' WHERE DOCTOR_ID>=1 AND DOCTOR_ID<9;
UPDATE DOCTORS SET SOCIAL_NETWORK='https://www.linkedin.com/' WHERE DOCTOR_ID>8 AND DOCTOR_ID<15;
UPDATE DOCTORS SET SOCIAL_NETWORK='https://www.facebook.com' WHERE DOCTOR_ID>14 AND DOCTOR_ID<27;
UPDATE DOCTORS SET SOCIAL_NETWORK='https://www.youtube.com' WHERE DOCTOR_ID>26 AND DOCTOR_ID<=36;