Khazanah ->laporan marhun keluar/ masuk
This commit is contained in:
@@ -1930,5 +1930,76 @@ class MarhunController extends Controller
|
||||
|
||||
return $pdf->download('Senarai SAG Telah Serah Kepada Pembida.pdf');
|
||||
}
|
||||
|
||||
public function senaraiscanbarcode(Request $request){
|
||||
|
||||
$auth_user = Auth::user();
|
||||
|
||||
$auth_user = ScanSemak::where('kodcaw','=',$auth_user['kodcaw'] )
|
||||
->get();
|
||||
|
||||
return view('marhun.senaraiscanbarcode', compact('auth_user','auth_user'));
|
||||
|
||||
}
|
||||
|
||||
public function cetakscanbarcode(Request $request)
|
||||
{
|
||||
|
||||
$auth_user = Auth::user();
|
||||
$current = Carbon::now();
|
||||
$current = new Carbon();
|
||||
$tarikh_cetak = $current->toDateString();
|
||||
|
||||
if($request->datemula == null){
|
||||
$mula_date = '2017-01-01';
|
||||
}else{
|
||||
$split_date = explode('-', $request->datemula);
|
||||
$mula_date = $split_date[2] . '-' . $split_date[1] . '-' . $split_date[0];
|
||||
}
|
||||
|
||||
if($request->datehingga == null){
|
||||
$hingga_date = $current->toDateString();
|
||||
}else{
|
||||
$split_date = explode('-', $request->datehingga);
|
||||
$hingga_date = $split_date[2] . '-' . $split_date[1] . '-' . $split_date[0];
|
||||
}
|
||||
|
||||
$kodcaw = $auth_user['kodcaw'];
|
||||
|
||||
$cawangan = Cawangan::where('caw_code','=',$kodcaw)
|
||||
->first();
|
||||
|
||||
if($request->jenis == 'keluar')
|
||||
{
|
||||
$scan=ScanSemak::where('kodcaw','=',$kodcaw)
|
||||
->where([['scan_keluar','>=',$request->datemula],['scan_keluar','<=',$request->datehingga]])
|
||||
->get();
|
||||
|
||||
return view('pdf.laporanscankeluar', compact('scan','auth_user','tarikh_cetak','cawangan'));
|
||||
|
||||
}
|
||||
|
||||
else if($request->jenis == 'masuk'){
|
||||
|
||||
$scan=ScanSemak::where('kodcaw','=',$kodcaw)
|
||||
->where([['scan_masuk','>=',$request->datemula],['scan_masuk','<=',$request->datehingga]])
|
||||
->get();
|
||||
// dd($scan);
|
||||
|
||||
return view('pdf.laporanscanmasuk', compact('scan','auth_user','tarikh_cetak','cawangan'));
|
||||
|
||||
}
|
||||
|
||||
// else{
|
||||
// $scan=ScanJual::where('kodcaw','=',$kodcaw)
|
||||
// ->where([['serah_marhun','>=',$request->datemula],['serah_marhun','<=',$request->datehingga]])
|
||||
// ->where('serahkpdpembida','=',1)
|
||||
// ->get();
|
||||
|
||||
// return view('pdf.laporanscanserah', compact('scan','auth_user','tarikh_cetak','cawangan'));
|
||||
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -66,6 +66,9 @@
|
||||
<li class="{{ (request()->is('marhun/senarailelongscanjual') )}}">
|
||||
<a href="{{url('marhun/senarailelongscanjual')}}">Scan Barcode Serahan Pembida</a>
|
||||
</li>
|
||||
<li class="{{ (request()->is('marhun/senaraiscanbarcode') )}}">
|
||||
<a href="{{url('marhun/senaraiscanbarcode')}}">Laporan Scan Barcode</a>
|
||||
</li>
|
||||
@endhasrole
|
||||
@hasrole('penilai')
|
||||
<li class="{{ (request()->is('marhun/senarailelongterimaserah') || request()->is('marhun/senarailelongterimaserah/*')) ? 'active' : '' }}">
|
||||
|
||||
@@ -0,0 +1,162 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
<style>
|
||||
|
||||
.radiostyle .radio-green {
|
||||
background-color: #27ae60;
|
||||
color:white;
|
||||
box-shadow: 5px 10px #888888;
|
||||
width:200px;
|
||||
margin-right:5px;
|
||||
transition: 0.5s ease;
|
||||
}
|
||||
|
||||
.radiostyle .radio-red {
|
||||
background-color: #e74c3c;
|
||||
color:white;
|
||||
width:200px;
|
||||
margin-right:5px;
|
||||
box-shadow: 5px 10px #888888;
|
||||
transition: 0.5s ease;
|
||||
}
|
||||
|
||||
.radiostyle .radio-yellow {
|
||||
background-color: #3498db;
|
||||
color:white;
|
||||
width:200px;
|
||||
margin-right:5px;
|
||||
box-shadow: 5px 10px #888888;
|
||||
transition: 0.5s ease;
|
||||
}
|
||||
|
||||
.radiostyle .radio-green:hover {
|
||||
box-shadow: 5px 5px #888888;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.radiostyle .radio-red:hover {
|
||||
box-shadow: 5px 5px #888888;
|
||||
|
||||
}
|
||||
|
||||
.radiostyle .radio-yellow:hover {
|
||||
box-shadow: 5px 5px #888888;
|
||||
|
||||
}
|
||||
|
||||
.radiostyle .radio-green input[type="radio"]:checked{
|
||||
box-shadow: 5px 10px #888888;
|
||||
}
|
||||
|
||||
.radiostyle .radio-yellow input[type="radio"]:checked{
|
||||
box-shadow: 5px 10px #888888;
|
||||
}
|
||||
|
||||
.radiostyle .radio-red input[type="radio"]:checked{
|
||||
box-shadow: 5px 10px #888888;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
|
||||
|
||||
|
||||
@section('content')
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="card">
|
||||
|
||||
|
||||
<div class="card-body text-center">
|
||||
<div class="row form-group">
|
||||
<div class="col-md-3">
|
||||
<h4> Laporan Scan Barcode</h4>
|
||||
</div>
|
||||
|
||||
<div class="col-md-10">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-8 mx-auto">
|
||||
<form action="{{ route('marhun.cetakscanbarcode') }}" target="_blank" method="post">
|
||||
@csrf
|
||||
<div class="input-group mb-3">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text" id="basic-addon1">Mula</span>
|
||||
</div>
|
||||
<input type="date" class="form-control" placeholder="Pilih Tarikh" aria-label="Tarikh" id="datemula" name="datemula">
|
||||
<div class="input-group-prepend ml-2">
|
||||
<span class="input-group-text" id="basic-addon1">Hingga</span>
|
||||
</div>
|
||||
<input type="date" class="form-control" placeholder="Pilih Tarikh" aria-label="Tarikh" id="datehingga" name="datehingga">
|
||||
<input type="submit" class="btn btn-primary ml-md-5" id="submit_button" name="submit_button" value="Cetak">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<br><br>
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-12 col-sm-12 mb-4">
|
||||
|
||||
<input autocomplete="off" type="radio" name="jenis" id="option1" value="keluar" autocomplete="off" checked>
|
||||
<span>SAG Keluar</span>
|
||||
|
||||
<input autocomplete="off" type="radio" name="jenis" id="option2" value="masuk" autocomplete="off">
|
||||
<span>SAG Masuk</span>
|
||||
|
||||
{{-- <input autocomplete="off" type="radio" name="jenis" id="option3" value="serah" autocomplete="off">
|
||||
<span>SAG Serah</span> --}}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
|
||||
var tablecustomers = $('#myTable').DataTable({
|
||||
"ordering": false
|
||||
});
|
||||
|
||||
$(document).ready( function () {
|
||||
var today = new Date();
|
||||
|
||||
var dateObject = '';
|
||||
$('#datemula').datepicker({
|
||||
maxViewMode:1,
|
||||
format: 'dd-mm-yyyy',
|
||||
autoclose:true,
|
||||
endDate: "today",
|
||||
maxDate: today
|
||||
});
|
||||
|
||||
$('#datehingga').datepicker({
|
||||
maxViewMode:1,
|
||||
format: 'dd-mm-yyyy',
|
||||
autoclose:true,
|
||||
endDate: "today",
|
||||
maxDate: today
|
||||
});
|
||||
|
||||
$('#datemula').change(function() {
|
||||
|
||||
$('#datehingga').datepicker('option', 'maxDate', new Date($(this).val()));
|
||||
console.log($(this).val());
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@endsection
|
||||
@@ -0,0 +1,136 @@
|
||||
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
||||
<style>
|
||||
#sim {
|
||||
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
|
||||
font-size:10px;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#sim td {padding:3px 5px 3px 5px; padding-right:10px;}, #sim th {
|
||||
border: 0px solid;
|
||||
padding: 1px;
|
||||
text-align: left;
|
||||
|
||||
}
|
||||
|
||||
#sim tr:nth-child(even){}
|
||||
|
||||
#sim tr:hover {}
|
||||
|
||||
#sim th {
|
||||
text-align: left;
|
||||
border: 0px solid;
|
||||
table-layout:auto;
|
||||
color: black;
|
||||
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.row {
|
||||
margin-left:-5px;
|
||||
margin-right:-5px;
|
||||
}
|
||||
|
||||
.column {
|
||||
float: left;
|
||||
width: 100%;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
/* Clearfix (clear floats) */
|
||||
.row::after {
|
||||
content: "";
|
||||
clear: both;
|
||||
display: table;
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
width: 200%;
|
||||
border: 0px solid #ddd;
|
||||
}
|
||||
|
||||
td {
|
||||
text-align: left;
|
||||
padding: 16px;
|
||||
}
|
||||
|
||||
th{
|
||||
text-align: left;
|
||||
padding: 16px;
|
||||
background-color:gainsboro;
|
||||
}
|
||||
|
||||
tr:nth-child(even) {
|
||||
background-color: #f2f2f2;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%" border="0" id="sim">
|
||||
<tr>
|
||||
<td width="50%"><h3>PERMODALAN KELANTAN BERHAD</h3></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2"><u><b>LAPORAN SCAN KELUAR BARCODE</b></u></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table cellspacing="" cellpadding="5" text-align="left" border="0" height="25" align="left" id="sim">
|
||||
<thead>
|
||||
<br>
|
||||
<tr>
|
||||
|
||||
<td>Cawangan : {{$cawangan->caw_name}}
|
||||
|
||||
<td>Tarikh Cetak:@php
|
||||
$myDateTime = DateTime::createFromFormat('Y-m-d', $tarikh_cetak );
|
||||
$t_lelong = $myDateTime->format('d-m-Y');
|
||||
echo($t_lelong);
|
||||
@endphp</td>
|
||||
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
<table cellspacing="0" cellpadding="5" style="float:right;" border="0" width="100%" height="80" align="left" id="sim">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>No</th>
|
||||
<th>No Rujukan</th>
|
||||
<th>Tarikh/Masa Scan Keluar</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@foreach ($scan as $keluar)
|
||||
<tr>
|
||||
<td>{{ $loop->iteration }}</td>
|
||||
<td>{{ $keluar['norujukan'] }}</td>
|
||||
<td>{{ $keluar['scan_keluar'] }}</td>
|
||||
|
||||
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</tbody>
|
||||
|
||||
@@ -0,0 +1,136 @@
|
||||
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
||||
<style>
|
||||
#sim {
|
||||
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
|
||||
font-size:10px;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#sim td {padding:3px 5px 3px 5px; padding-right:10px;}, #sim th {
|
||||
border: 0px solid;
|
||||
padding: 1px;
|
||||
text-align: left;
|
||||
|
||||
}
|
||||
|
||||
#sim tr:nth-child(even){}
|
||||
|
||||
#sim tr:hover {}
|
||||
|
||||
#sim th {
|
||||
text-align: left;
|
||||
border: 0px solid;
|
||||
table-layout:auto;
|
||||
color: black;
|
||||
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.row {
|
||||
margin-left:-5px;
|
||||
margin-right:-5px;
|
||||
}
|
||||
|
||||
.column {
|
||||
float: left;
|
||||
width: 100%;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
/* Clearfix (clear floats) */
|
||||
.row::after {
|
||||
content: "";
|
||||
clear: both;
|
||||
display: table;
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
width: 200%;
|
||||
border: 0px solid #ddd;
|
||||
}
|
||||
|
||||
td {
|
||||
text-align: left;
|
||||
padding: 16px;
|
||||
}
|
||||
|
||||
th{
|
||||
text-align: left;
|
||||
padding: 16px;
|
||||
background-color:gainsboro;
|
||||
}
|
||||
|
||||
tr:nth-child(even) {
|
||||
background-color: #f2f2f2;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%" border="0" id="sim">
|
||||
<tr>
|
||||
<td width="50%"><h3>PERMODALAN KELANTAN BERHAD</h3></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2"><u><b>LAPORAN SCAN MASUK BARCODE</b></u></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table cellspacing="" cellpadding="5" text-align="left" border="0" height="25" align="left" id="sim">
|
||||
<thead>
|
||||
<br>
|
||||
<tr>
|
||||
|
||||
<td>Cawangan : {{$cawangan->caw_name}}
|
||||
|
||||
<td>Tarikh Cetak:@php
|
||||
$myDateTime = DateTime::createFromFormat('Y-m-d', $tarikh_cetak );
|
||||
$t_lelong = $myDateTime->format('d-m-Y');
|
||||
echo($t_lelong);
|
||||
@endphp</td>
|
||||
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
<table cellspacing="0" cellpadding="5" style="float:right;" border="0" width="100%" height="80" align="left" id="sim">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>No</th>
|
||||
<th>No Rujukan</th>
|
||||
<th>Tarikh/Masa Scan Masuk</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@foreach ($scan as $masuk)
|
||||
<tr>
|
||||
<td>{{ $loop->iteration }}</td>
|
||||
<td>{{ $masuk['norujukan'] }}</td>
|
||||
<td>{{ $masuk['scan_masuk'] }}</td>
|
||||
|
||||
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</tbody>
|
||||
|
||||
@@ -265,6 +265,9 @@ Route::group(['middleware' => ['permission:semakanmarhun','permission:kemaskinim
|
||||
Route::get('/scanbarcodejual/{lelong_id}',['as'=>'marhun.scanbarcodejual','uses'=>'MarhunController@listScanBarcodejual']);
|
||||
Route::post('/scankeluarmarhunjual',['as'=>'marhun.scankeluarmarhunjual','uses'=>'MarhunController@scanKeluarMarhunjual']);
|
||||
Route::get('/cetakkeluarscanbarcodejual/{lelong_id}',['as'=>'marhun.cetakkeluarscanbarcodejual','uses'=>'MarhunController@cetakkeluarscanbarcodejual']);
|
||||
Route::get('/senaraiscanbarcode',['as'=>'marhun.senaraiscanbarcode','uses'=>'MarhunController@senaraiscanbarcode']);
|
||||
Route::post('/cetakscanbarcode',['as'=>'marhun.cetakscanbarcode','uses'=>'MarhunController@cetakscanbarcode']);
|
||||
|
||||
|
||||
//Penilai
|
||||
Route::post('/addphotomarhun',['as'=>'marhun.addphotomarhun','uses'=>'MarhunController@addPhotoMarhun']);
|
||||
|
||||
Reference in New Issue
Block a user