catch error in prefilling when source mapping does not exist in the api's response
This commit is contained in:
parent
e878310b72
commit
2db9ea613f
|
@ -57,8 +57,18 @@ public class PrefillingMapper {
|
||||||
sourceValue = ((Map)sourceValue).get(sourceKey);
|
sourceValue = ((Map)sourceValue).get(sourceKey);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
try {
|
||||||
setValue(prefillingMapping, mapper.writeValueAsString(sourceValue), datasetWizardModel, parentNode, properties, type, licenseManager);
|
setValue(prefillingMapping, mapper.writeValueAsString(sourceValue), datasetWizardModel, parentNode, properties, type, licenseManager);
|
||||||
}
|
}
|
||||||
|
catch (Exception e) {
|
||||||
|
if (prefillingMapping.getSemanticTarget() != null && !prefillingMapping.getSemanticTarget().isEmpty()) {
|
||||||
|
logger.warn("Couldn't map " + prefillingMapping.getSemanticTarget());
|
||||||
|
}
|
||||||
|
else if (prefillingMapping.getTarget() != null && !prefillingMapping.getTarget().isEmpty()) {
|
||||||
|
logger.warn("Couldn't map " + prefillingMapping.getTarget());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
for (PrefillingFixedMapping fixedMapping: prefillingGet.getFixedMappings()) {
|
for (PrefillingFixedMapping fixedMapping: prefillingGet.getFixedMappings()) {
|
||||||
setValue(fixedMapping, fixedMapping.getValue(), datasetWizardModel, parentNode, properties, type, licenseManager);
|
setValue(fixedMapping, fixedMapping.getValue(), datasetWizardModel, parentNode, properties, type, licenseManager);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue