add column active mail
This commit is contained in:
parent
3e45ad224d
commit
e3dbd0b5d1
@ -39,6 +39,8 @@ public class UsersEntity extends PanacheEntityBase {
|
|||||||
public LocalDate birth;
|
public LocalDate birth;
|
||||||
@ColumnDefault("false")
|
@ColumnDefault("false")
|
||||||
public Boolean status;
|
public Boolean status;
|
||||||
|
@ColumnDefault("false")
|
||||||
|
public Boolean active_mail;
|
||||||
@Column(nullable = false)
|
@Column(nullable = false)
|
||||||
public String password;
|
public String password;
|
||||||
@Column(nullable = false)
|
@Column(nullable = false)
|
||||||
|
@ -150,6 +150,7 @@ public class UsersRessources {
|
|||||||
.encryptSHA512(Base64.toBase64String(users.password.getBytes(StandardCharsets.UTF_8)));
|
.encryptSHA512(Base64.toBase64String(users.password.getBytes(StandardCharsets.UTF_8)));
|
||||||
usersNew.roles = users.roles;
|
usersNew.roles = users.roles;
|
||||||
usersNew.status = false;
|
usersNew.status = false;
|
||||||
|
usersNew.active_mail = true;
|
||||||
usersNew.persist();
|
usersNew.persist();
|
||||||
if (usersNew.isPersistent()) {
|
if (usersNew.isPersistent()) {
|
||||||
status = Response.Status.CREATED;
|
status = Response.Status.CREATED;
|
||||||
@ -264,7 +265,6 @@ public class UsersRessources {
|
|||||||
status = Response.Status.NOT_MODIFIED;
|
status = Response.Status.NOT_MODIFIED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return Response.status(status).build();
|
return Response.status(status).build();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user