Files
thetool/Layout/default/Product/Index.php
2021-07-05 19:46:22 +02:00

75 lines
2.9 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>
<li class="breadcrumb-item active">Produkte</li>
</ol>
</div>
<h4 class="page-title">Produkte</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="float-left">
<h4 class="header-title">Liste aller Produkte</h4>
</div>
<div class="float-right">
<a class="btn btn-primary mb-2" href="<?=self::getUrl("Product", "add")?>"><i class="fas fa-plus"></i> Neues Produkt anlegen</a>
</div>
<table class="table table-striped table-hover">
<tr>
<th>Fremdprodukt</th>
<th>Gruppe</th>
<th>Name</th>
<th>Technologie</th>
<th>Kundentyp</th>
<th>Verkaufspreis</th>
<th>Verr. Periode</th>
<th>SLA</th>
<th>IVT ID</th>
<th></th>
</tr>
<?php foreach($products as $product): ?>
<tr>
<td><?=($product->external == 1) ? "<i class='fas fa-check text-success'></i>" : ""?></td>
<td><?=$product->productgroup->name?></td>
<td><?=$product->name?></td>
<td><?=$product->producttech->name?> (<?=$product->producttech->rtrcode?>)</td>
<td><?=__($product->producttech->customer_type)?></td>
<td><?=$product->price?></td>
<td><?=$product->billing_period?>x Jährlich</td>
<td><?=$product->sla->id?></td>
<td><?=$product->ivt_id?></td>
<td style="text-align: left; letter-spacing: 4px; font-size: 1.1em;">
<a href="<?=self::getUrl("Product", "edit", ["id" => $product->id])?>"><i class="far fa-edit" title="Produkt Bearbeiten"></i></a>
<a href="<?=self::getUrl("Product", "delete", ["id" => $product->id])?>" class="text-danger" onclick="if(!confirm('Berechtigungen wirklich löschen?')) return false;" title="Produkt Löschen"><i class="fas fa-trash"></i></a>
</td>
</tr>
<?php endforeach; ?>
</table>
</div>
</div>
</div>
</div>
</div> <!-- end container-fluid -->
</div>
<!-- end wrapper -->
<?php include(realpath(dirname(__FILE__)."/../")."/footer.php"); ?>