Add translations for database overview

This commit is contained in:
Dane Everitt 2017-01-17 19:46:42 -05:00
parent f6600f447f
commit 542b919bd1
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
3 changed files with 24 additions and 14 deletions

View file

@ -22,5 +22,14 @@ return [
'conn_addr' => 'Connection Address', 'conn_addr' => 'Connection Address',
'warning' => 'Ensure that your client is set to use SFTP and not FTP or FTPS for connections, there is a difference between the protocols.', 'warning' => 'Ensure that your client is set to use SFTP and not FTP or FTPS for connections, there is a difference between the protocols.',
], ],
] 'database' => [
'header' => 'Databases',
'header_sub' => 'All databases available for this server.',
'your_dbs' => 'Your Databases',
'host' => 'MySQL Host',
'reset_password' => 'Reset Password',
'no_dbs' => 'There are no databases listed for this server.',
'add_db' => 'Add a new database.',
],
],
]; ];

View file

@ -39,4 +39,5 @@ return [
'required' => 'Required', 'required' => 'Required',
'port' => 'Port', 'port' => 'Port',
'username' => 'Username', 'username' => 'Username',
'database' => 'Database',
]; ];

View file

@ -20,16 +20,16 @@
@extends('layouts.master') @extends('layouts.master')
@section('title') @section('title')
Databases @lang('server.config.database.header')
@endsection @endsection
@section('content-header') @section('content-header')
<h1>Databases<small>All databases available for this server.</small></h1> <h1>@lang('server.config.database.header')<small>@lang('server.config.database.header_sub')</small></h1>
<ol class="breadcrumb"> <ol class="breadcrumb">
<li><a href="{{ route('index') }}">{{ trans('strings.home') }}</a></li> <li><a href="{{ route('index') }}">@lang('strings.home')</a></li>
<li><a href="{{ route('server.index', $server->uuidShort) }}">{{ $server->name }}</a></li> <li><a href="{{ route('server.index', $server->uuidShort) }}">{{ $server->name }}</a></li>
<li>{{ trans('strings.configuration') }}</li> <li>@lang('navigation.server.configuration')</li>
<li class="active">{{ trans('strings.databases') }}</li> <li class="active">@lang('navigation.server.databases')</li>
</ol> </ol>
@endsection @endsection
@ -38,17 +38,17 @@
<div class="col-xs-12"> <div class="col-xs-12">
<div class="box"> <div class="box">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">Your Databases</h3> <h3 class="box-title">@lang('server.config.database.your_dbs')</h3>
</div> </div>
@if(count($databases) > 0) @if(count($databases) > 0)
<div class="box-body table-responsive no-padding"> <div class="box-body table-responsive no-padding">
<table class="table table-hover"> <table class="table table-hover">
<tbody> <tbody>
<tr> <tr>
<th>Database</th> <th>@lang('strings.database')</th>
<th>Username</th> <th>@lang('strings.username')</th>
<th>Password</th> <th>@lang('strings.password')</th>
<th>MySQL Host</th> <th>@lang('server.config.database.host')</th>
</tr> </tr>
@foreach($databases as $database) @foreach($databases as $database)
<tr> <tr>
@ -56,7 +56,7 @@
<td>{{ $database->username }}</td> <td>{{ $database->username }}</td>
<td><code>{{ Crypt::decrypt($database->password) }}</code> <td><code>{{ Crypt::decrypt($database->password) }}</code>
@can('reset-db-password', $server) @can('reset-db-password', $server)
<button class="btn btn-xs btn-primary pull-right" data-action="reset-database-password" data-id="{{ $database->id }}"><i class="fa fa-fw fa-refresh"></i> Reset Password</button> <button class="btn btn-xs btn-primary pull-right" data-action="reset-database-password" data-id="{{ $database->id }}"><i class="fa fa-fw fa-refresh"></i> @lang('server.config.database.reset_password')</button>
@endcan @endcan
</td> </td>
<td><code>{{ $database->a_host }}:{{ $database->a_port }}</code></td> <td><code>{{ $database->a_host }}:{{ $database->a_port }}</code></td>
@ -68,12 +68,12 @@
@else @else
<div class="box-body"> <div class="box-body">
<div class="callout callout-info callout-nomargin"> <div class="callout callout-info callout-nomargin">
There are no databases listed for this server. @lang('server.config.database.no_dbs')
@if(Auth::user()->root_admin === 1) @if(Auth::user()->root_admin === 1)
<a href="{{ route('admin.servers.view', [ <a href="{{ route('admin.servers.view', [
'id' => $server->id, 'id' => $server->id,
'tab' => 'tab_database' 'tab' => 'tab_database'
]) }}" target="_blank">Add a new database.</a> ]) }}" target="_blank">@lang('server.config.database.add_db')</a>
@endif @endif
</div> </div>
</div> </div>