#77: Minor improvements to meta-data update page

This commit is contained in:
Andy Heathershaw 2018-07-12 06:09:28 +01:00
parent 06869a157c
commit 309d97cb75
3 changed files with 7 additions and 6 deletions

View File

@ -118,7 +118,8 @@ class DefaultController extends Controller
$labelCount = Label::all()->count(); $labelCount = Label::all()->count();
$userCount = User::where('is_activated', true)->count(); $userCount = User::where('is_activated', true)->count();
$metadataUpgradeNeeded = Photo::min('metadata_version') < PhotoService::METADATA_VERSION; $minMetadataVersion = Photo::min('metadata_version');
$metadataUpgradeNeeded = $minMetadataVersion > 0 && $minMetadataVersion < PhotoService::METADATA_VERSION;
// Default to a supported function call to get the OS version // Default to a supported function call to get the OS version
$osVersion = sprintf('%s %s', php_uname('s'), php_uname('r')); $osVersion = sprintf('%s %s', php_uname('s'), php_uname('r'));

View File

@ -141,7 +141,7 @@ return [
'panel_header' => 'Manage' 'panel_header' => 'Manage'
], ],
'metadata_upgrade' => [ 'metadata_upgrade' => [
'can_be_upgraded' => 'Metadata can be updated (version :version_from --&gt; :version_to)', 'can_be_upgraded' => 'Metadata can be updated (version :version_from &raquo; :version_to)',
'confirm' => 'Are you sure you want to update the metadata of the :name album?', 'confirm' => 'Are you sure you want to update the metadata of the :name album?',
'intro' => 'Blue Twilight analyses your photos to capture metadata such as the camera and location used to capture the photo. Sometimes we capture more metadata than we have done previously, which requires your original photos to be re-analysed.', 'intro' => 'Blue Twilight analyses your photos to capture metadata such as the camera and location used to capture the photo. Sometimes we capture more metadata than we have done previously, which requires your original photos to be re-analysed.',
'intro_2' => 'This page shows you which of your albums contain photos that need to be re-analysed to get the latest metadata information.', 'intro_2' => 'This page shows you which of your albums contain photos that need to be re-analysed to get the latest metadata information.',

View File

@ -16,11 +16,8 @@
<i class="fa fa-fw fa-info"></i> @lang('admin.metadata_upgrade.intro') <i class="fa fa-fw fa-info"></i> @lang('admin.metadata_upgrade.intro')
</div> </div>
<p>@lang('admin.metadata_upgrade.intro_2')</p>
<p class="mb-4">@lang('admin.metadata_upgrade.intro_3')</p>
@if (count($albums) == 0) @if (count($albums) == 0)
<div class="text-center"> <div class="text-center mt-5">
<h4 class="text-danger"><b>@lang('admin.no_albums_title')</b></h4> <h4 class="text-danger"><b>@lang('admin.no_albums_title')</b></h4>
<p>@lang('admin.no_albums_text')</p> <p>@lang('admin.no_albums_text')</p>
<p style="margin-top: 40px;"> <p style="margin-top: 40px;">
@ -28,6 +25,9 @@
</p> </p>
</div> </div>
@else @else
<p>@lang('admin.metadata_upgrade.intro_2')</p>
<p class="mb-4">@lang('admin.metadata_upgrade.intro_3')</p>
<table class="table table-hover table-striped"> <table class="table table-hover table-striped">
<tbody> <tbody>
@foreach ($albums as $album) @foreach ($albums as $album)