xref: /webtrees/resources/views/modules/stories/edit.phtml (revision 0c0910bf0f275a14f35d2ccdf698f91f79e269d4)
1dd6b2bfcSGreg Roach<?php use Fisharebest\Webtrees\Functions\FunctionsEdit; ?>
23cfcc809SGreg Roach<?php
33cfcc809SGreg Roach
4*0c0910bfSGreg Roachuse Fisharebest\Webtrees\Http\RequestHandlers\ControlPanel;
5*0c0910bfSGreg Roachuse Fisharebest\Webtrees\I18N;
6dd6b2bfcSGreg Roach
7*0c0910bfSGreg Roach?>
8*0c0910bfSGreg Roach
9*0c0910bfSGreg Roach<?= view('components/breadcrumbs', ['links' => [route(ControlPanel::class) => I18N::translate('Control panel'), route('modules') => I18N::translate('Modules'), route('module', ['module' => 'stories', 'action' => 'Admin', 'tree' => $tree->name()]) => I18N::translate('Stories'), $title]]) ?>
10dd6b2bfcSGreg Roach
11dd6b2bfcSGreg Roach<h1><?= $title ?></h1>
12dd6b2bfcSGreg Roach
13d72b284aSGreg Roach<form method="post" action="<?= e(route('module', ['module' => 'stories', 'action' => 'AdminEdit', 'block_id' => $block_id, 'tree' => $tree->name()])) ?>" class="form-horizontal">
14dd6b2bfcSGreg Roach    <?= csrf_field() ?>
15dd6b2bfcSGreg Roach
16dd6b2bfcSGreg Roach    <div class="row form-group">
17dd6b2bfcSGreg Roach        <label for="xref" class="col-sm-3 col-form-label">
18dd6b2bfcSGreg Roach            <?= I18N::translate('Individual') ?>
19dd6b2bfcSGreg Roach        </label>
20dd6b2bfcSGreg Roach        <div class="col-sm-9">
21b6c326d8SGreg Roach            <?= view('components/select-individual', ['name' => 'xref', 'individual' => $individual, 'tree' => $tree]) ?>
22dd6b2bfcSGreg Roach        </div>
23dd6b2bfcSGreg Roach    </div>
24dd6b2bfcSGreg Roach
25dd6b2bfcSGreg Roach    <div class="row form-group">
26dd6b2bfcSGreg Roach        <label for="story-title" class="col-sm-3 col-form-label">
27dd6b2bfcSGreg Roach            <?= I18N::translate('Story title') ?>
28dd6b2bfcSGreg Roach        </label>
29dd6b2bfcSGreg Roach        <div class="col-sm-9">
30dd6b2bfcSGreg Roach            <input type="text" class="form-control" name="story_title" id="story-title" value="<?= e($story_title) ?>">
31dd6b2bfcSGreg Roach        </div>
32dd6b2bfcSGreg Roach    </div>
33dd6b2bfcSGreg Roach
34dd6b2bfcSGreg Roach    <div class="row form-group">
35dd6b2bfcSGreg Roach        <label for="story-body" class="col-sm-3 col-form-label">
36dd6b2bfcSGreg Roach            <?= I18N::translate('Story') ?>
37dd6b2bfcSGreg Roach        </label>
38dd6b2bfcSGreg Roach        <div class="col-sm-9">
39dd6b2bfcSGreg Roach            <textarea name="story_body" id="story-body" class="html-edit form-control" rows="10"><?= e($story_body) ?></textarea>
40dd6b2bfcSGreg Roach        </div>
41dd6b2bfcSGreg Roach    </div>
42dd6b2bfcSGreg Roach
43dd6b2bfcSGreg Roach    <div class="row form-group">
44dd6b2bfcSGreg Roach        <label class="col-sm-3 col-form-label">
45dd6b2bfcSGreg Roach            <?= I18N::translate('Show this block for which languages') ?>
46dd6b2bfcSGreg Roach        </label>
47dd6b2bfcSGreg Roach        <div class="col-sm-9">
48dd6b2bfcSGreg Roach            <?= FunctionsEdit::editLanguageCheckboxes('languages', $languages) ?>
49dd6b2bfcSGreg Roach        </div>
50dd6b2bfcSGreg Roach    </div>
51dd6b2bfcSGreg Roach
52dd6b2bfcSGreg Roach    <div class="row form-group">
53dd6b2bfcSGreg Roach        <div class="offset-sm-3 col-sm-9">
54dd6b2bfcSGreg Roach            <button type="submit" class="btn btn-primary">
55dd6b2bfcSGreg Roach                <?= view('icons/save') ?>
56dd6b2bfcSGreg Roach                <?= I18N::translate('save') ?>
57dd6b2bfcSGreg Roach            </button>
58dd6b2bfcSGreg Roach
59d72b284aSGreg Roach            <a href="<?= e(route('module', ['module' => 'stories', 'action' => 'Admin', 'tree' => $tree->name()])) ?>" class="btn btn-secondary">
60dd6b2bfcSGreg Roach                <?= view('icons/cancel') ?>
61dd6b2bfcSGreg Roach                <?= I18N::translate('cancel') ?>
62dd6b2bfcSGreg Roach            </a>
63dd6b2bfcSGreg Roach        </div>
64dd6b2bfcSGreg Roach    </div>
65dd6b2bfcSGreg Roach</form>
66