Fix wrong language code from java locale
This commit is contained in:
parent
0cc46e5a44
commit
2d226fdf51
|
@ -284,7 +284,7 @@ public class FhirRequestBuilder {
|
||||||
reqid = response.header("X-Request-Id");
|
reqid = response.header("X-Request-Id");
|
||||||
}
|
}
|
||||||
if (reqid != null) {
|
if (reqid != null) {
|
||||||
s = s + " ["+reqid+"]";
|
s = s + " [x-request-id: "+reqid+"]";
|
||||||
}
|
}
|
||||||
System.out.println("Error from "+source+": " + s);
|
System.out.println("Error from "+source+": " + s);
|
||||||
throw new EFhirClientException("Error from "+source+": " + ResourceUtilities.getErrorDescription(error), error);
|
throw new EFhirClientException("Error from "+source+": " + ResourceUtilities.getErrorDescription(error), error);
|
||||||
|
|
|
@ -327,7 +327,7 @@ public class DataRenderer extends Renderer implements CodeResolver {
|
||||||
if (JurisdictionUtilities.isJurisdiction(system)) {
|
if (JurisdictionUtilities.isJurisdiction(system)) {
|
||||||
return JurisdictionUtilities.displayJurisdiction(system+"#"+code);
|
return JurisdictionUtilities.displayJurisdiction(system+"#"+code);
|
||||||
}
|
}
|
||||||
ValidationResult t = getContext().getWorker().validateCode(getContext().getTerminologyServiceOptions().withLanguage(context.getLocale().toString()).withVersionFlexible(true), system, version, code, null);
|
ValidationResult t = getContext().getWorker().validateCode(getContext().getTerminologyServiceOptions().withLanguage(context.getLocale().toString().replace("_", "-")).withVersionFlexible(true), system, version, code, null);
|
||||||
|
|
||||||
if (t != null && t.getDisplay() != null)
|
if (t != null && t.getDisplay() != null)
|
||||||
return t.getDisplay();
|
return t.getDisplay();
|
||||||
|
|
Loading…
Reference in New Issue