blob: 4bcb1515dda01b0a449200da34fe862f23c33159 (
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
47
48
|
<?php
/**
* @var Institute_ExternController $controller
* @var array $config_types
* @var ExternPageConfig[] $configs
*/
if (count($configs) == 0) :
echo MessageBox::info(_('Es wurde noch keine externe Seite angelegt.'),
[
sprintf(_('Um eine neue externe Seite anzulegen, klicken sie %shier%s.'),
'<a href="' . $controller->new() . '" data-dialog="size=870x500">',
'</a>')
]);
else : ?>
<form id="extern-page-index" action="#" method="post">
<?= CSRFProtection::tokenTag() ?>
<section class="contentbox">
<header>
<h1>
<?= _('Externe Seiten') ?>
</h1>
</header>
<? foreach ($config_types as $type_id => $config_type): ?>
<? if (!empty($configs[$type_id])) : ?>
<article id="<?= $type_id ?>" <? if (Request::option('open_type') === $type_id) echo 'class="open"'; ?>>
<header>
<h1>
<a href="<?= URLHelper::getLink('?#' . $type_id)?>">
<?= htmlReady($config_type['name']) ?>
(<?= count($configs[$type_id]) ?>)
</a>
</h1>
</header>
<section>
<table class="default sortable-table">
<?= $this->render_partial('institute/extern/_table-header.php') ?>
<? foreach ($configs[$type_id] as $config) : ?>
<?= $this->render_partial('institute/extern/_table-row.php', ['config' => $config]) ?>
<? endforeach ?>
</table>
</section>
</article>
<? endif ?>
<? endforeach ?>
</section>
</form>
<?php endif ?>
|