diff --git a/src/question.ts b/src/question.ts index 0dc56e1cb4..72769c3b2f 100644 --- a/src/question.ts +++ b/src/question.ts @@ -2028,7 +2028,7 @@ export class Question extends SurveyElement } public addConditionObjectsByContext(objects: Array, context: any): void { objects.push({ - name: this.getValueName(), + name: this.getFilteredName(), text: this.processedTitle, question: this, }); diff --git a/src/question_checkbox.ts b/src/question_checkbox.ts index fcc1a3d02e..01ab3372a5 100644 --- a/src/question_checkbox.ts +++ b/src/question_checkbox.ts @@ -253,7 +253,7 @@ export class QuestionCheckboxModel extends QuestionCheckboxBase { public getFilteredName(): any { let res = super.getFilteredName(); if(this.hasFilteredValue) { - res += "#value"; + res += "-unwrapped"; } return res; } diff --git a/tests/question_baseselecttests.ts b/tests/question_baseselecttests.ts index 02c4932c9f..90224334e4 100644 --- a/tests/question_baseselecttests.ts +++ b/tests/question_baseselecttests.ts @@ -714,7 +714,7 @@ QUnit.test("checkbox vs valuePropertyName, use in expression", (assert) => { { type: "text", name: "q2", - visibleIf: "{q1#value} allof ['apple', 'orange']" + visibleIf: "{q1-unwrapped} allof ['apple', 'orange']" } ] });