Skip to content

Commit 1ea33e5

Browse files
committed
currentStudy
1 parent d1ce455 commit 1ea33e5

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

services/static-webserver/client/source/class/osparc/support/CallTopicSelector.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ qx.Class.define("osparc.support.CallTopicSelector", {
8080
});
8181
this._add(control);
8282
break;
83-
case "share-project-checkbox":
83+
case "share-project-checkbox": {
8484
control = new qx.ui.form.CheckBox().set({
8585
value: true,
8686
label: this.tr("share current project with support team (optional)"),
@@ -90,7 +90,17 @@ qx.Class.define("osparc.support.CallTopicSelector", {
9090
this.getChildControl("help-with-project-button").bind("value", control, "visibility", {
9191
converter: val => val ? "visible" : "excluded"
9292
});
93+
const store = osparc.store.Store.getInstance();
94+
store.bind("currentStudy", control, "enabled", {
95+
converter: study => {
96+
if (!study) {
97+
control.setValue(false);
98+
}
99+
return Boolean(study);
100+
}
101+
});
93102
break;
103+
}
94104
case "specific-topic-button":
95105
control = new qx.ui.form.RadioButton().set({
96106
label: this.tr("to discuss a specific topic"),

0 commit comments

Comments
 (0)