Files
silaras-rssa/app/Views/tindakan/pilih_pasien.php
T

65 lines
1.3 KiB
PHP

<!DOCTYPE html>
<html lang="id">
<head>
<meta charset="UTF-8">
<title>Cari Pasien</title>
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet">
</head>
<body class="bg-light">
<div class="container mt-4">
<h4>Input Tindakan Ambulans</h4>
<!-- SEARCH -->
<form method="GET" action="<?= base_url('tindakan') ?>" class="mb-3">
<div class="input-group">
<input type="text" name="q" class="form-control"
placeholder="Cari nama / RM / register..."
value="<?= $_GET['q'] ?? '' ?>">
<button class="btn btn-primary">Cari</button>
</div>
</form>
<!-- TABLE HASIL -->
<div class="card">
<table class="table table-hover mb-0">
<thead>
<tr>
<th>RM</th>
<th>Register</th>
<th>Nama Pasien</th>
<th>Aksi</th>
</tr>
</thead>
<tbody>
<?php if (empty($pasien)) : ?>
<tr>
<td colspan="4" class="text-center">Data tidak ditemukan</td>
</tr>
<?php endif; ?>
<?php foreach($pasien as $p): ?>
<tr>
<td><?= $p['rm'] ?></td>
<td><?= $p['register'] ?></td>
<td><?= $p['nama'] ?></td>
<td>
<a href="<?= base_url('tindakan/input/'.$p['id']) ?>"
class="btn btn-success btn-sm">
Pilih
</a>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
</div>
</body>
</html>