改进 实名认证位置以及提示
This commit is contained in:
parent
4b0acbc74c
commit
2c04c3144b
@ -1,15 +1,6 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
|
|
||||||
@if(!auth('web')->user()->isRealNamed())
|
|
||||||
<x-alert-warning>
|
|
||||||
<div>
|
|
||||||
部分功能需要您<a href="{{ route('real_name.create') }}">实人认证</a>。
|
|
||||||
</div>
|
|
||||||
</x-alert-warning>
|
|
||||||
@endif
|
|
||||||
|
|
||||||
@if (session('token'))
|
@if (session('token'))
|
||||||
<x-alert-warning>
|
<x-alert-warning>
|
||||||
<div>
|
<div>
|
||||||
|
@ -39,7 +39,6 @@
|
|||||||
<!-- Left Side Of Navbar -->
|
<!-- Left Side Of Navbar -->
|
||||||
<ul class="navbar-nav me-auto">
|
<ul class="navbar-nav me-auto">
|
||||||
@auth('web')
|
@auth('web')
|
||||||
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link" href="{{ route('index') }}">授权</a>
|
<a class="nav-link" href="{{ route('index') }}">授权</a>
|
||||||
</li>
|
</li>
|
||||||
@ -110,6 +109,9 @@
|
|||||||
{{ __('Reset Password') }}
|
{{ __('Reset Password') }}
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
|
@if(!auth('web')->user()->isRealNamed())
|
||||||
|
<a class="dropdown-item" href="{{ route('real_name.create') }}">实名认证</a>
|
||||||
|
@endif
|
||||||
|
|
||||||
@if (!session('auth.password_confirmed_at'))
|
@if (!session('auth.password_confirmed_at'))
|
||||||
<a class="dropdown-item" href="{{ route('password.confirm') }}">
|
<a class="dropdown-item" href="{{ route('password.confirm') }}">
|
||||||
@ -173,6 +175,17 @@ class="d-none">
|
|||||||
nav.classList.remove('bg-body');
|
nav.classList.remove('bg-body');
|
||||||
|
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
|
// 根据 URL 自动激活导航栏
|
||||||
|
const navLinks = document.querySelectorAll('#nav .nav-link, #nav .dropdown-item');
|
||||||
|
const currentUrl = window.location.href;
|
||||||
|
|
||||||
|
for (let i = 0; i < navLinks.length; i++) {
|
||||||
|
const navLink = navLinks[i];
|
||||||
|
if (currentUrl === navLink.href) {
|
||||||
|
navLink.classList.add('active');
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
Loading…
Reference in New Issue
Block a user