Skip to content

Commit

Permalink
Restore validation for all DMN versions
Browse files Browse the repository at this point in the history
  • Loading branch information
yesamer committed Mar 15, 2024
1 parent 5831ab7 commit 66afd37
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions packages/online-editor/src/editor/Validation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -120,14 +120,22 @@ export function useFileValidation(

const decodedFileContent = decoder.decode(fileContent);
const dmnSpecVersion = dmnLanguageService?.getSpecVersion(decodedFileContent);
if (!dmnSpecVersion || (dmnSpecVersion !== "1.0" && dmnSpecVersion !== "1.1" && dmnSpecVersion !== "1.2")) {
if (
!dmnSpecVersion ||
(dmnSpecVersion !== "1.0" &&
dmnSpecVersion !== "1.1" &&
dmnSpecVersion !== "1.2" &&
dmnSpecVersion !== "1.3" &&
dmnSpecVersion !== "1.4" &&
dmnSpecVersion !== "1.5")
) {
setNotifications(i18n.terms.validation, "", [
{
type: "ALERT",
normalizedPosixPathRelativeToTheWorkspaceRoot: "",
severity: "WARNING",
message:
"Validation checks are temporarily supported only on DMN 1.2 or below. For full access to this feature, use the Legacy DMN Editor.",
"Validation doesn't support this DMN version" + dmnSpecVersion ? "(" + dmnSpecVersion + ")" : "",
},
]);
return;
Expand Down

0 comments on commit 66afd37

Please sign in to comment.