diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2013-02-28 21:12:32 +1300 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2013-02-28 21:12:32 +1300 |
commit | 4f3cbf8afda8216f5fffa3f5288dea9779dc4881 (patch) | |
tree | 65101b9f1cb414d8006e3de2a0283599cfe8e246 /src/org/traccar/web/shared/model/Device.java | |
parent | d253ba26aaa3f94b154e93ab92c5779e8b98b81b (diff) | |
download | trackermap-web-4f3cbf8afda8216f5fffa3f5288dea9779dc4881.tar.gz trackermap-web-4f3cbf8afda8216f5fffa3f5288dea9779dc4881.tar.bz2 trackermap-web-4f3cbf8afda8216f5fffa3f5288dea9779dc4881.zip |
Temporary persistence workaround
Diffstat (limited to 'src/org/traccar/web/shared/model/Device.java')
-rw-r--r-- | src/org/traccar/web/shared/model/Device.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/org/traccar/web/shared/model/Device.java b/src/org/traccar/web/shared/model/Device.java index 324bad83..6f6d6c57 100644 --- a/src/org/traccar/web/shared/model/Device.java +++ b/src/org/traccar/web/shared/model/Device.java @@ -17,7 +17,6 @@ package org.traccar.web.shared.model; import java.io.Serializable; -import javax.persistence.CascadeType; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.FetchType; @@ -49,9 +48,13 @@ public class Device implements Serializable { return id; } - @OneToOne(fetch = FetchType.EAGER, cascade = CascadeType.ALL) + @OneToOne(fetch = FetchType.EAGER) private Position latestPosition; + public void setLatestPosition(Position latestPosition) { + this.latestPosition = latestPosition; + } + public Position getLatestPosition() { return latestPosition; } |