xref: /webtrees/resources/views/modules/relationships-chart/config.phtml (revision d70512ab02636ee884ef6d7907223ed02c754ff5)
1<?php
2
3use Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
4use Fisharebest\Webtrees\I18N;
5
6?>
7
8<?= view('components/breadcrumbs', ['links' => [route(ControlPanel::class) => I18N::translate('Control panel'), route('modules') => I18N::translate('Modules'), $title]]) ?>
9
10<h1><?= $title ?></h1>
11<p>
12    <?= I18N::translate('Searching for all possible relationships can take a lot of time in complex trees.') ?>
13</p>
14
15<form method="post">
16    <?= csrf_field() ?>
17    <?php foreach ($all_trees as $tree) : ?>
18        <h2><?= e($tree->title()) ?></h2>
19        <div class="row form-group">
20            <label class="col-sm-3 col-form-label" for="relationship-ancestors-<?= $tree->id() ?>">
21                <?= /* I18N: Configuration option */
22                I18N::translate('Relationships') ?>
23            </label>
24            <div class="col-sm-9">
25                <?= view('components/select', ['name' => 'relationship-ancestors-' . $tree->id(), 'selected' => $tree->getPreference('RELATIONSHIP_ANCESTORS', $default_ancestors), 'options' => $ancestors_options]) ?>
26            </div>
27        </div>
28
29        <fieldset class="form-group">
30            <div class="row">
31                <legend class="col-form-label col-sm-3">
32                    <?= /* I18N: Configuration option */
33                    I18N::translate('How much recursion to use when searching for relationships') ?>
34                </legend>
35                <div class="col-sm-9">
36                    <?= view('components/radios-inline', ['name' => 'relationship-recursion-' . $tree->id(), 'options' => $recursion_options, 'selected' => (int) $tree->getPreference('RELATIONSHIP_RECURSION', $default_recursion)]) ?>
37                </div>
38            </div>
39        </fieldset>
40    <?php endforeach ?>
41
42    <div class="row form-group">
43        <div class="offset-sm-3 col-sm-9">
44            <button type="submit" class="btn btn-primary">
45                <?= view('icons/save') ?>
46                <?= I18N::translate('save') ?>
47            </button>
48        </div>
49    </div>
50</form>
51