blue-twilight/resources/views/themes/base/admin/settings.blade.php

113 lines
6.7 KiB
PHP
Raw Normal View History

@extends('themes.base.layout')
@section('title', trans('admin.settings_title'))
@section('content')
<div class="container">
<div class="row">
<div class="col-xs-12">
<h1>@yield('title')</h1>
<hr/>
{!! Form::model($config, ['route' => 'admin.saveSettings', 'method' => 'POST']) !!}
<div>
{{-- Nav tabs --}}
<ul class="nav nav-tabs" role="tablist">
<li role="presentation" class="active"><a href="#general-tab" aria-controls="general-tab" role="tab" data-toggle="tab"><i class="fa fa-fw fa-info-circle"></i> General</a></li>
<li role="presentation"><a href="#email-tab" aria-controls="email-tab" role="tab" data-toggle="tab"><i class="fa fa-fw fa-envelope"></i> E-mail</a></li>
<li role="presentation"><a href="#security-tab" aria-controls="security-tab" role="tab" data-toggle="tab"><i class="fa fa-fw fa-lock"></i> Security</a></li>
</ul>
{{-- Tab panes --}}
<div class="tab-content">
<div role="tabpanel" class="tab-pane active" id="general-tab">
<div class="form-group">
{!! Form::label('app_name', 'Gallery name:', ['class' => 'control-label']) !!}
{!! Form::text('app_name', old('app_name'), ['class' => 'form-control']) !!}
</div>
<div class="row">
<div class="col-xs-12 col-sm-4">
<div class="form-group">
{!! Form::label('date_format', 'Date format:', ['class' => 'control-label']) !!}
{!! Form::select('date_format', $date_formats, old('date_format'), ['class' => 'form-control']) !!}
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12 col-sm-4">
<div class="form-group">
{!! Form::label('theme', 'Theme:', ['class' => 'control-label']) !!}
{!! Form::select('theme', $theme_names, old('theme'), ['class' => 'form-control']) !!}
</div>
</div>
</div>
</div>
<div role="tabpanel" class="tab-pane" id="email-tab">
<div class="form-group">
{!! Form::label('sender_name', 'Sender name:', ['class' => 'control-label']) !!}
{!! Form::text('sender_name', old('sender_name'), ['class' => 'form-control']) !!}
</div>
<div class="form-group">
{!! Form::label('sender_address', 'Sender address:', ['class' => 'control-label']) !!}
{!! Form::text('sender_address', old('sender_address'), ['class' => 'form-control']) !!}
</div>
<hr/>
<p style="margin-bottom: 15px;">Configure your SMTP server using the settings below.</p>
<div class="form-group">
{!! Form::label('smtp_server', 'Hostname:', ['class' => 'control-label']) !!}
{!! Form::text('smtp_server', old('smtp_server'), ['class' => 'form-control']) !!}
</div>
<div class="form-group">
{!! Form::label('smtp_port', 'Port:', ['class' => 'control-label']) !!}
{!! Form::text('smtp_port', old('smtp_port'), ['class' => 'form-control']) !!}
</div>
<div class="form-group">
{!! Form::label('smtp_username', 'Username:', ['class' => 'control-label']) !!}
{!! Form::text('smtp_username', old('smtp_username'), ['class' => 'form-control']) !!}
</div>
<div class="form-group">
{!! Form::label('smtp_password', 'Password:', ['class' => 'control-label']) !!}
{!! Form::text('smtp_password', old('smtp_password'), ['class' => 'form-control']) !!}
</div>
</div>
<div role="tabpanel" class="tab-pane" id="security-tab">
<div class="checkbox">
<label>
<input type="checkbox" name="allow_self_registration" @if (UserConfig::get('allow_self_registration') == 1)checked="checked"@endif>
<strong>Allow self-registration</strong><br/>
With this option enabled, users can sign up for their own &quot;visitor&quot; accounts to comment on photos.
</label>
</div>
<div class="checkbox" style="margin-top: 20px;">
<label>
<input type="checkbox" name="require_email_verification" @if (UserConfig::get('require_email_verification') == 1)checked="checked"@endif>
<strong>Require e-mail verification for self-registered accounts</strong><br/>
<span class="text-danger">It is strongly recommended to enable this option.</span>
</label>
</div>
</div>
</div>
</div>
<div class="text-right" style="margin-top: 15px;">
<a href="{{ route('admin') }}" class="btn btn-default">@lang('forms.cancel_action')</a>
{!! Form::submit(trans('admin.settings_save_action'), ['class' => 'btn btn-success']) !!}
</div>
{!! Form::close() !!}
</div>
</div>
</div>
@endsection