1dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Bootstrap4; ?> 2dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\I18N; ?> 39e5cb8c9SGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleAnalyticsInterface; ?> 4dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleBlockInterface; ?> 5dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleChartInterface; ?> 6dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleConfigInterface; ?> 79cad7645SGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleCustomInterface; ?> 88e5c5efeSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleExternalUrlInterface; ?> 933c34396SGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleFooterInterface; ?> 10f3244202SGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleHistoricEventsInterface; ?> 1111eb8581SGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleLanguageInterface; ?> 1267992b6aSRichard Cissee<?php use Fisharebest\Webtrees\Module\ModuleListInterface; ?> 13dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleMenuInterface; ?> 14dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleReportInterface; ?> 15dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleSidebarInterface; ?> 16dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleTabInterface; ?> 17dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Module\ModuleThemeInterface; ?> 18dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\View; ?> 19dd6b2bfcSGreg Roach 20dd6b2bfcSGreg Roach<?= view('components/breadcrumbs', ['links' => [route('admin-control-panel') => I18N::translate('Control panel'), $title]]) ?> 21dd6b2bfcSGreg Roach 22dd6b2bfcSGreg Roach<h1><?= $title ?></h1> 23dd6b2bfcSGreg Roach 24dd6b2bfcSGreg Roach<?php foreach ($deleted_modules as $module_name) : ?> 25dd6b2bfcSGreg Roach <div class="alert alert-warning" role="alert"> 26244d9cdfSGreg Roach <form action="<?= e(route('delete-module-settings')) ?>" class="form-inline" method="POST"> 27dd6b2bfcSGreg Roach <?= csrf_field() ?> 28dd6b2bfcSGreg Roach <input type="hidden" name="module_name" value="<?= $module_name ?>"> 29dd6b2bfcSGreg Roach <?= I18N::translate('Preferences exist for the module “%s”, but this module no longer exists.', $module_name) ?> 3097c22350SGreg Roach <button type="submit" class="btn btn-secondary"> 31dd6b2bfcSGreg Roach <?= I18N::translate('Delete the preferences for this module.') ?> 32dd6b2bfcSGreg Roach </button> 33dd6b2bfcSGreg Roach </form> 34dd6b2bfcSGreg Roach </div> 35dd6b2bfcSGreg Roach<?php endforeach ?> 36dd6b2bfcSGreg Roach 37f70ab68bSGreg Roach<form method="POST"> 38dd6b2bfcSGreg Roach <input type="hidden" name="route" value="admin-update-module-status"> 39dd6b2bfcSGreg Roach <?= csrf_field() ?> 4049d6539eSGreg Roach <table class="table table-bordered table-hover table-sm table-module-administration" data-info="false" data-paging="false" data-state-save="true" data-filter="false"> 41dd6b2bfcSGreg Roach <caption class="sr-only"> 42dd6b2bfcSGreg Roach <?= I18N::translate('Module administration') ?> 43dd6b2bfcSGreg Roach </caption> 44dd6b2bfcSGreg Roach <thead> 45dd6b2bfcSGreg Roach <tr> 46dd6b2bfcSGreg Roach <th> 47dd6b2bfcSGreg Roach <?= I18N::translate('Module') ?> 48dd6b2bfcSGreg Roach </th> 49dd6b2bfcSGreg Roach <th> 50dd6b2bfcSGreg Roach <?= I18N::translate('Enabled') ?> 51dd6b2bfcSGreg Roach </th> 520cb66f86SGreg Roach <th data-orderable="false"> 53dd6b2bfcSGreg Roach <?= I18N::translate('Description') ?> 54dd6b2bfcSGreg Roach </th> 550cb66f86SGreg Roach <th title="<?= I18N::translate('Preferences') ?>"> 560cb66f86SGreg Roach <?= view('icons/preferences') ?> 570cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Preferences') ?></span> 58dd6b2bfcSGreg Roach </th> 590cb66f86SGreg Roach <th title="<?= I18N::translate('Menus') ?>"> 600cb66f86SGreg Roach <?= view('icons/menu') ?> 610cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Menus') ?></span> 62dd6b2bfcSGreg Roach </th> 630cb66f86SGreg Roach <th title="<?= I18N::translate('Tabs') ?>"> 640cb66f86SGreg Roach <?= view('icons/tab') ?> 650cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Tabs') ?></span> 66dd6b2bfcSGreg Roach </th> 670cb66f86SGreg Roach <th title="<?= I18N::translate('Sidebars') ?>"> 680cb66f86SGreg Roach <?= view('icons/sidebar') ?> 690cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Sidebars') ?></span> 70dd6b2bfcSGreg Roach </th> 710cb66f86SGreg Roach <th title="<?= I18N::translate('Blocks') ?>"> 720cb66f86SGreg Roach <?= view('icons/block') ?> 730cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Blocks') ?></span> 74dd6b2bfcSGreg Roach </th> 750cb66f86SGreg Roach <th title="<?= I18N::translate('Charts') ?>"> 760cb66f86SGreg Roach <?= view('icons/chart') ?> 770cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Charts') ?></span> 78dd6b2bfcSGreg Roach </th> 7967992b6aSRichard Cissee <th title="<?= I18N::translate('Lists') ?>"> 8067992b6aSRichard Cissee <?= view('icons/list') ?> 8167992b6aSRichard Cissee <span class="sr-only"><?= I18N::translate('Lists') ?></span> 8267992b6aSRichard Cissee </th> 830cb66f86SGreg Roach <th title="<?= I18N::translate('Reports') ?>"> 840cb66f86SGreg Roach <?= view('icons/report') ?> 850cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Reports') ?></span> 86dd6b2bfcSGreg Roach </th> 8733c34396SGreg Roach <th title="<?= I18N::translate('Footers') ?>"> 8833c34396SGreg Roach <?= view('icons/footer') ?> 8933c34396SGreg Roach <span class="sr-only"><?= I18N::translate('Footers') ?></span> 9033c34396SGreg Roach </th> 919e5cb8c9SGreg Roach <th title="<?= I18N::translate('Tracking and analytics') ?>"> 929e5cb8c9SGreg Roach <?= view('icons/analytics') ?> 939e5cb8c9SGreg Roach <span class="sr-only"><?= I18N::translate('Tracking and analytics') ?></span> 949e5cb8c9SGreg Roach </th> 95f3244202SGreg Roach <th title="<?= I18N::translate('Historic events') ?>"> 96f3244202SGreg Roach <?= view('icons/history') ?> 97f3244202SGreg Roach <span class="sr-only"><?= I18N::translate('Historic events') ?></span> 98f3244202SGreg Roach </th> 9911eb8581SGreg Roach <th title="<?= I18N::translate('Themes') ?>"> 1000cb66f86SGreg Roach <?= view('icons/theme') ?> 1010cb66f86SGreg Roach <span class="sr-only"><?= I18N::translate('Themes') ?></span> 102dd6b2bfcSGreg Roach </th> 10311eb8581SGreg Roach <th title="<?= I18N::translate('Languages') ?>"> 10411eb8581SGreg Roach <?= view('icons/language') ?> 10511eb8581SGreg Roach <span class="sr-only"><?= I18N::translate('Languages') ?></span> 10611eb8581SGreg Roach </th> 107dd6b2bfcSGreg Roach </tr> 108dd6b2bfcSGreg Roach </thead> 1090cb66f86SGreg Roach 110dd6b2bfcSGreg Roach <tbody> 11149a243cbSGreg Roach <?php foreach ($modules as $module) : ?> 112dd6b2bfcSGreg Roach <tr> 1130cb66f86SGreg Roach <th scope="row" dir="auto"> 11449a243cbSGreg Roach <?= $module->title() ?> 115dd6b2bfcSGreg Roach </th> 11649a243cbSGreg Roach <td class="text-center" data-sort="<?= $module->isEnabled() ?>"> 117677aaceaSGreg Roach <?= Bootstrap4::checkbox('', false, ['name' => 'status-' . $module->name(), 'checked' => $module->isEnabled()]) ?> 118dd6b2bfcSGreg Roach </td> 1190cb66f86SGreg Roach <td> 12049a243cbSGreg Roach <?= $module->description() ?> 1219cad7645SGreg Roach <?php if ($module instanceof ModuleCustomInterface) : ?> 122*1bfef740SGreg Roach <?= view('admin/custom-module-info', ['module' => $module]) ?> 123dd6b2bfcSGreg Roach <?php endif ?> 1248e5c5efeSGreg Roach <?php if ($module instanceof ModuleExternalUrlInterface) : ?> 125*1bfef740SGreg Roach <?= view('admin/external-module-info', ['module' => $module]) ?> 1268e5c5efeSGreg Roach <?php endif ?> 127dd6b2bfcSGreg Roach </td> 1280cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Preferences') ?>"> 1290cb66f86SGreg Roach <?php if ($module instanceof ModuleConfigInterface) : ?> 1300cb66f86SGreg Roach <a href="<?= e($module->getConfigLink()) ?>" title="<?= I18N::translate('Preferences') ?>"> 1310cb66f86SGreg Roach <?= view('icons/preferences') ?> 1320cb66f86SGreg Roach <span class="sr-only"> 1330cb66f86SGreg Roach <?= I18N::translate('Preferences') ?> 1340cb66f86SGreg Roach </span> 1350cb66f86SGreg Roach </a> 1360cb66f86SGreg Roach <?php endif ?> 1370cb66f86SGreg Roach </td> 1380cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Menu') ?>"> 139dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleMenuInterface) : ?> 140dd6b2bfcSGreg Roach <?= view('icons/menu') ?> 141dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Menu') ?></span> 142dd6b2bfcSGreg Roach <?php else : ?> 143dd6b2bfcSGreg Roach - 144dd6b2bfcSGreg Roach <?php endif ?> 145dd6b2bfcSGreg Roach </td> 1460cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Tab') ?>"> 147dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleTabInterface) : ?> 148dd6b2bfcSGreg Roach <?= view('icons/tab') ?> 149dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Tab') ?></span> 1500cb66f86SGreg Roach <?php else : ?> 1510cb66f86SGreg Roach - 152dd6b2bfcSGreg Roach <?php endif ?> 1530cb66f86SGreg Roach </td> 1540cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Sidebar') ?>"> 155dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleSidebarInterface) : ?> 156dd6b2bfcSGreg Roach <?= view('icons/sidebar') ?> 157dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Sidebar') ?></span> 1580cb66f86SGreg Roach <?php else : ?> 1590cb66f86SGreg Roach - 160dd6b2bfcSGreg Roach <?php endif ?> 1610cb66f86SGreg Roach </td> 1620cb66f86SGreg Roach <td class="text-center text-muted"> 1630cb66f86SGreg Roach <?php if ($module instanceof ModuleBlockInterface) : ?> 1640cb66f86SGreg Roach <?php if ($module->isUserBlock()) : ?> 1650cb66f86SGreg Roach <span title="<?= I18N::translate('My page') ?>"> 166dd6b2bfcSGreg Roach <?= view('icons/block-user') ?> 1670cb66f86SGreg Roach </span> 1680cb66f86SGreg Roach <span class="sr-only"> 1690cb66f86SGreg Roach <?= I18N::translate('My page') ?> 1700cb66f86SGreg Roach </span> 171dd6b2bfcSGreg Roach <?php endif ?> 1720cb66f86SGreg Roach 1730cb66f86SGreg Roach <?php if ($module->isTreeBlock()) : ?> 1740cb66f86SGreg Roach <span title="<?= I18N::translate('Home page') ?>"> 175dd6b2bfcSGreg Roach <?= view('icons/block-tree') ?> 1760cb66f86SGreg Roach </span> 1770cb66f86SGreg Roach <span class="sr-only"> 1780cb66f86SGreg Roach <?= I18N::translate('Home page') ?> 1790cb66f86SGreg Roach </span> 180dd6b2bfcSGreg Roach <?php endif ?> 1810cb66f86SGreg Roach <?php else : ?> 1820cb66f86SGreg Roach - 1830cb66f86SGreg Roach <?php endif ?> 1840cb66f86SGreg Roach </td> 1850cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Chart') ?>"> 186dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleChartInterface) : ?> 187dd6b2bfcSGreg Roach <?= view('icons/chart') ?> 188dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Chart') ?></span> 1890cb66f86SGreg Roach <?php else : ?> 1900cb66f86SGreg Roach - 191dd6b2bfcSGreg Roach <?php endif ?> 1920cb66f86SGreg Roach </td> 19367992b6aSRichard Cissee <td class="text-center text-muted" title="<?= I18N::translate('List') ?>"> 19467992b6aSRichard Cissee <?php if ($module instanceof ModuleListInterface) : ?> 19567992b6aSRichard Cissee <?= view('icons/list') ?> 19667992b6aSRichard Cissee <span class="sr-only"><?= I18N::translate('List') ?></span> 19767992b6aSRichard Cissee <?php else : ?> 19867992b6aSRichard Cissee - 19967992b6aSRichard Cissee <?php endif ?> 20067992b6aSRichard Cissee </td> 2010cb66f86SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Report') ?>"> 202dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleReportInterface) : ?> 203dd6b2bfcSGreg Roach <?= view('icons/report') ?> 204dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Report') ?></span> 2050cb66f86SGreg Roach <?php else : ?> 2060cb66f86SGreg Roach - 207dd6b2bfcSGreg Roach <?php endif ?> 2080cb66f86SGreg Roach </td> 20933c34396SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Footer') ?>"> 21033c34396SGreg Roach <?php if ($module instanceof ModuleFooterInterface) : ?> 21133c34396SGreg Roach <?= view('icons/footer') ?> 21233c34396SGreg Roach <span class="sr-only"><?= I18N::translate('Footer') ?></span> 21333c34396SGreg Roach <?php else : ?> 21433c34396SGreg Roach - 21533c34396SGreg Roach <?php endif ?> 21633c34396SGreg Roach </td> 2179e5cb8c9SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Tracking and analytics') ?>"> 2189e5cb8c9SGreg Roach <?php if ($module instanceof ModuleAnalyticsInterface) : ?> 2199e5cb8c9SGreg Roach <?= view('icons/analytics') ?> 2209e5cb8c9SGreg Roach <span class="sr-only"><?= I18N::translate('Tracking and analytics') ?></span> 2219e5cb8c9SGreg Roach <?php else : ?> 2229e5cb8c9SGreg Roach - 2239e5cb8c9SGreg Roach <?php endif ?> 2249e5cb8c9SGreg Roach </td> 225f3244202SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Historic events') ?>"> 226f3244202SGreg Roach <?php if ($module instanceof ModuleHistoricEventsInterface) : ?> 227f3244202SGreg Roach <?= view('icons/history') ?> 228f3244202SGreg Roach <span class="sr-only"><?= I18N::translate('Historic events') ?></span> 229f3244202SGreg Roach <?php else : ?> 230f3244202SGreg Roach - 231f3244202SGreg Roach <?php endif ?> 232f3244202SGreg Roach </td> 23311eb8581SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Theme') ?>"> 234dd6b2bfcSGreg Roach <?php if ($module instanceof ModuleThemeInterface) : ?> 235dd6b2bfcSGreg Roach <?= view('icons/theme') ?> 236dd6b2bfcSGreg Roach <span class="sr-only"><?= I18N::translate('Theme') ?></span> 2370cb66f86SGreg Roach <?php else : ?> 2380cb66f86SGreg Roach - 239dd6b2bfcSGreg Roach <?php endif ?> 240dd6b2bfcSGreg Roach </td> 24111eb8581SGreg Roach <td class="text-center text-muted" title="<?= I18N::translate('Language') ?>"> 24211eb8581SGreg Roach <?php if ($module instanceof ModuleLanguageInterface) : ?> 24311eb8581SGreg Roach <?= view('icons/language') ?> 24411eb8581SGreg Roach <span class="sr-only"><?= I18N::translate('Language') ?></span> 24511eb8581SGreg Roach <?php else : ?> 24611eb8581SGreg Roach - 24711eb8581SGreg Roach <?php endif ?> 24811eb8581SGreg Roach </td> 249dd6b2bfcSGreg Roach </tr> 250dd6b2bfcSGreg Roach <?php endforeach ?> 251dd6b2bfcSGreg Roach </tbody> 252dd6b2bfcSGreg Roach </table> 253dd6b2bfcSGreg Roach <button class="btn btn-primary" type="submit"> 254dd6b2bfcSGreg Roach <?= view('icons/save') ?> 255dd6b2bfcSGreg Roach <?= I18N::translate('save') ?></button> 256dd6b2bfcSGreg Roach</form> 257dd6b2bfcSGreg Roach 258dd6b2bfcSGreg Roach<?php View::push('javascript') ?> 259dd6b2bfcSGreg Roach<script> 260dd6b2bfcSGreg Roach 'use strict'; 261dd6b2bfcSGreg Roach 262dd6b2bfcSGreg Roach $(".table-module-administration").dataTable({<?= I18N::datatablesI18N() ?>}); 263dd6b2bfcSGreg Roach</script> 264dd6b2bfcSGreg Roach<?php View::endpush() ?> 265