1<?php 2 3use Fisharebest\Webtrees\Auth; 4use Fisharebest\Webtrees\Http\RequestHandlers\ChangeFamilyMembersPage; 5use Fisharebest\Webtrees\Http\RequestHandlers\DeleteRecord; 6use Fisharebest\Webtrees\Http\RequestHandlers\EditRawRecordPage; 7use Fisharebest\Webtrees\Http\RequestHandlers\ReorderChildrenPage; 8use Fisharebest\Webtrees\I18N; 9 10?> 11 12<div class="dropdown wt-page-menu"> 13 <button class="btn btn-primary dropdown-toggle wt-page-menu-button" type="button" id="page-menu" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> 14 <?= view('icons/edit') ?> 15 <?= I18N::translate('edit') ?> 16 </button> 17 18 <div class="dropdown-menu dropdown-menu-right wt-page-menu-items" aria-labelledby="page-menu"> 19 <a class="dropdown-item" href="<?= e(route(ChangeFamilyMembersPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>"> 20 <?= view('icons/family') ?> 21 <?= I18N::translate('Change family members') ?> 22 </a> 23 24 <?php if ($record->husband() === null) : ?> 25 <a class="dropdown-item" href="<?= e(route('add-spouse-to-family', ['tree' => $record->tree()->name(), 'xref' => $record->xref(), 'famtag' => 'HUSB'])) ?>"> 26 <?= view('icons/add') ?> 27 <?= I18N::translate('Add a husband') ?> 28 </a> 29 <?php endif ?> 30 31 <?php if ($record->wife() === null) : ?> 32 <a class="dropdown-item" href="<?= e(route('add-spouse-to-family', ['tree' => $record->tree()->name(), 'xref' => $record->xref(), 'famtag' => 'WIFE'])) ?>"> 33 <?= view('icons/add') ?> 34 <?= I18N::translate('Add a wife') ?> 35 </a> 36 <?php endif ?> 37 38 <a class="dropdown-item" href="<?= e(route('add-child-to-family', ['gender' => 'U', 'tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>"> 39 <?= view('icons/add') ?> 40 <?= I18N::translate('Add a child') ?> 41 </a> 42 43 <?php if ($record->numberOfChildren() > 1) : ?> 44 <a class="dropdown-item" href="<?= e(route(ReorderChildrenPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>"> 45 <?= view('icons/reorder') ?> 46 <?= I18N::translate('Re-order children') ?> 47 </a> 48 <?php endif ?> 49 50 <div class="dropdown-divider"></div> 51 52 <a class="dropdown-item" href="#" data-confirm="<?= I18N::translate('Deleting the family will unlink all of the individuals from each other but will leave the individuals in place. Are you sure you want to delete this family?') ?>" data-post-url="<?= e(route(DeleteRecord::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>"> 53 <?= view('icons/delete') ?> 54 <?= I18N::translate('Delete') ?> 55 </a> 56 57 <?php if (Auth::isAdmin() || $record->tree()->getPreference('SHOW_GEDCOM_RECORD')) : ?> 58 <a class="dropdown-item" href="<?= e(route(EditRawRecordPage::class, ['tree' => $record->tree()->name(), 'xref' => $record->xref()])) ?>"> 59 <?= view('icons/edit') ?> 60 <?= I18N::translate('Edit the raw GEDCOM') ?> 61 </a> 62 <?php endif ?> 63 </div> 64</div> 65