Project

General

Profile

« Previous | Next » 

Revision 8275a22c

Added by Andreas Müller over 3 years ago

cleanup

View differences:

app-import/src/main/java/eu/etaxonomy/cdm/io/berlinModel/in/BerlinModelNameFactsImport.java
128 128
				String category = CdmUtils.Nz(rs.getString("NameFactCategory"));
129 129
				String nameFact = CdmUtils.Nz(rs.getString("nameFact"));
130 130

  
131
				TaxonName taxonNameBase = nameMap.get(String.valueOf(nameId));
131
				TaxonName taxonName = nameMap.get(String.valueOf(nameId));
132 132
				String nameFactRefFk = String.valueOf(nameFactRefFkObj);
133 133
				Reference citation = refMap.get(nameFactRefFk);
134 134

  
135
				if (taxonNameBase != null){
135
				if (taxonName != null){
136 136
					//PROTOLOGUE
137 137
					if (category.equalsIgnoreCase(NAME_FACT_PROTOLOGUE)){
138 138

  
......
140 140
						try{
141 141
						    //this depends on specific project implementation, maybe also config.getMediaPath() is important
142 142
						    URI uri = URI.create(uriString);
143
							taxonNameBase.addProtologue(uri, null, ExternalLinkType.Unknown);
143
							taxonName.addProtologue(uri, null, ExternalLinkType.Unknown);
144 144
						}catch(IllegalArgumentException e){
145 145
							logger.warn("Incorrect protologue URI: " + uriString);
146 146
							success = false;
......
158 158
								additionalPublication.addSource(OriginalSourceType.PrimaryTaxonomicSource, null, null, citation, nameFactRefDetail, null, null);
159 159
							}
160 160
							description.addElement(additionalPublication);
161
							taxonNameBase.addDescription(description);
161
							taxonName.addDescription(description);
162 162
						}
163 163
					}else if (category.equalsIgnoreCase(NAME_FACT_BIBLIOGRAPHY)){
164 164
						if (isNotBlank(nameFact)){
......
172 172
								bibliography.addSource(OriginalSourceType.PrimaryTaxonomicSource, null, null, citation, nameFactRefDetail, null, null);
173 173
							}
174 174
							description.addElement(bibliography);
175
							taxonNameBase.addDescription(description);
175
							taxonName.addDescription(description);
176 176
						}
177 177
					}else {
178 178
						//TODO
......
189 189
//					Updated_Who  nvarchar(255)    Checked
190 190
//					Notes      nvarchar(1000)           Checked
191 191

  
192
					nameToSave.add(taxonNameBase);
192
					nameToSave.add(taxonName);
193 193
				}else{
194 194
					//TODO
195 195
					logger.warn("TaxonName for NameFact " + nameFactId + " does not exist in store");

Also available in: Unified diff