middleware('auth'); } public function index($norujukan){ $auth_user = Auth::user(); $api_url = config('api.url'); $cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json(); $gadaidetail = Http::get(config('api.url') . '/api/gadai/norujukan/'. $norujukan)->json(); $noic = $gadaidetail[0][0]['nokp']; $customerdetail = Http::get(config('api.url') . '/api/customers/'. $noic)->json(); $marhundetail = Http::get(config('api.url') . '/api/marhun/'. $norujukan)->json(); // dd($marhundetail[0]); $marhun = $marhundetail[0]; $nama = $customerdetail[0]['nama']; $gadai = $gadaidetail[0][0]; return view('penebusan.index',compact('cawangan_info','api_url','gadai','marhun','nama')); } }