diff options
Diffstat (limited to 'resources')
| -rw-r--r-- | resources/views/admin/analytics-edit.phtml (renamed from resources/views/admin/analytics/edit.phtml) | 2 | ||||
| -rw-r--r-- | resources/views/admin/analytics/index.phtml | 36 | ||||
| -rw-r--r-- | resources/views/admin/components.phtml | 13 | ||||
| -rw-r--r-- | resources/views/admin/control-panel.phtml | 27 | ||||
| -rw-r--r-- | resources/views/admin/modules.phtml | 7 | ||||
| -rw-r--r-- | resources/views/components/badge.phtml | 5 | ||||
| -rw-r--r-- | resources/views/modules/bing-webmaster-tools/form.phtml (renamed from resources/views/admin/analytics/bing-webmaster-form.phtml) | 3 | ||||
| -rw-r--r-- | resources/views/modules/bing-webmaster-tools/snippet.phtml (renamed from resources/views/admin/analytics/bing-webmaster-snippet.phtml) | 0 | ||||
| -rw-r--r-- | resources/views/modules/google-analytics/form.phtml (renamed from resources/views/admin/analytics/google-analytics-form.phtml) | 4 | ||||
| -rw-r--r-- | resources/views/modules/google-analytics/snippet.phtml (renamed from resources/views/admin/analytics/google-analytics-snippet.phtml) | 0 | ||||
| -rw-r--r-- | resources/views/modules/google-webmaster-tools/form.phtml (renamed from resources/views/admin/analytics/google-webmaster-form.phtml) | 3 | ||||
| -rw-r--r-- | resources/views/modules/google-webmaster-tools/snippet.phtml (renamed from resources/views/admin/analytics/google-webmaster-snippet.phtml) | 0 | ||||
| -rw-r--r-- | resources/views/modules/matomo-analytics/form.phtml (renamed from resources/views/admin/analytics/matomo-analytics-form.phtml) | 3 | ||||
| -rw-r--r-- | resources/views/modules/matomo-analytics/snippet.phtml (renamed from resources/views/admin/analytics/matomo-analytics-snippet.phtml) | 0 | ||||
| -rw-r--r-- | resources/views/modules/statcounter/form.phtml (renamed from resources/views/admin/analytics/statcounter-form.phtml) | 4 | ||||
| -rw-r--r-- | resources/views/modules/statcounter/snippet.phtml (renamed from resources/views/admin/analytics/statcounter-snippet.phtml) | 0 |
16 files changed, 62 insertions, 45 deletions
diff --git a/resources/views/admin/analytics/edit.phtml b/resources/views/admin/analytics-edit.phtml index ce9879b5c1..fc9b1353ba 100644 --- a/resources/views/admin/analytics/edit.phtml +++ b/resources/views/admin/analytics-edit.phtml @@ -1,6 +1,6 @@ <?php use Fisharebest\Webtrees\I18N; ?> -<?= view('components/breadcrumbs', ['links' => [route('admin-control-panel') => I18N::translate('Control panel'), route('analytics') => I18N::translate('Tracking and analytics'), $title]]) ?> +<?= view('components/breadcrumbs', ['links' => [route('admin-control-panel') => I18N::translate('Control panel'), route('modules') => I18N::translate('Modules'), route('analytics') => I18N::translate('Tracking and analytics'), $title]]) ?> <h1><?= $title ?></h1> diff --git a/resources/views/admin/analytics/index.phtml b/resources/views/admin/analytics/index.phtml deleted file mode 100644 index 1e31c27075..0000000000 --- a/resources/views/admin/analytics/index.phtml +++ /dev/null @@ -1,36 +0,0 @@ -<?php use Fisharebest\Webtrees\I18N; ?> -<?php use Fisharebest\Webtrees\Site; ?> - -<?= view('components/breadcrumbs', ['links' => [route('admin-control-panel') => I18N::translate('Control panel'), $title]]) ?> - -<h1><?= $title ?></h1> - -<p> - <?= I18N::translate('If you use one of the following tracking and analytics services, webtrees can add the tracking codes automatically.') ?> -</p> - -<p> - <?= I18N::translate('Tracking and analytics are not added to the control panel.') ?> -</p> - -<p> - <?= I18N::translate('Site verification codes do not work when webtrees is installed in a subfolder.') ?> -</p> - -<?php foreach ($modules as $module) : ?> - <h2> - <?= e($module->title()) ?> - </h2> - - <p> - <a class="btn btn-link" href="<?= e(route('analytics-edit', ['module' => $module->name()])) ?>"> - <?= view('icons/preferences') ?> - <?= I18N::translate('Preferences') ?> - </a> - - <a class="btn btn-link" href="<?= e($module->analyticsHomePageUrl()) ?>"> - <?= view('icons/information') ?> - <?= e($module->analyticsHomePageUrl()) ?> - </a> - </p> -<?php endforeach ?> diff --git a/resources/views/admin/components.phtml b/resources/views/admin/components.phtml index b90650c0d5..62aea3ed34 100644 --- a/resources/views/admin/components.phtml +++ b/resources/views/admin/components.phtml @@ -1,13 +1,16 @@ <?php use Fisharebest\Webtrees\Bootstrap4; ?> <?php use Fisharebest\Webtrees\Functions\FunctionsEdit; ?> <?php use Fisharebest\Webtrees\I18N; ?> -<?php use Fisharebest\Webtrees\Module\ModuleConfigInterface; -use Fisharebest\Webtrees\View; ?> +<?php use Fisharebest\Webtrees\Module\ModuleExternalUrlInterface; ?> +<?php use Fisharebest\Webtrees\Module\ModuleConfigInterface; ?> +<?php use Fisharebest\Webtrees\View; ?> <?= view('components/breadcrumbs', ['links' => [route('admin-control-panel') => I18N::translate('Control panel'), route('modules') => I18N::translate('Modules'), $title]]) ?> <h1><?= $title ?></h1> +<p><?= $description ?></p> + <form method="post"> <?= csrf_field() ?> <table class="table table-bordered wt-table-menu"> @@ -41,6 +44,12 @@ use Fisharebest\Webtrees\View; ?> </span> </a> <?php endif ?> + <?php if ($module instanceof ModuleExternalUrlInterface) : ?> + <br> + <a href="<?= e($module->externalUrl()) ?>"> + <?= e($module->externalUrl()) ?> + </a> + <?php endif ?> </th> <td class="text-center"> diff --git a/resources/views/admin/control-panel.phtml b/resources/views/admin/control-panel.phtml index 43b04710d1..d4dbe6313f 100644 --- a/resources/views/admin/control-panel.phtml +++ b/resources/views/admin/control-panel.phtml @@ -63,12 +63,6 @@ <?= I18N::translate('Languages') ?> </a> </li> - <li> - <span class="fa-li"><?= view('icons/wizard') ?></span> - <a href="<?= e(route('analytics')) ?>"> - <?= I18N::translate('Tracking and analytics') ?> - </a> - </li> </ul> </div> <div class="col-sm-6"> @@ -306,11 +300,13 @@ <a href="<?= e(route('menus')) ?>"> <?= I18N::translate('Menus') ?> </a> + <?= view('components/badge', ['count' => $menu_modules->count()]) ?> </li> <li> <span class="fa-li"><?= view('icons/tab') ?></span> <a href="<?= e(route('tabs')) ?>"> <?= I18N::translate('Tabs') ?> + <?= view('components/badge', ['count' => $tab_modules->count()]) ?> </a> </li> <li> @@ -318,30 +314,49 @@ <a href="<?= e(route('blocks')) ?>"> <?= I18N::translate('Blocks') ?> </a> + <?= view('components/badge', ['count' => $block_modules->count()]) ?> </li> <li> <span class="fa-li"><?= view('icons/sidebar') ?></span> <a href="<?= e(route('sidebars')) ?>"> <?= I18N::translate('Sidebars') ?> </a> + <?= view('components/badge', ['count' => $sidebar_modules->count()]) ?> </li> <li> <span class="fa-li"><?= view('icons/chart') ?></span> <a href="<?= e(route('charts')) ?>"> <?= I18N::translate('Charts') ?> </a> + <?= view('components/badge', ['count' => $chart_modules->count()]) ?> </li> <li> <span class="fa-li"><?= view('icons/report') ?></span> <a href="<?= e(route('reports')) ?>"> <?= I18N::translate('Reports') ?> </a> + <?= view('components/badge', ['count' => $report_modules->count()]) ?> </li> <li> <span class="fa-li"><?= view('icons/footer') ?></span> <a href="<?= e(route('footers')) ?>"> <?= I18N::translate('Footers') ?> </a> + <?= view('components/badge', ['count' => $footer_modules->count()]) ?> + </li> + <li> + <span class="fa-li"><?= view('icons/analytics') ?></span> + <a href="<?= e(route('analytics')) ?>"> + <?= I18N::translate('Tracking and analytics') ?> + </a> + <?= view('components/badge', ['count' => $analytics_modules->count()]) ?> + </li> + <li> + <span class="fa-li"><?= view('icons/history') ?></span> + <a href="<?= e(route('history')) ?>"> + <?= I18N::translate('Historic events') ?> + </a> + <?= view('components/badge', ['count' => $history_modules->count()]) ?> </li> </ul> </div> diff --git a/resources/views/admin/modules.phtml b/resources/views/admin/modules.phtml index 3fa125f73a..1e87715d58 100644 --- a/resources/views/admin/modules.phtml +++ b/resources/views/admin/modules.phtml @@ -5,6 +5,7 @@ <?php use Fisharebest\Webtrees\Module\ModuleChartInterface; ?> <?php use Fisharebest\Webtrees\Module\ModuleConfigInterface; ?> <?php use Fisharebest\Webtrees\Module\ModuleCustomInterface; ?> +<?php use Fisharebest\Webtrees\Module\ModuleExternalUrlInterface; ?> <?php use Fisharebest\Webtrees\Module\ModuleFooterInterface; ?> <?php use Fisharebest\Webtrees\Module\ModuleHistoricEventsInterface; ?> <?php use Fisharebest\Webtrees\Module\ModuleMenuInterface; ?> @@ -120,6 +121,12 @@ </a> <?php endif ?> <?php endif ?> + <?php if ($module instanceof ModuleExternalUrlInterface) : ?> + <br> + <a href="<?= e($module->externalUrl()) ?>"> + <?= e($module->externalUrl()) ?> + </a> + <?php endif ?> </td> <td class="text-center text-muted" title="<?= I18N::translate('Preferences') ?>"> <?php if ($module instanceof ModuleConfigInterface) : ?> diff --git a/resources/views/components/badge.phtml b/resources/views/components/badge.phtml new file mode 100644 index 0000000000..391ab5fc9b --- /dev/null +++ b/resources/views/components/badge.phtml @@ -0,0 +1,5 @@ +<?php use Fisharebest\Webtrees\I18N; ?> + +<span class="badge badge-<?= $context ?? 'primary' ?>"> + <?= I18N::number($count) ?> +</span> diff --git a/resources/views/admin/analytics/bing-webmaster-form.phtml b/resources/views/modules/bing-webmaster-tools/form.phtml index e483ede59a..8b41a3eb91 100644 --- a/resources/views/admin/analytics/bing-webmaster-form.phtml +++ b/resources/views/modules/bing-webmaster-tools/form.phtml @@ -10,3 +10,6 @@ </div> </div> +<p> + <?= I18N::translate('Site verification codes do not work when webtrees is installed in a subfolder.') ?> +</p> diff --git a/resources/views/admin/analytics/bing-webmaster-snippet.phtml b/resources/views/modules/bing-webmaster-tools/snippet.phtml index f78fb17c81..f78fb17c81 100644 --- a/resources/views/admin/analytics/bing-webmaster-snippet.phtml +++ b/resources/views/modules/bing-webmaster-tools/snippet.phtml diff --git a/resources/views/admin/analytics/google-analytics-form.phtml b/resources/views/modules/google-analytics/form.phtml index a246214c5c..a441cfcd31 100644 --- a/resources/views/admin/analytics/google-analytics-form.phtml +++ b/resources/views/modules/google-analytics/form.phtml @@ -9,3 +9,7 @@ <input type="text" class="form-control" id="GOOGLE_ANALYTICS_ID" name="GOOGLE_ANALYTICS_ID" value="<?= e($GOOGLE_ANALYTICS_ID ?? '') ?>" placeholder="UA-12345-6" maxlength="255" pattern="UA-[0-9]+-[0-9]+"> </div> </div> + +<p> + <?= I18N::translate('Tracking and analytics are not added to the control panel.') ?> +</p> diff --git a/resources/views/admin/analytics/google-analytics-snippet.phtml b/resources/views/modules/google-analytics/snippet.phtml index e55b77b528..e55b77b528 100644 --- a/resources/views/admin/analytics/google-analytics-snippet.phtml +++ b/resources/views/modules/google-analytics/snippet.phtml diff --git a/resources/views/admin/analytics/google-webmaster-form.phtml b/resources/views/modules/google-webmaster-tools/form.phtml index 4e3a7bd731..ba9baa8cca 100644 --- a/resources/views/admin/analytics/google-webmaster-form.phtml +++ b/resources/views/modules/google-webmaster-tools/form.phtml @@ -10,3 +10,6 @@ </div> </div> +<p> + <?= I18N::translate('Site verification codes do not work when webtrees is installed in a subfolder.') ?> +</p> diff --git a/resources/views/admin/analytics/google-webmaster-snippet.phtml b/resources/views/modules/google-webmaster-tools/snippet.phtml index 8728d9ada4..8728d9ada4 100644 --- a/resources/views/admin/analytics/google-webmaster-snippet.phtml +++ b/resources/views/modules/google-webmaster-tools/snippet.phtml diff --git a/resources/views/admin/analytics/matomo-analytics-form.phtml b/resources/views/modules/matomo-analytics/form.phtml index dcd4edfe92..8fce201551 100644 --- a/resources/views/admin/analytics/matomo-analytics-form.phtml +++ b/resources/views/modules/matomo-analytics/form.phtml @@ -19,3 +19,6 @@ </div> </div> +<p> + <?= I18N::translate('Tracking and analytics are not added to the control panel.') ?> +</p> diff --git a/resources/views/admin/analytics/matomo-analytics-snippet.phtml b/resources/views/modules/matomo-analytics/snippet.phtml index c81a17f402..c81a17f402 100644 --- a/resources/views/admin/analytics/matomo-analytics-snippet.phtml +++ b/resources/views/modules/matomo-analytics/snippet.phtml diff --git a/resources/views/admin/analytics/statcounter-form.phtml b/resources/views/modules/statcounter/form.phtml index 23a38294b0..3a64308348 100644 --- a/resources/views/admin/analytics/statcounter-form.phtml +++ b/resources/views/modules/statcounter/form.phtml @@ -18,3 +18,7 @@ <input type="text" class="form-control" id="STATCOUNTER_SECURITY_ID" name="STATCOUNTER_SECURITY_ID" value="<?= e($STATCOUNTER_SECURITY_ID ?? '') ?>" maxlength="255" pattern="[0-9a-zA-Z]+"> </div> </div> + +<p> + <?= I18N::translate('Tracking and analytics are not added to the control panel.') ?> +</p> diff --git a/resources/views/admin/analytics/statcounter-snippet.phtml b/resources/views/modules/statcounter/snippet.phtml index 13dfa49009..13dfa49009 100644 --- a/resources/views/admin/analytics/statcounter-snippet.phtml +++ b/resources/views/modules/statcounter/snippet.phtml |
