Mercurial > dive4elements > river
view backend/src/main/java/org/dive4elements/river/seddb/model/Bild.java @ 8443:df65f24af5bc
(issue1762) Use getValue to obtain dateRange values
The getToValue was always the initial value regardless
of what has been entered in the form.
According to the documentation both getToValue and getFromValue
should return the "initial value" of the form field. But wether
this means the value before validation corrections or the value
the field is initialized with (which is also not true in both
cases as the field is set only after creation) It returned
the real value for the from date but not for the to date.
With an explicit getValue we workaround this issue.
author | Andre Heinecke <andre.heinecke@intevation.de> |
---|---|
date | Wed, 22 Oct 2014 17:33:43 +0200 |
parents | 4c3ccf2b0304 |
children |
line wrap: on
line source
/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde * Software engineering by Intevation GmbH * * This file is Free Software under the GNU AGPL (>=v3) * and comes with ABSOLUTELY NO WARRANTY! Check out the * documentation coming with Dive4Elements River for details. */ package org.dive4elements.river.seddb.model; // Generated 14.06.2012 11:30:57 by Hibernate Tools 3.4.0.CR1 import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.FetchType; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; import javax.persistence.Table; /** * Bild generated by hbm2java */ @Entity @Table(name="BILD" ,schema="SEDDB" ) public class Bild implements java.io.Serializable { private long bildid; private Zzthema zzthema; private Sohltest sohltest; private int lfdnr; private boolean istdigital; private String pfad; private String standort; private String medium; private String medpfad; private String bemerkung; private String typklein; private String typmittel; private String typgross; public Bild() { } public Bild(long bildid, Zzthema zzthema, Sohltest sohltest, int lfdnr, boolean istdigital) { this.bildid = bildid; this.zzthema = zzthema; this.sohltest = sohltest; this.lfdnr = lfdnr; this.istdigital = istdigital; } public Bild(long bildid, Zzthema zzthema, Sohltest sohltest, int lfdnr, boolean istdigital, String pfad, String standort, String medium, String medpfad, String bemerkung, String typklein, String typmittel, String typgross) { this.bildid = bildid; this.zzthema = zzthema; this.sohltest = sohltest; this.lfdnr = lfdnr; this.istdigital = istdigital; this.pfad = pfad; this.standort = standort; this.medium = medium; this.medpfad = medpfad; this.bemerkung = bemerkung; this.typklein = typklein; this.typmittel = typmittel; this.typgross = typgross; } @Id @Column(name="BILDID", unique=true, nullable=false, precision=11, scale=0) public long getBildid() { return this.bildid; } public void setBildid(long bildid) { this.bildid = bildid; } @ManyToOne(fetch=FetchType.LAZY) @JoinColumn(name="THEMAID", nullable=false) public Zzthema getZzthema() { return this.zzthema; } public void setZzthema(Zzthema zzthema) { this.zzthema = zzthema; } @ManyToOne(fetch=FetchType.LAZY) @JoinColumn(name="SOHLTESTID", nullable=false) public Sohltest getSohltest() { return this.sohltest; } public void setSohltest(Sohltest sohltest) { this.sohltest = sohltest; } @Column(name="LFDNR", nullable=false, precision=5, scale=0) public int getLfdnr() { return this.lfdnr; } public void setLfdnr(int lfdnr) { this.lfdnr = lfdnr; } @Column(name="ISTDIGITAL", nullable=false, precision=1, scale=0) public boolean isIstdigital() { return this.istdigital; } public void setIstdigital(boolean istdigital) { this.istdigital = istdigital; } @Column(name="PFAD", length=512) public String getPfad() { return this.pfad; } public void setPfad(String pfad) { this.pfad = pfad; } @Column(name="STANDORT", length=50) public String getStandort() { return this.standort; } public void setStandort(String standort) { this.standort = standort; } @Column(name="MEDIUM", length=50) public String getMedium() { return this.medium; } public void setMedium(String medium) { this.medium = medium; } @Column(name="MEDPFAD", length=50) public String getMedpfad() { return this.medpfad; } public void setMedpfad(String medpfad) { this.medpfad = medpfad; } @Column(name="BEMERKUNG", length=240) public String getBemerkung() { return this.bemerkung; } public void setBemerkung(String bemerkung) { this.bemerkung = bemerkung; } @Column(name="TYPKLEIN", length=8) public String getTypklein() { return this.typklein; } public void setTypklein(String typklein) { this.typklein = typklein; } @Column(name="TYPMITTEL", length=8) public String getTypmittel() { return this.typmittel; } public void setTypmittel(String typmittel) { this.typmittel = typmittel; } @Column(name="TYPGROSS", length=8) public String getTypgross() { return this.typgross; } public void setTypgross(String typgross) { this.typgross = typgross; } }