mirror of
https://github.com/renbaoshuo/S2OJ.git
synced 2024-11-08 14:48:41 +00:00
feat: add incomplete user profile warning
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
a483cc598b
commit
c35dd3f3fb
@ -30,6 +30,10 @@ class Auth {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!isset($myUser[$name])) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return $myUser[$name];
|
return $myUser[$name];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4,6 +4,18 @@ $parsedown = HTML::parsedown(['username_with_color' => true]);
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<?php if (Auth::check()) : ?>
|
<?php if (Auth::check()) : ?>
|
||||||
|
<?php if (!Auth::property('email')) : ?>
|
||||||
|
<div class="alert alert-warning d-flex align-items-center mb-2" role="alert">
|
||||||
|
<div class="flex-shrink-0 me-3">
|
||||||
|
<i class="fs-4 bi bi-exclamation-triangle-fill"></i>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="fw-bold mb-2">请完善个人资料</div>
|
||||||
|
<div class="small">您还没有填写您的电子邮件地址,请前往 <a href="/user/<?= Auth::id() ?>/edit">个人资料编辑</a> 页面补全信息,以便接收最新的安全和功能通知。</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php endif ?>
|
||||||
|
|
||||||
<?php if (!isset($groups_hidden)) : ?>
|
<?php if (!isset($groups_hidden)) : ?>
|
||||||
<?php $groups = UOJGroup::queryGroupsOfUser(Auth::user()); ?>
|
<?php $groups = UOJGroup::queryGroupsOfUser(Auth::user()); ?>
|
||||||
<?php if (!empty($groups)) : ?>
|
<?php if (!empty($groups)) : ?>
|
||||||
|
Loading…
Reference in New Issue
Block a user