Skip to content
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
1 change: 0 additions & 1 deletion src/main/java/tw/kits/voicein/model/User.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ public class User {
private String profile;
@NotNull
private String company;
@NotNull
private String profilePhotoId;
private String qrCodeUuid;
@NotNull
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,12 @@ public Response getUserAccount(@PathParam("uuid") String uuid) {
@Consumes(MediaType.APPLICATION_JSON)
@TokenRequired
public Response updateUserAccount(@PathParam("uuid") String uuid, @Valid User u) {
User modifiedUser = dsObj.get(User.class, uuid);

u.setUuid(uuid);
u.setProfilePhotoId(modifiedUser.getProfilePhotoId());
u.setQrCodeUuid(modifiedUser.getQrCodeUuid());

dsObj.save(u);

LOGGER.setLevel(Level.ALL);
Expand Down Expand Up @@ -207,6 +212,9 @@ public Response updateAcontactOfAnUser(@PathParam("uuid") String uuid, @PathPara

contact.setId(modifiedContact.getId());
contact.setQrCodeUuid(qrCodeUuid);
contact.setCustomerIcon(modifiedContact.getCustomerIcon());
contact.setProviderUser(modifiedContact.getProviderUser());
contact.setUser(u);

dsObj.save(contact);
return Response.ok().build();
Expand Down