Files
thetool/Layout/default/Network/Index.php
2021-06-24 22:49:37 +02:00

78 lines
3.1 KiB
PHP

<?php include(realpath(dirname(__FILE__)."/../")."/header.php"); ?>
<div class="wrapper">
<div class="container-fluid">
<!-- start page title -->
<div class="row">
<div class="col-12">
<div class="page-title-box">
<div class="page-title-right">
<ol class="breadcrumb m-0">
<li class="breadcrumb-item"><a href="<?=self::getUrl("Dashboard")?>">the-tool</a></li>
<?php if(is_array($filter['addresstype']) && count($filter['addresstype'])): ?>
<li class="breadcrumb-item"><a href="<?=self::getUrl("Address")?>">Netzgebiete</a></li>
<li class="breadcrumb-item active">
<?php foreach($filter['addresstype'] as $type) { $types[] = __($type); } ?>
<?=implode(", ", $types)?>
</li>
<?php else: ?>
<li class="breadcrumb-item active">Netzgebiete</li>
<?php endif; ?>
</ol>
</div>
<h4 class="page-title">Netzgebiete</h4>
</div>
</div>
</div>
<!-- end page title -->
<div class="row">
<div class="col-lg-12">
<div class="card">
<div class="card-body mb-3">
<div class="row">
<div class="col-lg-12">
<div class="float-left">
<h4 class="header-title mb-4">Liste aller Netzgebiete</h4>
</div>
<div class="float-right">
<a class="btn btn-primary" href="<?=self::getUrl("Network", "add")?>"><i class="fas fa-plus"></i> Neues Netzgebiet anlegen</a>
</div>
</div>
</div>
<?php if(is_array($networks) && count($networks)): ?>
<table class="table table-striped table-hover">
<tr>
<th>Name</th>
<th>Besitzer</th>
<th></th>
</tr>
<?php foreach($networks as $network): ?>
<tr>
<td><?=$network->name?></td>
<td><?=nl2br($network->owner->getCompanyOrName())?></td>
<td style="text-align: left; letter-spacing: 4px; font-size: 1.1em;">
<a href="<?=self::getUrl("Pop", "Index", ["filter" => ["network_id" => $network->id]])?>" title="POPs anzeigen"><i class="fas fa-project-diagram"></i></a>
<a href="<?=self::getUrl("Network", "edit", ["id" => $network->id])?>"><i class="far fa-edit" title="Bearbeiten"></i></a>
<a href="<?=self::getUrl("Network", "delete", ["id" => $network->id])?>" class="text-danger" title="Löschen"><i class="fas fa-trash"></i></a>
</td>
</tr>
<?php endforeach; ?>
</table>
<?php else: ?>
<div class="row"><p class="col-md-12"><i>Keine Netzgebiete gefunden</i></p></div>
<?php endif; ?>
</div>
</div>
</div>
</div>
</div> <!-- end container-fluid -->
</div>
<!-- end wrapper -->
<?php include(realpath(dirname(__FILE__)."/../")."/footer.php"); ?>