Skip to content

Commit

Permalink
Merge branch 'master' into fix/s4llite-guided-tour
Browse files Browse the repository at this point in the history
  • Loading branch information
odeimaiz authored Oct 17, 2024
2 parents b74dbb3 + 990292e commit cf2ce1c
Showing 1 changed file with 18 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,15 @@ qx.Class.define("osparc.auth.ui.LoginView", {
createAccountBtn.setLabel(this.tr("Request Account"));
}
createAccountBtn.addListener("execute", () => {
createAccountBtn.setEnabled(false);
if (createAccountAction === "REGISTER") {
if (window.location.hostname === "tip.itis.swiss") {
this.__openTIPITISSWISSPhaseOutDialog();
} else if (createAccountAction === "REGISTER") {
this.fireEvent("toRegister");
} else if (createAccountAction === "REQUEST_ACCOUNT_FORM") {
this.fireEvent("toRequestAccount");
} else if (createAccountAction === "REQUEST_ACCOUNT_INSTRUCTIONS") {
osparc.store.Support.openInvitationRequiredDialog();
}
createAccountBtn.setEnabled(true);
}, this);
osparc.utils.Utils.setIdToWidget(createAccountBtn, "loginCreateAccountBtn");

Expand Down Expand Up @@ -162,6 +162,21 @@ qx.Class.define("osparc.auth.ui.LoginView", {
}
},

__openTIPITISSWISSPhaseOutDialog: function() {
const createAccountWindow = new osparc.ui.window.Dialog("Request Account").set({
maxWidth: 380
});
let message = "This version of the planning tool will be phased out soon and no longer accepts new users.";
message += "<br>";
const tipLiteLabel = osparc.utils.Utils.createHTMLLink("TIP.lite", "https://tip-lite.science/");
const tipLabel = osparc.utils.Utils.createHTMLLink("TIP", "https://tip.science/");
const hereLabel = osparc.utils.Utils.createHTMLLink("here", "https://itis.swiss/tools-and-systems/ti-planning/overview/");
message += `Please visit ${tipLiteLabel} or ${tipLabel} instead. See ${hereLabel} for more information.`;
createAccountWindow.setMessage(message);
createAccountWindow.center();
createAccountWindow.open();
},

getEmail: function() {
const email = this._form.getItems().email;
return email.getValue();
Expand Down

0 comments on commit cf2ce1c

Please sign in to comment.