Adding more columns for users.
parent
ad5e842008
commit
3d5b27d91e
spring-showcase-web
src/main
java/ch/polgrabia/springshowcaseweb/models
resources/db/migration
|
@ -4,4 +4,3 @@
|
|||
springshowcase.flyway.url=jdbc:postgresql://localhost:5432/test
|
||||
springshowcase.flyway.username=test
|
||||
springshowcase.flyway.password=test
|
||||
springshowcase.flyway.schemas=test
|
||||
|
|
|
@ -27,5 +27,4 @@ flyway {
|
|||
url = project.ext['springshowcase.flyway.url']
|
||||
user = project.ext['springshowcase.flyway.username']
|
||||
password = project.ext['springshowcase.flyway.password']
|
||||
schemas = project.ext['springshowcase.flyway.schemas']
|
||||
}
|
||||
|
|
|
@ -13,9 +13,18 @@ public class User {
|
|||
@Column(name = "user_name")
|
||||
private String userName;
|
||||
|
||||
@Column(name = "password")
|
||||
private String password;
|
||||
|
||||
@Column(name = "first_name")
|
||||
private String firstName;
|
||||
|
||||
@Column(name = "last_name")
|
||||
private String lastName;
|
||||
|
||||
@Column(name = "email")
|
||||
private String email;
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -39,4 +48,28 @@ public class User {
|
|||
public void setFirstName(String firstName) {
|
||||
this.firstName = firstName;
|
||||
}
|
||||
|
||||
public String getPassword() {
|
||||
return password;
|
||||
}
|
||||
|
||||
public void setPassword(String password) {
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
public String getLastName() {
|
||||
return lastName;
|
||||
}
|
||||
|
||||
public void setLastName(String lastName) {
|
||||
this.lastName = lastName;
|
||||
}
|
||||
|
||||
public String getEmail() {
|
||||
return email;
|
||||
}
|
||||
|
||||
public void setEmail(String email) {
|
||||
this.email = email;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
alter table users
|
||||
add column last_name text not null default '',
|
||||
add column password varchar(256) not null default '',
|
||||
add column email text not null default ''
|
Loading…
Reference in New Issue