Completed
Pull Request — dev (#76)
by Sarah
02:44
created
views/user/auth/login_modal.php 1 patch
Braces   +10 added lines, -4 removed lines patch added patch discarded remove patch
@@ -36,11 +36,17 @@
 block discarded – undo
36 36
 
37 37
                     <?php if (AuthChoice::hasClients()): ?>
38 38
                         <?= AuthChoice::widget([]) ?>
39
-                    <?php else: ?>
39
+                    <?php else {
40
+    : ?>
40 41
                         <?php if ($canRegister) : ?>
41
-                            <p><?= Yii::t('UserModule.views_auth_login', "If you're already a member, please login with your username/email and password."); ?></p>
42
-                        <?php else: ?>
43
-                            <p><?= Yii::t('UserModule.views_auth_login', "Please login with your username/email and password."); ?></p>
42
+                            <p><?= Yii::t('UserModule.views_auth_login', "If you're already a member, please login with your username/email and password.");
43
+}
44
+?></p>
45
+                        <?php else {
46
+    : ?>
47
+                            <p><?= Yii::t('UserModule.views_auth_login', "Please login with your username/email and password.");
48
+}
49
+?></p>
44 50
                         <?php endif; ?>                    <?php endif; ?>
45 51
 
46 52
                     <?php $form = ActiveForm::begin(['enableClientValidation' => false]); ?>
Please login to merge, or discard this patch.
views/user/widgets/profileHeader.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -101,9 +101,12 @@
 block discarded – undo
101 101
                          src="<?= $user->getProfileImage()->getUrl(); ?>"
102 102
                          data-src="holder.js/140x140" alt="140x140" style="width: 140px; height: 140px;"/>
103 103
                 </a>
104
-            <?php else : ?>
104
+            <?php else {
105
+    : ?>
105 106
                 <img class="img-rounded profile-user-photo" id="user-profile-image"
106
-                     src="<?= $user->getProfileImage()->getUrl(); ?>"
107
+                     src="<?= $user->getProfileImage()->getUrl();
108
+}
109
+?>"
107 110
                      data-src="holder.js/140x140" alt="140x140" style="width: 140px; height: 140px;"/>
108 111
                  <?php endif; ?>
109 112
 
Please login to merge, or discard this patch.
views/user/widgets/accountTopMenu.php 1 patch
Braces   +15 added lines, -6 removed lines patch added patch discarded remove patch
@@ -8,18 +8,24 @@  discard block
 block discarded – undo
8 8
     <a href="#" class="btn btn-enter" data-action-click="ui.modal.load" data-action-url="<?= Url::toRoute('/user/auth/login'); ?>">
9 9
         <?php if (Yii::$app->getModule('user')->settings->get('auth.anonymousRegistration')): ?>
10 10
             <?= Yii::t('UserModule.base', 'Sign in / up'); ?>
11
-        <?php else: ?>
12
-            <?= Yii::t('UserModule.base', 'Sign in'); ?>
11
+        <?php else {
12
+    : ?>
13
+            <?= Yii::t('UserModule.base', 'Sign in');
14
+}
15
+?>
13 16
         <?php endif; ?>
14 17
     </a>
15
-<?php else: ?>
18
+<?php else {
19
+    : ?>
16 20
     <ul class="nav">
17 21
         <li class="dropdown account">
18 22
             <a href="#" id="account-dropdown-link" class="dropdown-toggle" data-toggle="dropdown">
19 23
 
20 24
                 <?php if ($this->context->showUserName): ?>
21 25
                     <div class="user-title pull-left hidden-xs">
22
-                        <strong><?= Html::encode(Yii::$app->user->getIdentity()->displayName); ?></strong><br/><span class="truncate"><?= Html::encode(Yii::$app->user->getIdentity()->profile->title); ?></span>
26
+                        <strong><?= Html::encode(Yii::$app->user->getIdentity()->displayName);
27
+}
28
+?></strong><br/><span class="truncate"><?= Html::encode(Yii::$app->user->getIdentity()->profile->title); ?></span>
23 29
                     </div>
24 30
                 <?php endif; ?>
25 31
 
@@ -34,9 +40,12 @@  discard block
 block discarded – undo
34 40
                 <?php foreach ($this->context->getItems() as $item): ?>
35 41
                     <?php if ($item['label'] == '---'): ?>
36 42
                         <li class="divider"></li>
37
-                        <?php else: ?>
43
+                        <?php else {
44
+    : ?>
38 45
                         <li>
39
-                            <a <?= isset($item['id']) ? 'id="' . $item['id'] . '"' : '' ?> href="<?= $item['url']; ?>" <?= isset($item['pjax']) && $item['pjax'] === false ? 'data-pjax-prevent' : '' ?>>
46
+                            <a <?= isset($item['id']) ? 'id="' . $item['id'] . '"' : '' ?> href="<?= $item['url'];
47
+}
48
+?>" <?= isset($item['pjax']) && $item['pjax'] === false ? 'data-pjax-prevent' : '' ?>>
40 49
                                 <?= $item['icon'] . ' ' . $item['label']; ?>
41 50
                             </a>
42 51
                         </li>
Please login to merge, or discard this patch.
views/user/registration/success.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,8 +18,11 @@
 block discarded – undo
18 18
                     <p><?= Yii::t('UserModule.views_auth_createAccount_success', 'After activating your account by the administrator, you will receive a notification by email.'); ?></p>
19 19
                     <br>
20 20
                     <a href="<?= Url::home() ?>" class="btn btn-primary" data-ui-loader><?= Yii::t('UserModule.views_auth_createAccount_success', 'back to home') ?></a>
21
-                <?php else: ?>
22
-                    <p><?= Yii::t('UserModule.views_auth_createAccount_success', 'To log in with your new account, click the button below.'); ?></p>
21
+                <?php else {
22
+    : ?>
23
+                    <p><?= Yii::t('UserModule.views_auth_createAccount_success', 'To log in with your new account, click the button below.');
24
+}
25
+?></p>
23 26
                     <br>
24 27
                     <a href="<?= Url::home() ?>"
25 28
                        class="btn btn-primary" data-ui-loader><?= Yii::t('UserModule.views_auth_createAccount_success', 'Go to login page') ?></a>
Please login to merge, or discard this patch.
views/user/account/delete.php 1 patch
Braces   +10 added lines, -4 removed lines patch added patch discarded remove patch
@@ -8,8 +8,11 @@  discard block
 block discarded – undo
8 8
 <?php $this->beginContent('@user/views/account/_userProfileLayout.php') ?>
9 9
 <?php if ($isSpaceOwner) : ?>
10 10
     <?= Yii::t('UserModule.views_account_delete', 'Sorry, as an owner of a workspace you are not able to delete your account!<br />Please assign another owner or delete them.'); ?>
11
-<?php else: ?>
12
-    <?= Yii::t('UserModule.views_account_delete', 'Are you sure, that you want to delete your account?<br />All your published content will be removed! '); ?>
11
+<?php else {
12
+    : ?>
13
+    <?= Yii::t('UserModule.views_account_delete', 'Are you sure, that you want to delete your account?<br />All your published content will be removed! ');
14
+}
15
+?>
13 16
     <br />
14 17
     <br />
15 18
 
@@ -17,8 +20,11 @@  discard block
 block discarded – undo
17 20
 
18 21
     <?php if ($model->isAttributeRequired('currentPassword')): ?>
19 22
         <?= $form->field($model, 'currentPassword')->passwordInput(['maxlength' => 45, 'placeholder' => Yii::t('UserModule.views_account_delete', 'Enter your password to continue')])->label(false); ?>
20
-    <?php else: ?>
21
-        <?= $form->field($model, 'currentPassword')->hiddenInput()->label(false); ?>
23
+    <?php else {
24
+    : ?>
25
+        <?= $form->field($model, 'currentPassword')->hiddenInput()->label(false);
26
+}
27
+?>
22 28
     <?php endif; ?>
23 29
 
24 30
     <?= Html::submitButton(Yii::t('UserModule.views_account_delete', 'Delete account'), array('class' => 'btn btn-danger', 'data-ui-loader' => '')); ?>
Please login to merge, or discard this patch.
views/user/account/connected-accounts.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,8 +27,11 @@
 block discarded – undo
27 27
                         <?= Html::a(Yii::t('UserModule.base', 'Currently in use'), '#', ['class' => 'btn btn-default btn-sm', 'data-method' => 'POST', 'disabled' => 'disabled']); ?>
28 28
                     <?php elseif (in_array($client->getId(), $activeAuthClientIds)) : ?>
29 29
                         <?= Html::a(Yii::t('UserModule.base', 'Disconnect account'), ['connected-accounts', 'disconnect' => $client->getId()], ['class' => 'btn btn-danger btn-sm', 'data-method' => 'POST']); ?>
30
-                    <?php else: ?>
31
-                        <?= Html::a(Yii::t('UserModule.base', 'Connect account'), Url::to(['/user/auth/external', 'authclient' => $client->getId()]), ['class' => 'btn btn-success  btn-sm']); ?>
30
+                    <?php else {
31
+    : ?>
32
+                        <?= Html::a(Yii::t('UserModule.base', 'Connect account'), Url::to(['/user/auth/external', 'authclient' => $client->getId()]), ['class' => 'btn btn-success  btn-sm']);
33
+}
34
+?>
32 35
                     <?php endif; ?>
33 36
                 </td>
34 37
             </tr>
Please login to merge, or discard this patch.
views/user/profile/about.php 1 patch
Braces   +10 added lines, -4 removed lines patch added patch discarded remove patch
@@ -38,14 +38,20 @@
 block discarded – undo
38 38
                                     <div class="col-sm-9">
39 39
                                         <p class="form-control-static"><?= RichText::widget(['text' => $field->getUserValue($user, true)]); ?></p>
40 40
                                     </div>
41
-                                <?php else: ?>
41
+                                <?php else {
42
+    : ?>
42 43
                                     <div class="col-sm-9">
43 44
                                         <?php if ($field->field_type_class == MarkdownEditor::className()): ?>
44 45
                                             <p class="form-control-static" style="min-height: 0 !important;padding-top:0;">
45
-                                                <?= MarkdownView::widget(['markdown' => $field->getUserValue($user, false)]); ?>
46
+                                                <?= MarkdownView::widget(['markdown' => $field->getUserValue($user, false)]);
47
+}
48
+?>
46 49
                                             </p>
47
-                                        <?php else: ?>
48
-                                            <p class="form-control-static"><?= $field->getUserValue($user, false); ?></p>                     
50
+                                        <?php else {
51
+    : ?>
52
+                                            <p class="form-control-static"><?= $field->getUserValue($user, false);
53
+}
54
+?></p>                     
49 55
                                         <?php endif; ?>
50 56
                                     </div>
51 57
                                 <?php endif; ?>
Please login to merge, or discard this patch.
views/user/profile/_layout.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,9 +18,12 @@
 block discarded – undo
18 18
             <div class="col-md-10 layout-content-container">
19 19
                 <?= $content; ?>
20 20
             </div>
21
-        <?php else: ?>
21
+        <?php else {
22
+    : ?>
22 23
             <div class="col-md-7 layout-content-container">
23
-                <?= $content; ?>
24
+                <?= $content;
25
+}
26
+?>
24 27
             </div>
25 28
             <div class="col-md-3 layout-sidebar-container">
26 29
                 <?php
Please login to merge, or discard this patch.
views/layouts/main.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -98,8 +98,11 @@
 block discarded – undo
98 98
                             <!-- start: show content (and check, if exists a sublayout -->
99 99
                             <?php if (isset($this->context->subLayout) && $this->context->subLayout != "") : ?>
100 100
                             <?= $this->render($this->context->subLayout, array('content' => $content)); ?>
101
-                                <?php else: ?>
102
-                                <?= $content; ?>
101
+                                <?php else {
102
+    : ?>
103
+                                <?= $content;
104
+}
105
+?>
103 106
                                     <?php endif; ?>
104 107
                                     <!-- end: show content -->
105 108
 
Please login to merge, or discard this patch.