fix audit
This commit is contained in:
@@ -801,4 +801,33 @@ class AkaunController extends Controller
|
||||
|
||||
return view('audit.index');
|
||||
}
|
||||
|
||||
public function CetakSenarai(Request $request)
|
||||
{
|
||||
|
||||
$tarikhasal = $request->mula;
|
||||
$jenistebus = $request->jenis;
|
||||
|
||||
$tarikh = explode("-",$request->mula);
|
||||
|
||||
$month = $tarikh[0];
|
||||
$year = $tarikh[1];
|
||||
|
||||
$laporan = Http::get(config('api.url').'/admin/audit/keuntungansebenar',[
|
||||
'kodcaw' => $request->kodcaw,
|
||||
'year' => $year,
|
||||
'month' => $month,
|
||||
'jenistebus' => $request->jenis,
|
||||
])->json();
|
||||
|
||||
$cawangan=Http::get(config('api.url').'/api/cawangan/detail/'. $request->kodcaw)->json();
|
||||
$cawangan_detail=$cawangan[0];
|
||||
|
||||
if($jenistebus == 'L')
|
||||
{
|
||||
return view('audit.cetakanexcelelong', compact('laporan','cawangan_detail','tarikhasal','jenistebus'));
|
||||
}else{
|
||||
return view('audit.cetakanexcel', compact('laporan','cawangan_detail','tarikhasal','jenistebus'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user