more work on code validation
This commit is contained in:
parent
fa89778809
commit
c5f4d2396f
|
@ -159,13 +159,20 @@ public class ValueSetCheckerSimple implements ValueSetChecker {
|
|||
}
|
||||
|
||||
if (cs != null /*&& (cs.getContent() == CodeSystemContentMode.COMPLETE || cs.getContent() == CodeSystemContentMode.FRAGMENT)*/) {
|
||||
if (!(cs.getContent() == CodeSystemContentMode.COMPLETE || cs.getContent() == CodeSystemContentMode.FRAGMENT)) {
|
||||
// we can't validate that here.
|
||||
throw new FHIRException("Unable to evaluate based on empty code system");
|
||||
}
|
||||
res = validateCode(code, cs);
|
||||
} else {
|
||||
// it's in the expansion, but we could find it in a code system
|
||||
res = findCodeInExpansion(code);
|
||||
// well, we didn't find a code system - try the expansion?
|
||||
// disabled waiting for discussion
|
||||
throw new Error("No try the server");
|
||||
}
|
||||
} else {
|
||||
inExpansion = checkExpansion(code);
|
||||
// disabled waiting for discussion
|
||||
throw new Error("No try the server");
|
||||
// inExpansion = checkExpansion(code);
|
||||
}
|
||||
|
||||
// then, if we have a value set, we check it's in the value set
|
||||
|
|
|
@ -180,7 +180,6 @@ public class QuestionnaireValidator extends BaseValidator {
|
|||
}
|
||||
}
|
||||
if (hint(errors, IssueType.REQUIRED, element.line(), element.col(), stack.getLiteralPath(), questionnaire != null, I18nConstants.QUESTIONNAIRE_QR_Q_NONE)) {
|
||||
long t = System.nanoTime();
|
||||
Questionnaire qsrc = questionnaire.startsWith("#") ? loadQuestionnaire(element, questionnaire.substring(1)) : context.fetchResource(Questionnaire.class, questionnaire);
|
||||
if (warning(errors, IssueType.REQUIRED, q.line(), q.col(), stack.getLiteralPath(), qsrc != null, I18nConstants.QUESTIONNAIRE_QR_Q_NOTFOUND, questionnaire)) {
|
||||
boolean inProgress = "in-progress".equals(element.getNamedChildValue("status"));
|
||||
|
|
Loading…
Reference in New Issue