@@ -189,7 +189,7 @@ |
||
189 | 189 | <div class="modal-content"> |
190 | 190 | <div class="modal-header"> |
191 | 191 | <h3 class="modal-title" id="wt-modal-title">' . $title . '</h3> |
192 | - <button type="button" class="close" data-dismiss="modal" aria-label="'. I18N::translate('close') .'"> |
|
192 | + <button type="button" class="close" data-dismiss="modal" aria-label="'. I18N::translate('close') . '"> |
|
193 | 193 | <span aria-hidden="true">×</span> |
194 | 194 | </button> |
195 | 195 | </div> |
@@ -28,8 +28,6 @@ |
||
28 | 28 | use Fisharebest\Webtrees\Html; |
29 | 29 | use Fisharebest\Webtrees\I18N; |
30 | 30 | use Fisharebest\Webtrees\Individual; |
31 | -use Fisharebest\Webtrees\Module; |
|
32 | -use Fisharebest\Webtrees\Module\CensusAssistantModule; |
|
33 | 31 | use Fisharebest\Webtrees\Note; |
34 | 32 | use Fisharebest\Webtrees\Place; |
35 | 33 | use Fisharebest\Webtrees\Session; |
@@ -90,9 +90,9 @@ |
||
90 | 90 | 'info' => 'fa fa-info-circle', |
91 | 91 | 'warning' => 'fa fa-exclamation-circle', |
92 | 92 | |
93 | - // Icons for file types |
|
94 | - 'mime-application-pdf' => '', |
|
95 | - 'mime-text-html' => '', |
|
93 | + // Icons for file types |
|
94 | + 'mime-application-pdf' => '', |
|
95 | + 'mime-text-html' => '', |
|
96 | 96 | |
97 | 97 | // Other icons |
98 | 98 | 'mail' => 'fa fa-envelope-o', |
@@ -819,7 +819,7 @@ discard block |
||
819 | 819 | '<div class="icons">' . |
820 | 820 | '<span class="iconz icon-zoomin" title="' . I18N::translate('Zoom in/out on this box.') . '"></span>' . |
821 | 821 | '<div class="itr"><i class="icon-pedigree"></i><div class="popup">' . |
822 | - '<ul class="' . $personBoxClass . '">' . implode('', array_map(function(Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
822 | + '<ul class="' . $personBoxClass . '">' . implode('', array_map(function (Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
823 | 823 | '</div>' . |
824 | 824 | '</div>' . |
825 | 825 | '</div>'; |
@@ -871,7 +871,7 @@ discard block |
||
871 | 871 | '<div class="icons">' . |
872 | 872 | '<span class="iconz icon-zoomin" title="' . I18N::translate('Zoom in/out on this box.') . '"></span>' . |
873 | 873 | '<div class="itr"><i class="icon-pedigree"></i><div class="popup">' . |
874 | - '<ul class="' . $personBoxClass . '">' . implode('', array_map(function(Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
874 | + '<ul class="' . $personBoxClass . '">' . implode('', array_map(function (Menu $menu) { return $menu->bootstrap4(); }, $this->individualBoxMenu($individual))) . '</ul>' . |
|
875 | 875 | '</div>' . |
876 | 876 | '</div>' . |
877 | 877 | '</div>'; |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | $controller->restrictAccess(!in_array($to, ['all', 'never_logged', 'last_6mo']) || Auth::isAdmin()); |
101 | 101 | $controller->pageHeader(); |
102 | 102 | |
103 | -$to_names = implode(I18N::$list_separator, array_map(function(User $user) { return $user->getRealName(); }, recipients($to))); |
|
103 | +$to_names = implode(I18N::$list_separator, array_map(function (User $user) { return $user->getRealName(); }, recipients($to))); |
|
104 | 104 | |
105 | 105 | ?> |
106 | 106 | <h2><?= I18N::translate('Send a message') ?></h2> |
@@ -185,13 +185,13 @@ discard block |
||
185 | 185 | */ |
186 | 186 | function recipients($to) { |
187 | 187 | if ($to === 'all') { |
188 | - $recipients = User::all(); |
|
188 | + $recipients = User::all(); |
|
189 | 189 | } elseif ($to === 'last_6mo') { |
190 | - $recipients = array_filter(User::all(), function(User $user) { |
|
190 | + $recipients = array_filter(User::all(), function (User $user) { |
|
191 | 191 | return $user->getPreference('sessiontime') > 0 && WT_TIMESTAMP - $user->getPreference('sessiontime') > 60 * 60 * 24 * 30 * 6; |
192 | 192 | }); |
193 | 193 | } elseif ($to === 'never_logged') { |
194 | - $recipients = array_filter(User::all(), function(User $user) { |
|
194 | + $recipients = array_filter(User::all(), function (User $user) { |
|
195 | 195 | return $user->getPreference('verified_by_admin') && $user->getPreference('reg_timestamp') > $user->getPreference('sessiontime'); |
196 | 196 | }); |
197 | 197 | } else { |
@@ -123,7 +123,8 @@ discard block |
||
123 | 123 | <div class="form-control"><?= Html::escape(Auth::user()->getRealName()) ?></div> |
124 | 124 | </div> |
125 | 125 | </div> |
126 | - <?php else: ?> |
|
126 | + <?php else { |
|
127 | + : ?> |
|
127 | 128 | <div class="form-group row"> |
128 | 129 | <label class="col-sm-3 col-form-label" for="from-name"> |
129 | 130 | <?= I18N::translate('Your name') ?> |
@@ -181,6 +182,7 @@ discard block |
||
181 | 182 | function recipients($to) { |
182 | 183 | if ($to === 'all') { |
183 | 184 | $recipients = User::all(); |
185 | +} |
|
184 | 186 | } elseif ($to === 'last_6mo') { |
185 | 187 | $recipients = array_filter(User::all(), function(User $user) { |
186 | 188 | return $user->getPreference('sessiontime') > 0 && WT_TIMESTAMP - $user->getPreference('sessiontime') > 60 * 60 * 24 * 30 * 6; |
@@ -247,7 +247,7 @@ |
||
247 | 247 | /** |
248 | 248 | * Which months follows this one? Calendars with leap-months should provide their own implementation. |
249 | 249 | * |
250 | - * @return int[] |
|
250 | + * @return integer[] |
|
251 | 251 | */ |
252 | 252 | protected function nextMonth() { |
253 | 253 | if ($this->m == 6 && !$this->isLeapYear()) { |
@@ -842,7 +842,7 @@ |
||
842 | 842 | /** |
843 | 843 | * Which months follows this one? Calendars with leap-months should provide their own implementation. |
844 | 844 | * |
845 | - * @return int[] |
|
845 | + * @return integer[] |
|
846 | 846 | */ |
847 | 847 | protected function nextMonth() { |
848 | 848 | return [$this->m === $this->calendar->monthsInYear() ? $this->nextYear($this->y) : $this->y, ($this->m % $this->calendar->monthsInYear()) + 1]; |
@@ -381,7 +381,8 @@ discard block |
||
381 | 381 | <a href="<?= $individual->getHtmlUrl() ?>#tab-stories"> |
382 | 382 | <?= $individual->getFullName() ?> |
383 | 383 | </a> |
384 | - <?php else: ?> |
|
384 | + <?php else { |
|
385 | + : ?> |
|
385 | 386 | <?= $story->xref ?> |
386 | 387 | <?php endif ?> |
387 | 388 | </td> |
@@ -410,6 +411,7 @@ discard block |
||
410 | 411 | */ |
411 | 412 | private function showList() { |
412 | 413 | global $controller, $WT_TREE; |
414 | +} |
|
413 | 415 | |
414 | 416 | $controller = new PageController; |
415 | 417 | $controller |
@@ -16,8 +16,8 @@ |
||
16 | 16 | namespace Fisharebest\Webtrees; |
17 | 17 | |
18 | 18 | use Exception; |
19 | -use Swift_Mailer; |
|
20 | 19 | use Swift_MailTransport; |
20 | +use Swift_Mailer; |
|
21 | 21 | use Swift_Message; |
22 | 22 | use Swift_NullTransport; |
23 | 23 | use Swift_Preferences; |
@@ -106,7 +106,7 @@ |
||
106 | 106 | if (!empty($menu->getSubmenus())) { |
107 | 107 | // Insert a dummy menu / label into the submenu |
108 | 108 | $submenus = $menu->getSubmenus(); |
109 | - array_unshift($submenus, new Menu($menu->getLabel(), null, null, [ 'onclick' => 'return false;'])); |
|
109 | + array_unshift($submenus, new Menu($menu->getLabel(), null, null, ['onclick' => 'return false;'])); |
|
110 | 110 | $menu->setSubmenus($submenus); |
111 | 111 | } |
112 | 112 |
@@ -1120,24 +1120,24 @@ |
||
1120 | 1120 | if ($latlongval[$i] == $latlongval[$k]) { |
1121 | 1121 | $dups++; |
1122 | 1122 | switch ($dups) { |
1123 | - case 1: |
|
1124 | - $marker_number = $curgen . 'L'; |
|
1125 | - break; |
|
1126 | - case 2: |
|
1127 | - $marker_number = $curgen . 'R'; |
|
1128 | - break; |
|
1129 | - case 3: |
|
1130 | - $marker_number = $curgen . 'Ls'; |
|
1131 | - break; |
|
1132 | - case 4: |
|
1133 | - $marker_number = $curgen . 'Rs'; |
|
1134 | - break; |
|
1135 | - case 5: //adjust position where markers have same coodinates |
|
1136 | - default: |
|
1137 | - $marker_number = $curgen; |
|
1138 | - $lon[$i] += 0.0025; |
|
1139 | - $lat[$i] += 0.0025; |
|
1140 | - break; |
|
1123 | + case 1: |
|
1124 | + $marker_number = $curgen . 'L'; |
|
1125 | + break; |
|
1126 | + case 2: |
|
1127 | + $marker_number = $curgen . 'R'; |
|
1128 | + break; |
|
1129 | + case 3: |
|
1130 | + $marker_number = $curgen . 'Ls'; |
|
1131 | + break; |
|
1132 | + case 4: |
|
1133 | + $marker_number = $curgen . 'Rs'; |
|
1134 | + break; |
|
1135 | + case 5: //adjust position where markers have same coodinates |
|
1136 | + default: |
|
1137 | + $marker_number = $curgen; |
|
1138 | + $lon[$i] += 0.0025; |
|
1139 | + $lat[$i] += 0.0025; |
|
1140 | + break; |
|
1141 | 1141 | } |
1142 | 1142 | } |
1143 | 1143 | } |
@@ -1317,7 +1317,7 @@ discard block |
||
1317 | 1317 | // Create the normal googlemap sidebar of events and children |
1318 | 1318 | echo '<div class="gm-events">'; |
1319 | 1319 | echo '<table class="wt-facts-table">'; |
1320 | - echo '<caption class="sr-only">' . I18N::translate('Facts and events') .'</caption>'; |
|
1320 | + echo '<caption class="sr-only">' . I18N::translate('Facts and events') . '</caption>'; |
|
1321 | 1321 | echo '<tbody>'; |
1322 | 1322 | |
1323 | 1323 | foreach ($events as $event) { |
@@ -2244,7 +2244,7 @@ discard block |
||
2244 | 2244 | 'place_id' => $place_id, |
2245 | 2245 | ]); |
2246 | 2246 | } catch (\Exception $ex) { |
2247 | - FlashMessages::addMessage(I18N::translate('Location not removed: this location contains sub-locations'),'danger'); |
|
2247 | + FlashMessages::addMessage(I18N::translate('Location not removed: this location contains sub-locations'), 'danger'); |
|
2248 | 2248 | } |
2249 | 2249 | |
2250 | 2250 | header('Location: module.php?mod=googlemap&mod_action=admin_places&parent_id=' . $parent_id . '&inactive=' . $inactive); |
@@ -2594,7 +2594,7 @@ discard block |
||
2594 | 2594 | [0 => I18N::translate('Geographic data')] + |
2595 | 2595 | $this->placeIdToHierarchy($place_id === 0 ? $parent_id : $place_id); |
2596 | 2596 | foreach ($hierarchy as $id => $name) { |
2597 | - $breadcrumbs += ['module.php?mod=googlemap&mod_action=admin_places&parent_id=' . $id .'&inactive=' . $inactive => Html::escape($name)]; |
|
2597 | + $breadcrumbs += ['module.php?mod=googlemap&mod_action=admin_places&parent_id=' . $id . '&inactive=' . $inactive => Html::escape($name)]; |
|
2598 | 2598 | } |
2599 | 2599 | echo Bootstrap4::breadcrumbs($breadcrumbs, $place_id === 0 ? I18N::translate('Add') : I18N::translate('Edit')); |
2600 | 2600 | |
@@ -3100,7 +3100,7 @@ discard block |
||
3100 | 3100 | [0 => I18N::translate('Geographic data')] + |
3101 | 3101 | $this->placeIdToHierarchy($parent_id); |
3102 | 3102 | foreach (array_slice($hierarchy, 0, -1, true) as $id => $name) { |
3103 | - $breadcrumbs += ['module.php?mod=googlemap&mod_action=admin_places&parent_id=' . $id .'&inactive=' . $inactive => Html::escape($name)]; |
|
3103 | + $breadcrumbs += ['module.php?mod=googlemap&mod_action=admin_places&parent_id=' . $id . '&inactive=' . $inactive => Html::escape($name)]; |
|
3104 | 3104 | } |
3105 | 3105 | echo Bootstrap4::breadcrumbs($breadcrumbs, end($hierarchy)); |
3106 | 3106 | |
@@ -3292,7 +3292,7 @@ discard block |
||
3292 | 3292 | <?php endif ?> |
3293 | 3293 | </td> |
3294 | 3294 | <td> |
3295 | - <?= FontAwesome::linkIcon('edit', I18N::translate('Edit'), ['href' => 'module.php?mod=googlemap&mod_action=admin_place_edit&action=update&place_id=' . $place['place_id'] . '&parent_id=' . $place['parent_id'], 'class' => 'btn btn-primary']) ?> |
|
3295 | + <?= FontAwesome::linkIcon('edit', I18N::translate('Edit'), ['href' => 'module.php?mod=googlemap&mod_action=admin_place_edit&action=update&place_id=' . $place['place_id'] . '&parent_id=' . $place['parent_id'], 'class' => 'btn btn-primary']) ?> |
|
3296 | 3296 | </td> |
3297 | 3297 | <td> |
3298 | 3298 | <?php if ($noRows == 0): ?> |
@@ -3301,7 +3301,7 @@ discard block |
||
3301 | 3301 | <input type="hidden" name="place_id" value="<?= $place['place_id'] ?>"> |
3302 | 3302 | <input type="hidden" name="inactive" value="<?= $inactive ?>"> |
3303 | 3303 | <button type="submit" class="btn btn-danger"> |
3304 | - <?= FontAwesome::semanticIcon('delete', I18N::translate('Delete')) ?> |
|
3304 | + <?= FontAwesome::semanticIcon('delete', I18N::translate('Delete')) ?> |
|
3305 | 3305 | </button> |
3306 | 3306 | </form> |
3307 | 3307 | <?php else: ?> |