From 6801698dfc9c99b34d7ed081ebcfbec4a8853868 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Wed, 20 Feb 2013 22:35:43 +1300 Subject: Added account dialog --- src/org/traccar/web/shared/model/User.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'src/org/traccar/web/shared/model/User.java') diff --git a/src/org/traccar/web/shared/model/User.java b/src/org/traccar/web/shared/model/User.java index 9a67c6d9..77a17eef 100644 --- a/src/org/traccar/web/shared/model/User.java +++ b/src/org/traccar/web/shared/model/User.java @@ -25,8 +25,11 @@ import javax.persistence.FetchType; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.OneToMany; +import javax.persistence.OneToOne; import javax.persistence.Table; +import com.google.gwt.user.client.rpc.GwtTransient; + @Entity @Table(name="users") public class User implements Serializable, Cloneable { @@ -82,11 +85,27 @@ public class User implements Serializable, Cloneable { return admin; } + @GwtTransient @OneToMany(fetch = FetchType.EAGER) private List devices = new LinkedList(); + public void setDevices(List devices) { + this.devices = devices; + } + public List getDevices() { return devices; } + @OneToOne + private UserSettings userSettings; + + public void setUserSettings(UserSettings userSettings) { + this.userSettings = userSettings; + } + + public UserSettings getUserSettings() { + return userSettings; + } + } -- cgit v1.2.3