Commit 424fff02 by Juho Juopperi

model jpa fixes

1 parent f6dae56c
...@@ -41,7 +41,7 @@ public class AccessRight implements ModelInterface { ...@@ -41,7 +41,7 @@ public class AccessRight implements ModelInterface {
@OneToMany(cascade = CascadeType.ALL, mappedBy = "accessRight") @OneToMany(cascade = CascadeType.ALL, mappedBy = "accessRight")
private List<NewsGroup> newsGroups; private List<NewsGroup> newsGroups;
@OneToMany(mappedBy = "id") @OneToMany(mappedBy = "accessRight")
private List<RoleRight> roleRights; private List<RoleRight> roleRights;
public Integer getId() { public Integer getId() {
......
...@@ -48,7 +48,7 @@ public class CardTemplate implements ModelInterface { ...@@ -48,7 +48,7 @@ public class CardTemplate implements ModelInterface {
@OneToMany(mappedBy = "cardTemplate") @OneToMany(mappedBy = "cardTemplate")
private List<Role> roles; private List<Role> roles;
@OneToMany(mappedBy = "cardTemplate") @OneToMany(mappedBy = "template")
private List<PrintedCard> cards; private List<PrintedCard> cards;
@Version @Version
......
...@@ -34,7 +34,7 @@ public class Location implements ModelInterface { ...@@ -34,7 +34,7 @@ public class Location implements ModelInterface {
@Column(name = "location_name", nullable = false) @Column(name = "location_name", nullable = false)
private String name; private String name;
@OneToMany(mappedBy = "id") @OneToMany(mappedBy = "location")
private List<Reader> readers; private List<Reader> readers;
@OneToMany(mappedBy = "currentLocation") @OneToMany(mappedBy = "currentLocation")
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!