fix: update signature logic for VALEIND with LinkSehat penjamin

This commit is contained in:
Iqbal
2026-05-09 13:06:55 +07:00
parent 4160021ffb
commit d935445ebc
2 changed files with 30 additions and 35 deletions

View File

@@ -625,16 +625,20 @@ class RequestLogController extends Controller
$ttdImage = null; $ttdImage = null;
if ($isVale) { if ($isVale) {
if ($dataRequestLog->submission_date <= '2025-05-12') { if (trim($data['penjamin']) === 'LinkSehat') {
$ttdNama = 'Dr. Hery Hermas, M.Kes'; $ttdNama = 'Fariz Ariyadi';
$ttdImage = public_path('images/ttd_dr_vale.png'); $ttdJabatan = 'Chief Executive Officer';
$ttdImage = public_path('images/ttd_fariz.png');
} else { } else {
$ttdNama = 'dr. Irmawati Baso, S. Ked., MM'; if ($dataRequestLog->submission_date <= '2025-05-12') {
$ttdImage = public_path('images/ttd_dr_irma_2.png'); $ttdNama = 'Dr. Hery Hermas, M.Kes';
$ttdImage = public_path('images/ttd_dr_vale.png');
} else {
$ttdNama = 'dr. Irmawati Baso, S. Ked., MM';
$ttdImage = public_path('images/ttd_dr_irma_2.png');
}
$ttdJabatan = 'Offsite Medical Treatment';
} }
$ttdJabatan = 'Offsite Medical Treatment';
} else { } else {
$ttdNama = 'Fariz Ariyadi'; $ttdNama = 'Fariz Ariyadi';
$ttdJabatan = 'Chief Executive Officer'; $ttdJabatan = 'Chief Executive Officer';
@@ -883,16 +887,20 @@ class RequestLogController extends Controller
$ttdImage = null; $ttdImage = null;
if ($isVale) { if ($isVale) {
if ($dataRequestLog->submission_date <= '2025-05-12') { if (trim($data['penjamin']) === 'LinkSehat') {
$ttdNama = 'Dr. Hery Hermas, M.Kes'; $ttdNama = 'Fariz Ariyadi';
$ttdImage = public_path('images/ttd_dr_vale.png'); $ttdJabatan = 'Chief Executive Officer';
$ttdImage = public_path('images/ttd_fariz.png');
} else { } else {
$ttdNama = 'dr. Irmawati Baso, S. Ked., MM'; if ($dataRequestLog->submission_date <= '2025-05-12') {
$ttdImage = public_path('images/ttd_dr_irma_2.png'); $ttdNama = 'Dr. Hery Hermas, M.Kes';
$ttdImage = public_path('images/ttd_dr_vale.png');
} else {
$ttdNama = 'dr. Irmawati Baso, S. Ked., MM';
$ttdImage = public_path('images/ttd_dr_irma_2.png');
}
$ttdJabatan = 'Offsite Medical Treatment';
} }
$ttdJabatan = 'Offsite Medical Treatment';
} else { } else {
$ttdNama = 'Fariz Ariyadi'; $ttdNama = 'Fariz Ariyadi';
$ttdJabatan = 'Chief Executive Officer'; $ttdJabatan = 'Chief Executive Officer';

View File

@@ -437,31 +437,18 @@
{{ $dataMember->nama_perusahaan }} {{ $dataMember->nama_perusahaan }}
</div> </div>
<div class="corner-text-<?php echo now()->timestamp; ?> bottom-left-ttd-2-<?php echo now()->timestamp; ?> "> <div class="corner-text-<?php echo now()->timestamp; ?> bottom-left-ttd-2-<?php echo now()->timestamp; ?> ">
<!-- @php @php
if(!empty($signatureDr->path)) { if(!empty($ttdImage) && file_exists($ttdImage)) {
$imgSrc = 'data:image/png;base64,' . base64_encode(file_get_contents(storage_path('app/public/' . $signatureDr->path))); $imgSrc = 'data:image/png;base64,' . base64_encode(file_get_contents($ttdImage));
echo '<img style="width: 65px; height: 48px;" src="' . $imgSrc . '">'; echo '<img style="width: 65px; height: 48px;" src="' . $imgSrc . '">';
} }
@endphp -->
@php
if(!empty($dataMember->code_perusahaan) == 'VALEIND' && $dataRequestLog->submission_date <= '2025-05-12') {
$imgSrc = 'data:image/png;base64,' . base64_encode(file_get_contents(public_path('images/ttd_dr_vale.png')));
echo '<img style="width: 65px; height: 48px;" src="' . $imgSrc . '">';
} else if(!empty($dataMember->code_perusahaan) == 'VALEIND'){
$imgSrc = 'data:image/png;base64,' . base64_encode(file_get_contents(public_path('images/ttd_dr_irma_2.png')));
echo '<img style="width: 65px; height: 48px;" src="' . $imgSrc . '">';
}
@endphp @endphp
</div> </div>
<div class="corner-text-<?php echo now()->timestamp; ?> bottom-left-ttd-<?php echo now()->timestamp; ?> "> <div class="corner-text-<?php echo now()->timestamp; ?> bottom-left-ttd-<?php echo now()->timestamp; ?> ">
@php @php
if ($dataMember->code_perusahaan == 'VALEIND' && $dataRequestLog->submission_date <= '2025-05-12') { if (!empty($ttdNama)) {
@endphp @endphp
<u><b>Dr. Hery Hermas, M.Kes</b></u> <u><b>{{ $ttdNama }}</b></u>
@php
} elseif ($dataMember->code_perusahaan == 'VALEIND') {
@endphp
<u><b>dr. Irmawati Baso, S. Ked., MM</b></u>
@php @php
} else { } else {
@endphp @endphp
@@ -470,7 +457,7 @@
} }
@endphp @endphp
<br><b>Offsite Medical Treatment</b> <br><b>{{ $ttdJabatan ?? 'Offsite Medical Treatment' }}</b>
</div> </div>
<div class="corner-text-<?php echo now()->timestamp; ?> bottom-right-ttd-1-<?php echo now()->timestamp; ?> "> <div class="corner-text-<?php echo now()->timestamp; ?> bottom-right-ttd-1-<?php echo now()->timestamp; ?> ">
{{ \Carbon\Carbon::parse($request_logs->approved_at)->format('d M Y') }},<br> {{ \Carbon\Carbon::parse($request_logs->approved_at)->format('d M Y') }},<br>