update kelulusan ubah marhun dari pageoperasi kpd page PC
This commit is contained in:
@@ -87,12 +87,13 @@ class HomeController extends Controller
|
||||
$arrayinfomutu = [];
|
||||
//HOME KELULUSAN MUTU MARHUN
|
||||
$lelongmutu = pengesahan::join('lelong','lelong.id','=','pengesahan.lelong_id')
|
||||
->join('lelongbid','lelongbid.norujukan','=','pengesahan.norujukan')
|
||||
// ->where('sts_lelong', 0)
|
||||
->where('lelongbid.kodcaw', $user->kodcaw)
|
||||
->whereIn('pengesahan.status_ubah', [1,2,3,4,5])
|
||||
->where('disahkan_oleh','=', NULL)
|
||||
->select('pengesahan.lelong_id','lelong.id','lelong.tarikh_lelong','lelong.masatamat_lelong','lelong.harga_emas_asas','lelong.jbg','lelong.cajlelong','sts_lelong')
|
||||
// ->groupBy('pengesahan.lelong_id')
|
||||
|
||||
->distinct()
|
||||
->get()
|
||||
->toArray();
|
||||
@@ -103,6 +104,7 @@ class HomeController extends Controller
|
||||
foreach($lelongmutu as $infomutu)
|
||||
{
|
||||
$detailsinfo = CawanganLelong::join('cawangan','cawangan_lelong.caw_id','=','cawangan.id')
|
||||
->where('cawangan.caw_code', $user->kodcaw)
|
||||
->where('lelong_id',$infomutu['lelong_id'])
|
||||
->get()
|
||||
->toArray();
|
||||
@@ -138,9 +140,11 @@ class HomeController extends Controller
|
||||
public function senarailelongubahmutu()
|
||||
{
|
||||
$arrayinfo = [];
|
||||
$user = Auth::user();
|
||||
// dd($user->kodcaw);
|
||||
|
||||
$lelong = pengesahan::join('lelong','lelong.id','=','pengesahan.lelong_id')
|
||||
// ->where('sts_lelong', 0)
|
||||
|
||||
->whereIn('pengesahan.status_ubah', [1,2,3,4,5])
|
||||
->select('pengesahan.lelong_id','lelong.id','lelong.tarikh_lelong','lelong.masatamat_lelong','lelong.harga_emas_asas','lelong.jbg','lelong.cajlelong','sts_lelong')
|
||||
// ->groupBy('pengesahan.lelong_id')
|
||||
|
||||
@@ -700,11 +700,11 @@ class MarhunController extends Controller
|
||||
public function senarailelongubahmutu()
|
||||
{
|
||||
$arrayinfo = [];
|
||||
|
||||
|
||||
$lelong = pengesahan::join('lelong','lelong.id','=','pengesahan.lelong_id')
|
||||
// ->where('sts_lelong', 0)
|
||||
->whereIn('pengesahan.status_ubah', [1,2,3,4,5])
|
||||
->select('pengesahan.lelong_id','lelong.id','lelong.tarikh_lelong','lelong.masatamat_lelong','lelong.harga_emas_asas','lelong.jbg','lelong.cajlelong','sts_lelong')
|
||||
->select('lelong.fasa','pengesahan.lelong_id','lelong.id','lelong.tarikh_lelong','lelong.masatamat_lelong','lelong.harga_emas_asas','lelong.jbg','lelong.cajlelong','sts_lelong')
|
||||
// ->groupBy('pengesahan.lelong_id')
|
||||
|
||||
->distinct()
|
||||
@@ -725,19 +725,23 @@ class MarhunController extends Controller
|
||||
}
|
||||
|
||||
public function sahubahmutu($id){
|
||||
|
||||
$mutumarhun = Pengesahan::whereNull('disahkan_oleh')
|
||||
|
||||
$user = Auth::user();
|
||||
$mutumarhun = Pengesahan::join('lelongbid','lelongbid.norujukan','=','pengesahan.norujukan')
|
||||
->where('lelongbid.kodcaw', $user->kodcaw)
|
||||
->whereNull('disahkan_oleh')
|
||||
->whereNull('disahkan_pada')
|
||||
->where('lelong_id', $id)
|
||||
->where('pengesahan.lelong_id', $id)
|
||||
->whereIn('status_ubah', [1,2,3,4,5])
|
||||
->selectRaw('count(*) as total, sum(status) as tstat,norujukan')
|
||||
->groupBy('norujukan')
|
||||
->selectRaw('count(*) as total, sum(status) as tstat,pengesahan.norujukan')
|
||||
->groupBy('pengesahan.norujukan')
|
||||
->get()
|
||||
->toArray();
|
||||
|
||||
foreach($mutumarhun as $index1=>$mutu)
|
||||
{
|
||||
$cawangan = LelongBid::join('cawangan', 'lelongbid.caw_id', 'cawangan.id')
|
||||
->where('lelongbid.kodcaw', $user->kodcaw)
|
||||
->where('lelongbid.lelong_id', $id)
|
||||
->where('lelongbid.norujukan', $mutu['norujukan'])
|
||||
->select('cawangan.caw_name')
|
||||
|
||||
@@ -44,6 +44,66 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@php
|
||||
@empty($arrayinfomutu)
|
||||
@endphp
|
||||
|
||||
@if(count($arrayinfomutu)> 0)
|
||||
KELULUSAN UBAH MARHUN
|
||||
<table class="table table-striped table-xl text-center" id="tablelelong" style="width:100%">
|
||||
<thead class="bg-primary text-white">
|
||||
<tr>
|
||||
<th>No</th>
|
||||
<th>ID Lelong</th>
|
||||
<th>Cawangan</th>
|
||||
<th>Tarikh Lelong</th>
|
||||
<th>Harga Emas Asas</th>
|
||||
<th>Tempoh</th>
|
||||
<th>Caj Lelong</th>
|
||||
<th>Status Lelong</th>
|
||||
<th class="text-center">Pengesahan</th>
|
||||
<th class="text-center">Telah Sah</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($arrayinfomutu as $lel)
|
||||
<tr>
|
||||
<td>{{$loop->iteration}}</td>
|
||||
<td>{{ $lel['info']['lelong_id'] }}</td>
|
||||
<td align = 'left'>
|
||||
@foreach($lel['detailsinfo'] as $details)
|
||||
<span class="m-2">{{$details['caw_name']}}</span><br>
|
||||
@endforeach
|
||||
</td>
|
||||
<td> @php
|
||||
$myDateTime = DateTime::createFromFormat('Y-m-d', $lel['info']['tarikh_lelong']);
|
||||
$datez = $myDateTime->format('d-m-Y');
|
||||
echo($datez);
|
||||
|
||||
@endphp</td>
|
||||
|
||||
<td>{{ number_format($lel['info']['harga_emas_asas'], 2, '.', ',')}}</td>
|
||||
<td>{{ $lel['info']['jbg'] }}</td>
|
||||
<td>{{ $lel['info']['cajlelong'] }}</td>
|
||||
<td>
|
||||
@if($lel['info']['sts_lelong'] == 0)
|
||||
<button class="btn btn-warning btn-sm" disabled>LELONG BELUM BERMULA</button>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('pengesahan.perubahanmutumarhun', ['id'=>$lel['info']['lelong_id']]) }}" data-toggle="tooltip" data-placement="top" title="Butiran" class="text-center" ><i class="far fa-edit"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('pengesahan.listperubahanmutumarhun', ['id'=>$lel['info']['lelong_id']]) }}" data-toggle="tooltip" data-placement="top" title="Butiran" class="text-center" ><i class="far fa-user"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
@endif
|
||||
@php
|
||||
|
||||
@endphp
|
||||
@endhasrole
|
||||
@hasrole('pengurus-cawangan-khas')
|
||||
I am a pengurus-cawangan-khas!
|
||||
@@ -200,66 +260,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@php
|
||||
@empty($arrayinfomutu)
|
||||
@endphp
|
||||
|
||||
@if(count($arrayinfomutu)> 0)
|
||||
KELULUSAN UBAH MARHUN
|
||||
<table class="table table-striped table-xl text-center" id="tablelelong" style="width:100%">
|
||||
<thead class="bg-primary text-white">
|
||||
<tr>
|
||||
<th>No</th>
|
||||
<th>ID Lelong</th>
|
||||
<th>Cawangan</th>
|
||||
<th>Tarikh Lelong</th>
|
||||
<th>Harga Emas Asas</th>
|
||||
<th>Tempoh</th>
|
||||
<th>Caj Lelong</th>
|
||||
<th>Status Lelong</th>
|
||||
<th class="text-center">Pengesahan</th>
|
||||
<th class="text-center">Telah Sah</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($arrayinfomutu as $lel)
|
||||
<tr>
|
||||
<td>{{$loop->iteration}}</td>
|
||||
<td>{{ $lel['info']['lelong_id'] }}</td>
|
||||
<td align = 'left'>
|
||||
@foreach($lel['detailsinfo'] as $details)
|
||||
<span class="m-2">{{$details['caw_name']}}</span><br>
|
||||
@endforeach
|
||||
</td>
|
||||
<td> @php
|
||||
$myDateTime = DateTime::createFromFormat('Y-m-d', $lel['info']['tarikh_lelong']);
|
||||
$datez = $myDateTime->format('d-m-Y');
|
||||
echo($datez);
|
||||
|
||||
@endphp</td>
|
||||
|
||||
<td>{{ number_format($lel['info']['harga_emas_asas'], 2, '.', ',')}}</td>
|
||||
<td>{{ $lel['info']['jbg'] }}</td>
|
||||
<td>{{ $lel['info']['cajlelong'] }}</td>
|
||||
<td>
|
||||
@if($lel['info']['sts_lelong'] == 0)
|
||||
<button class="btn btn-warning btn-sm" disabled>LELONG BELUM BERMULA</button>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('pengesahan.perubahanmutumarhun', ['id'=>$lel['info']['lelong_id']]) }}" data-toggle="tooltip" data-placement="top" title="Butiran" class="text-center" ><i class="far fa-edit"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('pengesahan.listperubahanmutumarhun', ['id'=>$lel['info']['lelong_id']]) }}" data-toggle="tooltip" data-placement="top" title="Butiran" class="text-center" ><i class="far fa-user"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
@endif
|
||||
@php
|
||||
|
||||
@endphp
|
||||
|
||||
|
||||
@endhasrole
|
||||
@hasrole('account')
|
||||
|
||||
@@ -20,8 +20,9 @@
|
||||
<tr>
|
||||
<th>No</th>
|
||||
<th>ID Lelong</th>
|
||||
<th>Cawangan</th>
|
||||
{{-- <th>Cawangan</th> --}}
|
||||
<th>Tarikh Lelong</th>
|
||||
<th>Fasa</th>
|
||||
<th>Harga Emas Asas</th>
|
||||
<th>Tempoh</th>
|
||||
<th>Caj Lelong</th>
|
||||
@@ -35,17 +36,18 @@
|
||||
<tr>
|
||||
<td>{{$loop->iteration}}</td>
|
||||
<td>{{ $lel['info']['lelong_id'] }}</td>
|
||||
<td align = 'left'>
|
||||
{{-- <td align = 'left'>
|
||||
@foreach($lel['detailsinfo'] as $details)
|
||||
<span class="m-2">{{$details['caw_name']}}</span><br>
|
||||
@endforeach
|
||||
</td>
|
||||
</td> --}}
|
||||
<td> @php
|
||||
$myDateTime = DateTime::createFromFormat('Y-m-d', $lel['info']['tarikh_lelong']);
|
||||
$datez = $myDateTime->format('d-m-Y');
|
||||
echo($datez);
|
||||
|
||||
@endphp</td>
|
||||
<td>{{ $lel['info']['fasa'] }}</td>
|
||||
<td>{{ number_format($lel['info']['harga_emas_asas'], 2, '.', ',')}}</td>
|
||||
<td>{{ $lel['info']['jbg'] }}</td>
|
||||
<td>{{ $lel['info']['cajlelong'] }}</td>
|
||||
|
||||
Reference in New Issue
Block a user