130 lines
3.6 KiB
PHP
130 lines
3.6 KiB
PHP
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>E-Prescription</title>
|
|
<style>
|
|
body {
|
|
font-family: Arial, sans-serif;
|
|
text-align: center; /* Teks di tengah layar */
|
|
padding: 50px;
|
|
margin-top: 2px;;
|
|
font-size: 14px;
|
|
}
|
|
.header {
|
|
text-align: right;
|
|
margin-right: 2px;
|
|
margin-top: 0;
|
|
}
|
|
.header img {
|
|
max-width: 150px; /* Sesuaikan ukuran sesuai kebutuhan */
|
|
height: auto;
|
|
}
|
|
.right {
|
|
text-align: right; /* Teks di kanan */
|
|
}
|
|
.left {
|
|
text-align: left;
|
|
}
|
|
.footer {
|
|
width: 100%;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
}
|
|
.left-footer {
|
|
bottom: 0;
|
|
position: fixed;
|
|
float: left;
|
|
text-align: left;
|
|
}
|
|
.right-footer {
|
|
bottom: 0;
|
|
position: fixed;
|
|
float: right;
|
|
text-align: right;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="header">
|
|
<?php
|
|
// Path ke gambar
|
|
$gambarPath = public_path('images/logo-default.png');
|
|
|
|
// Membaca gambar dan mengonversi ke base64
|
|
$gambarBase64 = base64_encode(file_get_contents($gambarPath));
|
|
|
|
// Membuat tag img dengan base64 sebagai src
|
|
echo '<img src="data:image/png;base64,' . $gambarBase64 . '" alt="Logo" />';
|
|
?>
|
|
</div>
|
|
<h1 style="font-size: 14px;">E-PRESCRIPTION</h1>
|
|
<br>
|
|
<p class="right"><?=$tanggal_resep;?></p>
|
|
<p class="left"><?= isset($doctor) ? $doctor->user->detail->sTitlePrefix . ' ' . $doctor->user->sFirstName . ' ' . $doctor->user->sLastName . ' ' . $doctor->user->detail->sTitleSuffix : $prescription->sDokterName; ?></p>
|
|
<p class="left"><?= isset($doctor) ? $doctor->speciality->sSpesialis : '-'; ?></p>
|
|
<p class="left">Sip : <?= isset($doctor) ? $doctor->jadwalDokter[0]->sSIP : '-'; ?></p>
|
|
<br>
|
|
<p class="left">Patient Details</p>
|
|
<table width="100%">
|
|
<tbody>
|
|
<tr>
|
|
<td width="50%"><?=$pasien['name'];?></td>
|
|
<td width="50%"></td>
|
|
</tr>
|
|
<tr>
|
|
<td width="50%"><?=$pasien['tgl_lahir'];?></td>
|
|
<td width="50%"></td>
|
|
</tr>
|
|
<tr>
|
|
<td width="50%">(<?=$pasien['kelamin'];?>, <?=$pasien['umur'];?>)</td>
|
|
<td width="50%"></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<hr>
|
|
<br>
|
|
<?php foreach($items as $item){ ?>
|
|
<table width="100%">
|
|
<tbody>
|
|
<tr>
|
|
<td width="5%">R/</td>
|
|
<td width="50%"><?=$item->sItemName;?></td>
|
|
<td width="20%">@</td>
|
|
<td width="25%"><?=$item->nQty;?> Per <?= $item->sSatuan; ?></td>
|
|
</tr>
|
|
<tr>
|
|
<td width="5%"></td>
|
|
<td width="50%"><?= $item->sSigna ? '('.$item->sSigna.')' : ''; ?> per day</td>
|
|
<td width="20%"></td>
|
|
<td width="25%"></td>
|
|
</tr>
|
|
<tr>
|
|
<td width="5%"></td>
|
|
<td width="50%"><?= $item->sNote; ?></td>
|
|
<td width="20%"></td>
|
|
<td width="25%"></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<?php } ?>
|
|
<hr>
|
|
<p class="right">Valid Until <?=$valid_date;?></p>
|
|
<br>
|
|
<p class="left"></p>
|
|
<p class="left"></p>
|
|
<p class="left"></p>
|
|
<br>
|
|
<p class="left"></p>
|
|
<p class="left"></p>
|
|
<p class="left"></p>
|
|
<div class="footer">
|
|
<div class="left-footer">
|
|
<p>E-mail: helpdesk@linksehat.com</p>
|
|
</div>
|
|
<div class="right-footer">
|
|
<p>WA: +62 896-8177-3366</p>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|