Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Weimann <mail@michael-weimann.eu>2018-07-21 14:05:13 +0300
committerMichael Weimann <mail@michael-weimann.eu>2018-07-21 14:05:13 +0300
commitc92d7429d7ff9a76a6dd62607e55ef680a43a679 (patch)
treecb0b88b163bc425dfbddff63dd23f0b8e2d9647e /core/templates
parentcce12f0ca3e2b2b158ffa43450b862053291b8d0 (diff)
Implements handling for deactivated users
Signed-off-by: Michael Weimann <mail@michael-weimann.eu>
Diffstat (limited to 'core/templates')
-rw-r--r--core/templates/login.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/core/templates/login.php b/core/templates/login.php
index 8fc68edb92d..989ea1eaad5 100644
--- a/core/templates/login.php
+++ b/core/templates/login.php
@@ -2,6 +2,8 @@
<?php
vendor_script('jsTimezoneDetect/jstz');
script('core', 'merged-login');
+
+use OC\Core\Controller\LoginController;
?>
<!--[if IE 8]><style>input[type="checkbox"]{padding:0;}</style><![endif]-->
@@ -34,7 +36,7 @@ script('core', 'merged-login');
<!-- the following div ensures that the spinner is always inside the #message div -->
<div style="clear: both;"></div>
</div>
- <p class="grouptop<?php if (!empty($_['invalidpassword'])) { ?> shake<?php } ?>">
+ <p class="grouptop<?php if (!empty($_[LoginController::LOGIN_MSG_INVALIDPASSWORD])) { ?> shake<?php } ?>">
<input type="text" name="user" id="user"
placeholder="<?php p($l->t('Username or email')); ?>"
aria-label="<?php p($l->t('Username or email')); ?>"
@@ -44,7 +46,7 @@ script('core', 'merged-login');
<label for="user" class="infield"><?php p($l->t('Username or email')); ?></label>
</p>
- <p class="groupbottom<?php if (!empty($_['invalidpassword'])) { ?> shake<?php } ?>">
+ <p class="groupbottom<?php if (!empty($_[LoginController::LOGIN_MSG_INVALIDPASSWORD])) { ?> shake<?php } ?>">
<input type="password" name="password" id="password" value=""
placeholder="<?php p($l->t('Password')); ?>"
aria-label="<?php p($l->t('Password')); ?>"
@@ -58,10 +60,14 @@ script('core', 'merged-login');
<div class="submit-icon icon-confirm-white"></div>
</div>
- <?php if (!empty($_['invalidpassword'])) { ?>
+ <?php if (!empty($_[LoginController::LOGIN_MSG_INVALIDPASSWORD])) { ?>
<p class="warning wrongPasswordMsg">
<?php p($l->t('Wrong password.')); ?>
</p>
+ <?php } else if (!empty($_[LoginController::LOGIN_MSG_USERDISABLED])) { ?>
+ <p class="warning userDisabledMsg">
+ <?php p(\OC::$server->getL10N('lib')->t('User disabled')); ?>
+ </p>
<?php } ?>
<?php if ($_['throttle_delay'] > 5000) { ?>