ok
Direktori : /home2/selectio/public_html/bharath/a1tex.in/app/Http/Controllers/Web/ |
Current File : /home2/selectio/public_html/bharath/a1tex.in/app/Http/Controllers/Web/CurrencyController.php |
<?php namespace App\Http\Controllers\Web; use App\Http\Controllers\Controller; use App\Model\Currency; use Illuminate\Http\Request; class CurrencyController extends Controller { public function changeCurrency(Request $request) { session()->put('currency_code', $request->currency_code); $currency = Currency::where('code', $request->currency_code)->first(); session()->put('currency_symbol', $currency->symbol); session()->put('currency_exchange_rate', $currency->exchange_rate); return response()->json($currency); } }