comparison backend/src/main/java/org/dive4elements/river/importer/ImportBedHeight.java @ 9038:4c5eeaff554c

Database column "comment" renamed to "notes" (restrictions in Oracle)
author mschaefer
date Wed, 02 May 2018 06:56:21 +0200
parents 392bbcd8a88b
children
comparison
equal deleted inserted replaced
9037:1574ce45c98d 9038:4c5eeaff554c
35 protected ImportBedHeightType type; 35 protected ImportBedHeightType type;
36 protected ImportLocationSystem locationSystem; 36 protected ImportLocationSystem locationSystem;
37 protected ImportElevationModel curElevationModel; 37 protected ImportElevationModel curElevationModel;
38 protected ImportElevationModel oldElevationModel; 38 protected ImportElevationModel oldElevationModel;
39 protected String sounding_width_info; 39 protected String sounding_width_info;
40 protected String comment; 40 protected String notes;
41 41
42 protected List<ImportBedHeightValue> values; 42 protected List<ImportBedHeightValue> values;
43 43
44 protected StoreMode storeMode; 44 protected StoreMode storeMode;
45 45
100 100
101 public void setSoundingWidthInfo(final String sounding_width_info) { 101 public void setSoundingWidthInfo(final String sounding_width_info) {
102 this.sounding_width_info = sounding_width_info; 102 this.sounding_width_info = sounding_width_info;
103 } 103 }
104 104
105 public void setComment(final String comment) { 105 public void setNotes(final String notes) {
106 this.comment = comment; 106 this.notes = notes;
107 } 107 }
108 108
109 public void addValue(final ImportBedHeightValue value) { 109 public void addValue(final ImportBedHeightValue value) {
110 this.values.add(value); 110 this.values.add(value);
111 } 111 }
178 final List<BedHeight> bedHeights = query.list(); 178 final List<BedHeight> bedHeights = query.list();
179 if (bedHeights.isEmpty()) { 179 if (bedHeights.isEmpty()) {
180 log.info("Create new BedHeight DB instance."); 180 log.info("Create new BedHeight DB instance.");
181 this.peer = new BedHeight(river, this.year, theType, this.locationSystem.getPeer(), theCurModel, 181 this.peer = new BedHeight(river, this.year, theType, this.locationSystem.getPeer(), theCurModel,
182 (this.oldElevationModel != null) ? this.oldElevationModel.getPeer() : null, this.range.getPeer(river), 182 (this.oldElevationModel != null) ? this.oldElevationModel.getPeer() : null, this.range.getPeer(river),
183 this.evaluationBy, this.description, this.sounding_width_info, this.comment); 183 this.evaluationBy, this.description, this.sounding_width_info, this.notes);
184 session.save(this.peer); 184 session.save(this.peer);
185 this.storeMode = StoreMode.INSERT; 185 this.storeMode = StoreMode.INSERT;
186 } 186 }
187 else { 187 else {
188 this.peer = bedHeights.get(0); 188 this.peer = bedHeights.get(0);

http://dive4elements.wald.intevation.org