feat: add links to legal docs, force users to accept legal docs

This commit is contained in:
Miguel Nogueira 2022-04-04 11:03:09 +01:00
parent 2c63c2265d
commit e8cdc7c710
10 changed files with 25 additions and 28 deletions

View File

@ -106,6 +106,7 @@ class RegisterController extends Controller
'uuid' => (Options::getOption('requireGameLicense') && Options::getOption('currentGame') == 'MINECRAFT') ? ['required', 'string', 'unique:users', 'min:32', 'max:32'] : ['nullable', 'string'], 'uuid' => (Options::getOption('requireGameLicense') && Options::getOption('currentGame') == 'MINECRAFT') ? ['required', 'string', 'unique:users', 'min:32', 'max:32'] : ['nullable', 'string'],
'name' => ['required', 'string', 'max:255'], 'name' => ['required', 'string', 'max:255'],
'email' => ['required', 'string', 'email', 'max:255', 'unique:users'], 'email' => ['required', 'string', 'email', 'max:255', 'unique:users'],
'acceptTerms' => ['required', 'accepted'],
'password' => $password, 'password' => $password,
], [ ], [
'uuid.required' => 'Please enter a valid (and Premium) Minecraft username! We do not support cracked users.', 'uuid.required' => 'Please enter a valid (and Premium) Minecraft username! We do not support cracked users.',

View File

@ -2,14 +2,11 @@
return [ return [
'2fa_txt' => '', '2fa_txt' => '',
'choose_app' => '',
'dashboard' => '', 'dashboard' => '',
'details_m_title' => '', 'details_m_title' => '',
'dispatch_event' => '',
'edt_action' => '', 'edt_action' => '',
'global_error' => '', 'global_error' => '',
'global_success' => '', 'global_success' => '',
'modal_close' => '',
'open' => '', 'open' => '',
'ppolicy' => '', 'ppolicy' => '',
'profile' => [ 'profile' => [

View File

@ -2,14 +2,11 @@
return [ return [
'2fa_txt' => '', '2fa_txt' => '',
'choose_app' => '',
'dashboard' => '', 'dashboard' => '',
'details_m_title' => '', 'details_m_title' => '',
'dispatch_event' => '',
'edt_action' => '', 'edt_action' => '',
'global_error' => '', 'global_error' => '',
'global_success' => '', 'global_success' => '',
'modal_close' => '',
'open' => '', 'open' => '',
'ppolicy' => '', 'ppolicy' => '',
'profile' => [ 'profile' => [

View File

@ -2,14 +2,11 @@
return [ return [
'2fa_txt' => '', '2fa_txt' => '',
'choose_app' => '',
'dashboard' => '', 'dashboard' => '',
'details_m_title' => '', 'details_m_title' => '',
'dispatch_event' => '',
'edt_action' => '', 'edt_action' => '',
'global_error' => '', 'global_error' => '',
'global_success' => '', 'global_success' => '',
'modal_close' => '',
'open' => '', 'open' => '',
'ppolicy' => '', 'ppolicy' => '',
'profile' => [ 'profile' => [

View File

@ -13,7 +13,7 @@
<div class="brand-wrapper"> <div class="brand-wrapper">
<img src="{{ config('adminlte.logo_img') }}" alt="logo" class="logo">{{ config('adminlte.logo') }} <img src="{{ config('adminlte.logo_img') }}" alt="logo" class="logo">{{ config('adminlte.logo') }}
</div> </div>
<p class="login-card-description">{{__('messages.2fa_txt')}}</p> <p class="login-card-description">{{__('Multi-factor authentication is enabled for your account.')}}</p>
<form action="{{ route('verify2FA') }}" method="POST" id="verify"> <form action="{{ route('verify2FA') }}" method="POST" id="verify">
@csrf @csrf
<div class="form-group"> <div class="form-group">
@ -24,8 +24,9 @@
</form> </form>
<p class="login-card-footer-text">{{__("Don't know the code?")}} <a href="{{ route('logout') }}" class="text-reset">{{__('Cancel sign in (sign out)')}}</a></p> <p class="login-card-footer-text">{{__("Don't know the code?")}} <a href="{{ route('logout') }}" class="text-reset">{{__('Cancel sign in (sign out)')}}</a></p>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('Terms of Service')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
<a href="#!">{{__('Privacy Policy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
</nav> </nav>
</div> </div>
</div> </div>

View File

@ -13,7 +13,7 @@
<div class="brand-wrapper"> <div class="brand-wrapper">
<img src="{{ config('adminlte.logo_img') }}" alt="logo" class="logo rounded mr-2">{{ config('adminlte.logo') }} <img src="{{ config('adminlte.logo_img') }}" alt="logo" class="logo rounded mr-2">{{ config('adminlte.logo') }}
</div> </div>
<p class="login-card-description">{{__('messages.signin_cta')}}</p> <p class="login-card-description">{{__('Sign in to your account')}}</p>
<form action="{{ route('login') }}" method="POST" id="loginForm"> <form action="{{ route('login') }}" method="POST" id="loginForm">
@csrf @csrf
@if ($demoActive) @if ($demoActive)
@ -49,9 +49,9 @@
<a href="{{ route('password.request') }}" class="forgot-password-link">{{__('Forgot password?')}}</a> <a href="{{ route('password.request') }}" class="forgot-password-link">{{__('Forgot password?')}}</a>
<p class="login-card-footer-text">{{__("Don't have an account?")}} <a href="{{ route('register') }}" class="text-reset">{{__('Sign up here')}}</a></p> <p class="login-card-footer-text">{{__("Don't have an account?")}} <a href="{{ route('register') }}" class="text-reset">{{__('Sign up here')}}</a></p>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('Terms of Service')}}</a> <a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
<a href="#!">{{__('Privacy Policy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="#!">{{__('Community Guidelines')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
</nav> </nav>
</div> </div>

View File

@ -31,9 +31,9 @@
</form> </form>
<a href="{{ route('login') }}">{{__('Back to login')}}</a> <a href="{{ route('login') }}">{{__('Back to login')}}</a>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('Terms of Service')}}</a> <a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
<a href="#!">{{__('Privacy Policy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="#!">{{__('Community Guidelines')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
</nav> </nav>
</div> </div>

View File

@ -70,9 +70,9 @@
</form> </form>
<a href="{{ route('login') }}">{{__('Back to sign in')}}</a> <a href="{{ route('login') }}">{{__('Back to sign in')}}</a>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('Terms of Service')}}</a> <a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
<a href="#!">{{__('Privacy Policy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="#!">{{__('Community Guidelines')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
</nav> </nav>
</div> </div>

View File

@ -85,13 +85,17 @@
</div> </div>
@endif @endif
<div class="form-group mt-3">
<label for="legal"><input type="checkbox" name="acceptTerms"> {!! __('I am 13 years of age or older and have read and agree with the <a href=":communityGuidelinesUrlConfigValue" target="_blank">Community Guidelines</a>, <a href=":privacyPolicyUrlConfigValue" target="_blank">Privacy Policy</a> and <a href=":termsUrlConfigValue" target="_blank">Terms of Service</a> set forth.', ['communityGuidelinesUrlConfigValue' => config('app.guidelines_url'), 'privacyPolicyUrlConfigValue' => config('app.privacy_url'), 'termsUrlConfigValue' => config('app.terms_url')]) !!}</label>
</div>
<input name="register" id="register" class="btn btn-block login-btn mb-4" type="submit" value="{{__('Sign up')}}"> <input name="register" id="register" class="btn btn-block login-btn mb-4" type="submit" value="{{__('Sign up')}}">
</form> </form>
<p class="login-card-footer-text">{{__('Have an account with us?')}} <a href="{{ route('login') }}" class="text-reset">{{__('Sign in here')}}</a></p> <p class="login-card-footer-text">{{__('Have an account with us?')}} <a href="{{ route('login') }}" class="text-reset">{{__('Sign in here')}}</a></p>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('Terms of Service')}}</a> <a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
<a href="#!">{{__('Privacy Policy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="#!">{{__('Community Guidelines')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
</nav> </nav>
</div> </div>
</div> </div>

View File

@ -30,9 +30,9 @@
</form> </form>
<nav class="login-card-footer-nav"> <nav class="login-card-footer-nav">
<a href="#!">{{__('messages.terms')}}</a> <a href="{{ config('app.terms_url') }}">{{__('Terms of Service')}}</a>
<a href="#!">{{__('messages.ppolicy')}}</a> <a href="{{ config('app.privacy_url') }}">{{__('Privacy Policy')}}</a>
<a href="#!">{{__('Community Guidelines')}}</a> <a href="{{ config('app.guidelines_url') }}">{{__('Community Guidelines')}}</a>
</nav> </nav>
</div> </div>