Add option to disable email confirmation banner (#2469)

GitOrigin-RevId: ef5e08a6359346cc53dff4ce7978affb71fdb556
This commit is contained in:
Miguel Serrano 2019-12-18 10:46:27 +01:00 committed by Copybot
parent b055612e3c
commit 1c759ad413
3 changed files with 6 additions and 0 deletions

View file

@ -361,6 +361,7 @@ module.exports = function(webRouter, privateApiRouter, publicApiRouter) {
hasSamlFeature: Features.hasFeature('saml'), hasSamlFeature: Features.hasFeature('saml'),
samlInitPath: _.get(Settings, ['saml', 'ukamf', 'initPath']), samlInitPath: _.get(Settings, ['saml', 'ukamf', 'initPath']),
siteUrl: Settings.siteUrl, siteUrl: Settings.siteUrl,
emailConfirmationDisabled: Settings.emailConfirmationDisabled,
recaptchaSiteKeyV3: recaptchaSiteKeyV3:
Settings.recaptcha != null ? Settings.recaptcha.siteKeyV3 : undefined, Settings.recaptcha != null ? Settings.recaptcha.siteKeyV3 : undefined,
recaptchaDisabled: recaptchaDisabled:

View file

@ -567,6 +567,8 @@ module.exports = settings =
validRootDocExtensions: ['tex', 'Rtex', 'ltx'] validRootDocExtensions: ['tex', 'Rtex', 'ltx']
emailConfirmationDisabled: (process.env['EMAIL_CONFIRMATION_DISABLED'] == "true") or false
# allowedImageNames: [ # allowedImageNames: [
# {imageName: 'texlive-full:2017.1', imageDesc: 'TeXLive 2017'} # {imageName: 'texlive-full:2017.1', imageDesc: 'TeXLive 2017'}
# {imageName: 'wl_texlive:2018.1', imageDesc: 'Legacy OL TeXLive 2015'} # {imageName: 'wl_texlive:2018.1', imageDesc: 'Legacy OL TeXLive 2015'}

View file

@ -102,6 +102,9 @@ define(['base'], function(App) {
) { ) {
$scope.userEmails = [] $scope.userEmails = []
$scope.showConfirmEmail = email => { $scope.showConfirmEmail = email => {
if (ExposedSettings.emailConfirmationDisabled) {
return false
}
if (!email.confirmedAt && !email.hide) { if (!email.confirmedAt && !email.hide) {
if ( if (
email.affiliation && email.affiliation &&