<?php

namespace App\Http\Controllers\Configuration;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use App\Models\File;
use App\Http\Controllers\Utils\PaginatorController;

// use App\Http\Controllers\Storage;

class ExchangeRateController extends Controller
{
    
    public function mainlistExchangeRate(){
        $exchangerate = PaginatorController::paginate( config('masterfile.getExchangeRate'), 2 );
        $exchangerate->withPath('/configurations/exchange-rate');
        // var_dump(config('masterfile.PreStatus'));exit;
        // dd($exchangerate);
        $url = '/configurations/exchange-rate';
        return view('configurations/exchange-rates/exchange-rate')
        ->with('dataExchangeRate',config('masterfile.getExchangeRate'))
        ->with('exchangerate',$exchangerate)
        ->with('url',$url);
    }
    public function mainlistCurrency(){
        // var_dump(config('masterfile.PreStatus'));exit;
        $currencyCode  = PaginatorController::paginate( config('masterfile.getCurrency'), 2 );
        $currencyCode->withPath('/configurations/currency-code');

        $url = '/configurations/currency-code';
        return view('configurations/currency-codes/currency-code')
        ->with('dataCurrency',config('masterfile.getCurrency'))
        ->with('currencyCode',$currencyCode)
        ->with('url',$url);
    }

}
