summaryrefslogtreecommitdiff
path: root/resources/views/branches-page.phtml
blob: da0f6e5c8311baa17f17e2079f82e91002f3ad5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php use Fisharebest\Webtrees\Bootstrap4; ?>
<?php use Fisharebest\Webtrees\I18N; ?>

<h2 class="wt-page-title">
    <?= $title ?>
</h2>

<form class="wt-page-options wt-page-options-branches d-print-none">
    <input type="hidden" name="route" value="branches">
    <input type="hidden" name="ged" value="<?= e($tree->name()) ?>">

    <div class="form-group row">
        <label class="col-form-label col-sm-3 wt-page-options-label" for="surname">
            <?= I18N::translate('Surname') ?>
        </label>
        <div class="col-sm-9 wt-page-options-value">
            <input class="form-control" data-autocomplete-type="SURN" type="text" name="surname" id="surname" value="<?= e($surname) ?>" dir="auto">
        </div>
    </div>

    <fieldset class="form-group">
        <div class="row">
            <legend class="col-form-label col-sm-3 wt-page-options-label">
                <?= I18N::translate('Phonetic search') ?>
            </legend>
            <div class="col-sm-9 wt-page-options-value">
                <?= Bootstrap4::checkbox(I18N::translate('Russell'), true, ['name' => 'soundex_std', 'checked' => $soundex_std]) ?>
                <?= Bootstrap4::checkbox(I18N::translate('Daitch-Mokotoff'), true, ['name' => 'soundex_dm', 'checked' => $soundex_dm]) ?>
            </div>
        </div>
    </fieldset>

    <div class="form-group row">
        <div class="col-sm-3 wt-page-options-label">
        </div>
        <div class="col-sm-9 wt-page-options-value">
            <button type="submit" class="btn btn-primary">
                <?= /* I18N: A button label. */ I18N::translate('view') ?>
            </button>
        </div>
    </div>
</form>

<?php if ($surname !== '') : ?>
    <div class="wt-ajax-load wt-page-content wt-chart wt-branches" data-ajax-url="<?= e(route('branches-list', ['surname' => $surname, 'soundex_std' => $soundex_std, 'soundex_dm' => $soundex_dm, 'ged' => $tree->name()])) ?>"></div>
<?php endif ?>