55 lines
1.8 KiB
PHP
55 lines
1.8 KiB
PHP
<?php
|
|
$orderArr = $this->orders;
|
|
?>
|
|
<div id="tickets-orders">
|
|
<div class="container">
|
|
<div class="tickets-orders">
|
|
<h1>Lista zamówień</h1>
|
|
<div class="orders-list">
|
|
<div style="overflow-x:auto;">
|
|
<table class="table table-striped" id="myTable">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">id</th>
|
|
<th scope="col">Imię</th>
|
|
<th scope="col">Nazwisko</th>
|
|
<th scope="col">Email</th>
|
|
<th scope="col">Cena</th>
|
|
<th scope="col">Status płatności</th>
|
|
<th scope="col">Status biletu</th>
|
|
<th scope="col">Data zakupu</th>
|
|
<th>Edytuj</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<? foreach ($orderArr as $key => $value) : ?>
|
|
<tr>
|
|
<td scope="row"><?= $value['id']; ?></td>
|
|
<td><?= $value['name']; ?></td>
|
|
<td><?= $value['surname']; ?></td>
|
|
<td><?= $value['email']; ?></td>
|
|
<td><?= $value['order_price']; ?></td>
|
|
<td><?= $value['payment_status'] == 1 ? 'Zapłacono': 'Nie zapłacono'; ?></td>
|
|
<td><?= $value['used_ticket'] == 1 ? 'Wykorzystany': 'Nie wykorzystany'; ?></td>
|
|
<td><?= $value['date_added']; ?></td>
|
|
<td class="edit-btn"><a href="/apanel/order_data/id=<?= $value['id']; ?>"><i
|
|
class="fa-regular fa-pen-to-square"></i></a></td>
|
|
</tr>
|
|
<? endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() {
|
|
var table = $('#myTable').DataTable({
|
|
"pagingType": "simple",
|
|
order: [
|
|
[0, 'desc']
|
|
],
|
|
});
|
|
});
|
|
</script>
|