fix bug listing types when old versions are loaded
This commit is contained in:
parent
07a3962ac2
commit
753a90b463
|
@ -112,6 +112,7 @@ public abstract class BaseLoaderR5 implements IContextResourceLoader {
|
|||
// and we only patch URLs to support version transforms
|
||||
// so we just patch sd/od -> vs -> cs
|
||||
protected void doPatchUrls(Resource resource) {
|
||||
resource.setUserData("old.load.mode", true);
|
||||
if (resource instanceof CanonicalResource) {
|
||||
CanonicalResource cr = (CanonicalResource) resource;
|
||||
cr.setUrl(patchUrl(cr.getUrl(), cr.fhirType()));
|
||||
|
|
|
@ -570,7 +570,7 @@ public class SimpleWorkerContext extends BaseWorkerContext implements IWorkerCon
|
|||
public List<String> getResourceNames() {
|
||||
Set<String> result = new HashSet<String>();
|
||||
for (StructureDefinition sd : listStructures()) {
|
||||
if (sd.getKind() == StructureDefinitionKind.RESOURCE && sd.getDerivation() == TypeDerivationRule.SPECIALIZATION)
|
||||
if (sd.getKind() == StructureDefinitionKind.RESOURCE && sd.getDerivation() == TypeDerivationRule.SPECIALIZATION && !sd.hasUserData("old.load.mode"))
|
||||
result.add(sd.getName());
|
||||
}
|
||||
return Utilities.sorted(result);
|
||||
|
|
Loading…
Reference in New Issue