check headr file import peserta
This commit is contained in:
@@ -18,8 +18,28 @@
|
||||
@if(session('import_result'))
|
||||
@php $r = session('import_result'); @endphp
|
||||
|
||||
{{-- Invalid headers --}}
|
||||
@if(!empty($r['invalid_headers']))
|
||||
<div class="card border-0 shadow-sm mb-4 border-start border-4 border-danger">
|
||||
<div class="card-body">
|
||||
<h6 class="fw-semibold mb-2 text-danger">
|
||||
<i class="bi bi-x-circle me-2"></i>Format Header CSV Tidak Sah
|
||||
</h6>
|
||||
<p class="small text-muted mb-2">
|
||||
Baris pertama fail CSV mesti mengandungi header yang betul mengikut susunan ini:
|
||||
</p>
|
||||
<code class="d-block bg-light p-2 rounded small mb-3">name,no_kp,email,phone,agency</code>
|
||||
@if(!empty($r['found_headers']))
|
||||
<p class="small text-muted mb-0">
|
||||
<i class="bi bi-exclamation-triangle text-warning me-1"></i>
|
||||
Header yang dijumpai: <code>{{ $r['found_headers'] }}</code>
|
||||
</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- All IC empty — offer delete --}}
|
||||
@if(!empty($r['all_empty_ic']))
|
||||
@elseif(!empty($r['all_empty_ic']))
|
||||
<div class="card border-0 shadow-sm mb-4 border-start border-4 border-warning">
|
||||
<div class="card-body">
|
||||
<h6 class="fw-semibold mb-2 text-warning">
|
||||
@@ -41,6 +61,7 @@
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
{{-- Normal import result --}}
|
||||
<div class="card border-0 shadow-sm mb-4 border-start border-4
|
||||
{{ $r['failed'] > 0 ? 'border-warning' : 'border-success' }}">
|
||||
<div class="card-body">
|
||||
|
||||
Reference in New Issue
Block a user