54 lines
2.4 KiB
PHP
54 lines
2.4 KiB
PHP
<?php
|
|
declare(strict_types=1);
|
|
|
|
$orders = is_array($orders ?? null) ? $orders : [];
|
|
?>
|
|
<section class="page-heading">
|
|
<div class="container">
|
|
<h1>My Servers</h1>
|
|
<p>Review website orders tied to your account. Use the GSP control panel for live server controls, files, logs, backups, and operational management.</p>
|
|
</div>
|
|
</section>
|
|
|
|
<section class="section">
|
|
<div class="container">
|
|
<div class="card-actions" style="margin-bottom: 1rem;">
|
|
<a class="button button-primary" href="<?= website_escape(panel_url('home.php?m=gamemanager&p=game_monitor')) ?>">Open GSP Control Panel</a>
|
|
<a class="button button-secondary" href="<?= website_escape(website_url('serverlist.php')) ?>">Order Another Server</a>
|
|
</div>
|
|
|
|
<?php if (empty($orders)): ?>
|
|
<div class="notice-card">
|
|
<h2>No Website Server Orders Yet</h2>
|
|
<p>Orders created through Gameservers.World will appear here after checkout. Existing Panel-assigned servers remain available in the GSP control panel.</p>
|
|
</div>
|
|
<?php else: ?>
|
|
<div class="table-wrap">
|
|
<table class="data-table">
|
|
<thead>
|
|
<tr>
|
|
<th>Order</th>
|
|
<th>Server</th>
|
|
<th>Status</th>
|
|
<th>Slots</th>
|
|
<th>Home ID</th>
|
|
<th>Ordered</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<?php foreach ($orders as $order): ?>
|
|
<tr>
|
|
<td>#<?= (int)($order['order_id'] ?? 0) ?></td>
|
|
<td><?= website_escape($order['home_name'] ?? 'Game Server') ?></td>
|
|
<td><?= website_escape($order['status'] ?? 'unknown') ?></td>
|
|
<td><?= (int)($order['max_players'] ?? 0) ?></td>
|
|
<td><?= (int)($order['home_id'] ?? 0) ?: 'Pending' ?></td>
|
|
<td><?= website_escape($order['order_date'] ?? '') ?></td>
|
|
</tr>
|
|
<?php endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<?php endif; ?>
|
|
</div>
|
|
</section>
|