Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}).fail(function(result) {
if (result.status === 403 || result.status === 500) {
// Redirect the user to the forbidden page with more info
var errorText = result.status == 500 ? "Internal Server Error. Contact support" : result.responseText,
error_status = encodeURIComponent(errorText);
window.location = "/forbidden?banner=" + error_status;
} else {
NotificationController.error(
null,
`There was an error logging you in. If this persists, please email <a href="mailto:${globals.SUPPORT_EMAIL}">${globals.SUPPORT_EMAIL}</a>.`,
{
"positionClass": "toast-top-full-width",
"timeOut": "0",
"extendedTimeOut": "0"
});
}
});
}
<div style="{{minHeight:">
<p>
The password associated with the cloud providers
for your account has expired. This will block
further actions, like the launching of new
instances.
</p>
<p>
Please visit <a href="{link}">{text}</a> and
perform a password reset.
<br>
If you have trouble reach out to{" "}
<a href="{`mailto:${globals.SUPPORT_EMAIL}`}">
support
</a>.
</p>
</div>
<div>
<button type="button">
Okay
</button>
</div>
);
var content = (
<div>
<h4>Want to provide feedback?</h4>
<p>
{
"To avoid automated or auto-generated message, user must be authenticated to give feedback."
}
</p>
<h4>{"Having trouble logging in?"}</h4>
<p>
{`If you are experiencing issues accessing ${
globals.SITE_FOOTER
}, please contact
the support staff by sending an email to: `}
<a href="{`mailto${globals.SUPPORT_EMAIL}`}">
{`${globals.SUPPORT_EMAIL}`}
</a>
</p>
</div>
);
return (
<div>
<div>
<div>
<div>
{this.renderCloseButton()}
<h1>Feedback & Support</h1>
</div>
<div>{content}</div>
<div>{buttons}</div>
</div></div></div>
<div style="{{paddingTop:">
<h1>Help Page</h1>
<h2>External resources</h2>
<ul>{resourceElements}</ul>
<div>
<h2>Contact</h2>
<p>
{
"You can contact the Atmosphere support staff by clicking on the "
}
<strong>{"Feedback & Support"}</strong>
{
" button at the bottom of the page (to enter a help request online) or by sending an email to "
}
<a href="{`mailto:${globals.SUPPORT_EMAIL}`}">
{globals.SUPPORT_EMAIL}
</a>
{"."}
</p>
</div>
</div>
);
}
});
error: function(response) {
var errorMessage,
response_error =
response.responseJSON != null
? response.responseJSON.detail
: response.responseText;
if (response.status >= 500) {
errorMessage = `Your login failed due to an unexpected error in the Atmosphere Auth Server. If you continue to see this message please email <a href="mailto:${
globals.SUPPORT_EMAIL
}">${globals.SUPPORT_EMAIL}</a>.`;
} else {
errorMessage = `There was an error saving new user token: ${response_error}`;
}
NotificationController.error("An error occured", errorMessage);
}
});
renderSupportLink() {
return (
<a href="{">{ ` ${globals.SUPPORT_EMAIL} ` }</a>
);
},
error: function(response) {
var errorMessage,
response_error = response.responseJSON.detail;
if (response.status >= 500) {
errorMessage = `Your feedback could not be submitted. If you'd like to send it directly to support, email <a href="mailto:${
globals.SUPPORT_EMAIL
}">${globals.SUPPORT_EMAIL}</a>.`;
} else {
errorMessage =
"There was an error submitting your request: " +
response_error;
}
NotificationController.error("An error occured", errorMessage);
}
});
renderSupportLink() {
return (
<a href="{`mailto:${globals.SUPPORT_EMAIL}`}">{` ${
globals.SUPPORT_EMAIL
} `}</a>
);
},
error: function() {
var message = (
<div>
{"If this problem persists, contact support at "}
<a href="{`mailto:${globals.SUPPORT_EMAIL}`}">
{globals.SUPPORT_EMAIL}
</a>
</div>
);
return ReactDOM.renderToString(message);
},