173 lines
7.4 KiB
PHP
173 lines
7.4 KiB
PHP
@extends('layouts.app')
|
|
|
|
@section('content')
|
|
<div class="container-fluid">
|
|
<div class="row ">
|
|
<div class="col mx-auto p-4">
|
|
<div class="card">
|
|
<div class="card-header header-style">
|
|
<a href="{{ route('report.lapubahmarhunlelong') }}" class="header-style-icon">
|
|
<i class="fas fa-arrow-left"></i>
|
|
</a>
|
|
<div class="header-style-title">
|
|
Senarai SAG Perubahan Marhun: {{$getpengesahan['caw_name']}}
|
|
</div>
|
|
</div>
|
|
<div class="card-body">
|
|
@if ($message = Session::get('success'))
|
|
<div class="alert alert-success">
|
|
<p>{{ $message }}</p>
|
|
</div>
|
|
@endif
|
|
<table class='table text-center table-bordered table-hover' id="tablelelong" style="width:100%">
|
|
<thead class="bg-primary text-white">
|
|
<tr>
|
|
<th>Bil</th>
|
|
<th>No Rujukan</th>
|
|
<th>Perubahan</th>
|
|
<th>Marhun Asal</th>
|
|
<th>Marhun Baru</th>
|
|
<th>Mutu Asal</th>
|
|
<th>Mutu Baru</th>
|
|
<th>Berat Asal (gm)</th>
|
|
<th>Berat Baru (gm)</th>
|
|
<th>Diminta Oleh</th>
|
|
<th>Disahkan Oleh</th>
|
|
<th>Status</th>
|
|
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@forelse($cawangan as $marhun)
|
|
<tr>
|
|
<td>{{ $loop->iteration }}</td>
|
|
<td>{{ $marhun['norujukan'] }}</td>
|
|
<td>@foreach ($marhun['detailmarhun'] as $item)
|
|
@if($item['status_ubah'] == 1)
|
|
Mutu
|
|
@elseif($item['status_ubah'] == 2)
|
|
Pertambahan Marhun
|
|
@elseif($item['status_ubah'] == 3)
|
|
Hapus Marhun
|
|
@elseif($item['status_ubah'] == 4)
|
|
Berat
|
|
@elseif($item['status_ubah'] == 5)
|
|
Mutu & Berat
|
|
@elseif($item['status_ubah'] == 7)
|
|
Marhun
|
|
@elseif($item['status_ubah'] == 8)
|
|
Mutu, Berat & Marhun
|
|
@elseif($item['status_ubah'] == 9)
|
|
Mutu & Marhun
|
|
@elseif($item['status_ubah'] == 10)
|
|
Berat & Marhun
|
|
@endif
|
|
<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detail'] as $item)
|
|
{{$item['old_marhun']}}<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detailmarhun'] as $item)
|
|
@if($item['request_marhun'] == null)
|
|
@else
|
|
<i class="btn fa fa-arrow-right" aria-hidden="true" style="font-size: 10px"></i>
|
|
@endif {{$item['request_marhun']}}<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detail'] as $item)
|
|
{{$item['old_karat']}}<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detailmarhun'] as $item)
|
|
@if($item['request_karat'] == null)
|
|
@else
|
|
<i class="btn fa fa-arrow-right" aria-hidden="true" style="font-size: 10px"></i>
|
|
@endif{{$item['request_karat']}}<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detail'] as $item)
|
|
{{$item['old_berat']}}<br>
|
|
@endforeach</td>
|
|
<td>@foreach ($marhun['detailmarhun'] as $item)
|
|
@if($item['request_berat'] == null)
|
|
@else
|
|
<i class="btn fa fa-arrow-right" aria-hidden="true" style="font-size: 10px"></i>
|
|
@endif{{$item['request_berat']}}<br>
|
|
@endforeach</td>
|
|
|
|
<td>{{ $marhun['diminta_oleh'] }}</td>
|
|
<td>{{ $marhun['disahkan_oleh'] }}</td>
|
|
<td><button class="btn btn-success btn-sm hovernone-success" disabled>BERJAYA DISAHKAN</button></td>
|
|
|
|
</tr>
|
|
@empty
|
|
<tr>
|
|
<td colspan="7">No Data</td>
|
|
</tr>
|
|
|
|
@endforelse
|
|
</tbody>
|
|
|
|
</table>
|
|
<div class="modal-footer" style="margin-top:2%;">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script>
|
|
//Enable tooltips everywhere
|
|
$(function () {
|
|
$('[data-toggle="tooltip"]').tooltip()
|
|
})
|
|
|
|
var tablelelong = $('#tablelelong').DataTable( {
|
|
"columnDefs": [
|
|
{
|
|
"targets": 0,
|
|
"orderable": false
|
|
},
|
|
{
|
|
"targets": 4,
|
|
"orderable": false
|
|
}
|
|
],
|
|
order: [[0, 'asc']],
|
|
// "ordering": false,
|
|
"info": false,
|
|
"lengthChange": false,
|
|
"pageLength": 15,
|
|
// dom: 'Bfrtip',
|
|
// buttons: [
|
|
// // 'copy', 'excel', 'pdf'
|
|
// // { text: 'copy', className: 'btn btn-primary' },
|
|
// {
|
|
// className: 'btn btn-outline-success pl-4 pr-4 btn-sm addsim',
|
|
// text: '<i class="fas fa-plus" id="test"></i>',
|
|
// titleAttr: 'Tambah Simulasi',
|
|
// action: function ( e, dt, node, config ) {
|
|
// alert( 'Button activated' );
|
|
// }
|
|
// },
|
|
// {
|
|
// className: 'btn btn-outline-secondary pl-4 pr-4 btn-sm export',
|
|
// titleAttr: 'Export to CSV',
|
|
// text: '<i class="fas fa-download"></i>',
|
|
// action: function ( e, dt, node, config ) {
|
|
// $("#exportform").submit();
|
|
// }
|
|
// }
|
|
// ]
|
|
});
|
|
|
|
// $('.addsim').tooltip();
|
|
// $('.export').tooltip();
|
|
// // $( '.dt-buttons').addClass('btn-group');
|
|
// $( '.addsim').removeClass('dt-button');
|
|
// $( '.export').removeClass('dt-button');
|
|
|
|
// function selectall(cb) {
|
|
// tablelelong.rows().nodes().to$().find('input[type="checkbox"]').each(function(){
|
|
// $(this).prop('checked', cb.checked);
|
|
// })
|
|
// }
|
|
</script>
|
|
|
|
@endsection
|