How to use the cwlts/models/helpers/validation.ErrorCode.EXPR_ALL function in cwlts

To help you get started, we’ve selected a few cwlts examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github rabix / composer / src / app / tool-editor / sections / base-command-editor / base-command-editor.component.ts View on Github external
this.modal.delete("Base Command").then(() => {

            // Reset the expression's validity
            // @TODO: if this is an ExpressionModel, model won't revalidate when an entry is removed
            const entryAtIndex = this.formControl.at(index).value;

            if (entryAtIndex instanceof ExpressionModel) {
                entryAtIndex.clearIssue(ErrorCode.EXPR_ALL);
            }

            this.formControl.removeAt(index);
            this.cdr.markForCheck();
        }, err => {
            console.warn(err);
github rabix / composer / src / app / editor-common / components / secondary-files / secondary-files.component.ts View on Github external
this.modal.delete("secondary file").then(() => {
            // Reset the expression's validity
            const entryAtIndex = this.formControl.at(index).value;

            if (entryAtIndex) {
                entryAtIndex.clearIssue(ErrorCode.EXPR_ALL);
            }

            this.formControl.removeAt(index);
            this.cdr.markForCheck();
        }, err => {
            console.warn(err);
github rabix / composer / src / app / editor-common / components / hint-list / hint-list.component.ts View on Github external
this.modal.delete("hint").then(() => {
            this.model.hints[i].clearIssue(ErrorCode.EXPR_ALL);
            this.model.hints.splice(i, 1);
            (this.form.get("hints") as FormArray).removeAt(i);
            this.update.emit(this.model.hints);
        }, err => {
            console.warn(err);