From fb769c2d96513a5e7111e195b1b7b3d5d61e8bbb Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Fri, 24 Jan 2020 18:20:18 +0100 Subject: Rename OpenIds => OpenId. Change-Id: I5d6f1764b07a56a22c883a566e31d2af0abc5736 --- .../java/eu/mulk/mulkcms2/benki/users/OpenId.java | 21 +++++++++++++++++++++ .../java/eu/mulk/mulkcms2/benki/users/Openids.java | 21 --------------------- .../java/eu/mulk/mulkcms2/benki/users/User.java | 2 +- .../java/eu/mulk/mulkcms2/cms/users/OpenId.java | 2 +- 4 files changed, 23 insertions(+), 23 deletions(-) create mode 100644 src/main/java/eu/mulk/mulkcms2/benki/users/OpenId.java delete mode 100644 src/main/java/eu/mulk/mulkcms2/benki/users/Openids.java diff --git a/src/main/java/eu/mulk/mulkcms2/benki/users/OpenId.java b/src/main/java/eu/mulk/mulkcms2/benki/users/OpenId.java new file mode 100644 index 0000000..fe2c905 --- /dev/null +++ b/src/main/java/eu/mulk/mulkcms2/benki/users/OpenId.java @@ -0,0 +1,21 @@ +package eu.mulk.mulkcms2.benki.users; + +import io.quarkus.hibernate.orm.panache.PanacheEntityBase; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.FetchType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.ManyToOne; + +@Entity(name = "BenkiOpenId") +public class OpenId extends PanacheEntityBase { + + @Id + @Column(name = "openid", nullable = false, length = -1) + public String openid; + + @ManyToOne(fetch = FetchType.LAZY) + @JoinColumn(name = "user", referencedColumnName = "id", nullable = false) + public User user; +} diff --git a/src/main/java/eu/mulk/mulkcms2/benki/users/Openids.java b/src/main/java/eu/mulk/mulkcms2/benki/users/Openids.java deleted file mode 100644 index 52997c8..0000000 --- a/src/main/java/eu/mulk/mulkcms2/benki/users/Openids.java +++ /dev/null @@ -1,21 +0,0 @@ -package eu.mulk.mulkcms2.benki.users; - -import io.quarkus.hibernate.orm.panache.PanacheEntityBase; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.FetchType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.ManyToOne; - -@Entity -public class Openids extends PanacheEntityBase { - - @Id - @Column(name = "openid", nullable = false, length = -1) - public String openid; - - @ManyToOne(fetch = FetchType.LAZY) - @JoinColumn(name = "user", referencedColumnName = "id", nullable = false) - public User user; -} diff --git a/src/main/java/eu/mulk/mulkcms2/benki/users/User.java b/src/main/java/eu/mulk/mulkcms2/benki/users/User.java index 6e16903..45e775c 100644 --- a/src/main/java/eu/mulk/mulkcms2/benki/users/User.java +++ b/src/main/java/eu/mulk/mulkcms2/benki/users/User.java @@ -53,7 +53,7 @@ public class User extends PanacheEntityBase { public Collection lazychatMessages; @OneToMany(mappedBy = "user", fetch = FetchType.LAZY) - public Collection openids; + public Collection openids; @OneToMany(mappedBy = "user", fetch = FetchType.LAZY) public Collection pageKeys; diff --git a/src/main/java/eu/mulk/mulkcms2/cms/users/OpenId.java b/src/main/java/eu/mulk/mulkcms2/cms/users/OpenId.java index 0cc7407..a7a391b 100644 --- a/src/main/java/eu/mulk/mulkcms2/cms/users/OpenId.java +++ b/src/main/java/eu/mulk/mulkcms2/cms/users/OpenId.java @@ -10,7 +10,7 @@ import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; import javax.persistence.Table; -@Entity +@Entity(name = "CmsOpenId") @Table(name = "openids", schema = "public", catalog = "mulkcms") @IdClass(OpenIdPK.class) public class OpenId extends PanacheEntityBase { -- cgit v1.2.3