Skip to content

Commit 4fff6c7

Browse files
authored
Fix package in user listing, plus 2FA and IP restriction (hestiacp#3312)
* Fix 2fa and ip list for users * Fix system package in user list
1 parent 6605f7b commit 4fff6c7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

web/templates/pages/edit_user.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ class="<?= $v_status ?>"
121121
</label>
122122
</div>
123123
<?php } ?>
124-
<div x-cloak x-show="loginDisabled" id="password-options">
124+
<div x-cloak x-show="!loginDisabled" id="password-options">
125125
<div class="form-check u-mt15">
126126
<input class="form-check-input" type="checkbox" name="v_twofa" id="v_twofa" <?php if(!empty($v_twofa)) echo 'checked' ?>>
127127
<label for="v_twofa">
@@ -134,7 +134,7 @@ class="<?= $v_status ?>"
134134
<div><img class="qr-code" src="<?= htmlentities($v_qrcode) ?>" alt=""></div>
135135
<?php } ?>
136136
</div>
137-
<div x-cloak x-show="loginDisabled" id="password-options-ip">
137+
<div x-cloak x-show="!loginDisabled" id="password-options-ip">
138138
<div class="form-check">
139139
<input x-model="useIpAllowList" class="form-check-input" type="checkbox" name="v_login_use_iplist" id="v_login_use_iplist">
140140
<label for="v_login_use_iplist">

web/templates/pages/list_user.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@
157157
<!-- END QUICK ACTION TOOLBAR AREA -->
158158
<div class="clearfix l-unit__stat-col--left u-text-center">
159159
<b>
160-
<?php if ($data[$key]["PACKAGE"] === "default") { ?>
160+
<?php if ($data[$key]["PACKAGE"] === "system") { ?>
161161
<?= $data[$key]["PACKAGE"] ?>
162162
<?php } else { ?>
163163
<a href="/edit/package/?package=<?= $data[$key]["PACKAGE"] ?>&token=<?= $_SESSION["token"] ?>" title="<?= _("Edit Package") ?>"><?= $data[$key]["PACKAGE"] ?></a>

0 commit comments

Comments
 (0)