Skip to content

Commit

Permalink
FKS-596 #comment updated user table with status fields #in-progress
Browse files Browse the repository at this point in the history
  • Loading branch information
Erling Jahr committed Jan 5, 2024
1 parent 0017434 commit 017c1d8
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public void init() {

public void publish(Member member) {
String key = member.getResourceId();
log.info("Publish member : " + member.getResourceId());
//log.info("Publish member : " + member.getResourceId());
entityProducer.send(
EntityProducerRecord.<Member>builder()
.topicNameParameters(entityTopicNameParameters)
Expand Down
5 changes: 5 additions & 0 deletions src/main/java/no/fintlabs/user/User.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import lombok.extern.slf4j.Slf4j;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.UUID;

Expand Down Expand Up @@ -55,6 +56,10 @@ public class User {
private String email;
@Column(name="managerref")
private String managerRef;
// @Column(name = "status")
// private String status;
// @Column(name = "statuschanged")
// private Date statusChanged;

public SimpleUser toSimpleUser() {
return SimpleUser
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/no/fintlabs/user/UserService.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ private Runnable onSaveNewUser(User user) {
private Consumer<User> onSaveExistingUser(User user) {
return existingUser -> {
user.setId(existingUser.getId());
log.info("Update user: " + user.getId());
//log.info("Update user: " + user.getId());
memberService.process(memberService.create(user));
User savedUser = userRepository.save(user);
log.info("update kontrollUser: " + savedUser.getIdentityProviderUserObjectId());
//log.info("update kontrollUser: " + savedUser.getIdentityProviderUserObjectId());
userEntityProducerService.publish(savedUser);
};
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
alter table users ADD status varchar(255);
alter table users ADD statuschanged timestamp;

0 comments on commit 017c1d8

Please sign in to comment.