<?php



use Illuminate\Support\Facades\Route;
use \App\Http\Controllers\gencbeyin;
use \App\Http\Controllers\yonetici;
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Redirect;


$domain=request()->getHost();
$domain=str_replace('www.','',$domain);
$key=md5("frejmf".$domain."dfgggg");
if ($key!=env('key')) {


    die("lisans hatası");
}


/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider and all of them will
| be assigned to the "web" middleware group. Make something great!
|
*/


Route::get('/',[gencbeyin::class,'main']);
Route::post('/',[gencbeyin::class,'transferara']);
Route::post('/hesapla',[gencbeyin::class,'transferara']);
Route::get('/demo',[gencbeyin::class,'demo']);
Route::get('/demoadmin',[gencbeyin::class,'demoadmin']);

Route::get('/uye-ol',[gencbeyin::class,'uyeol']);
Route::post('/uye-ol',[gencbeyin::class,'uyeolup']);
Route::get('/index.html',function (){ return redirect('/');});
Route::get('/logout',[gencbeyin::class,'logout']);
Route::get('/login',[gencbeyin::class,'login'])->name('login');
Route::get('/giris-yap',[gencbeyin::class,'login'])->name('login');
Route::get('/sifremi-unuttum',[gencbeyin::class,'sifremiunuttum']);
Route::post('/sifremi-unuttum',[gencbeyin::class,'sifresifirla']);
Route::get('/sifresifirla',[gencbeyin::class,'resetmail']);
Route::post('/login',[gencbeyin::class,'loginup'])->name('loginup');
Route::post('/profilduzenle',[gencbeyin::class,'profilduzenle'])->middleware('auth');

Route::get('/panel',[gencbeyin::class,'panel']);
Route::get('/panel/{alt}',[gencbeyin::class,'panel']);


Route::get('/rent-a-car',[gencbeyin::class,'araclar']);
Route::get('/rezervasyon',[gencbeyin::class,'rezervasyon'])->middleware('auth');
Route::get('/blog',[gencbeyin::class,'blog']);
Route::get('/iletisim',[gencbeyin::class,'iletisim']);
Route::get('/transfer',[gencbeyin::class,'transfer']);
Route::get('/transfer-sorgula',[gencbeyin::class,'transfersorgula']);
Route::get('/arac-kirala',[gencbeyin::class,'arackirala']);
Route::post('/arac-kirala',[gencbeyin::class,'arackiralahesapla']);
Route::post('/send',[gencbeyin::class,'send']);
Route::post('/paytr',[gencbeyin::class,'paytr'])->middleware('auth');
Route::get('/paytr',[gencbeyin::class,'paytr'])->middleware('auth');
Route::get('/payment-ok',[gencbeyin::class,'paymentok']);
Route::get('/odemebildir',[gencbeyin::class,'odemebildir']);
Route::get('/kira-rezervasyon',[gencbeyin::class,'kirarezervasyon']);
Route::get('/turlar',[gencbeyin::class,'turlar']);
Route::get('/turlar/{kat?}',[gencbeyin::class,'turlar']);
Route::get('/tur/{turslug?}',[gencbeyin::class,'tur']);
Route::get('/kur',[gencbeyin::class,'kur']);
Route::get('/parabirimi',[gencbeyin::class,'parabirimi']);
Route::post('/parabirimi',[gencbeyin::class,'parabirimiup']);
Route::post('/tur-kayit',[gencbeyin::class,'turkayit'])->middleware('auth');


//Yönetici Paneli

Route::get('/admin',[yonetici::class,'admin']);
Route::get('/admin/musteriler',[yonetici::class,'musteriler']);
Route::get('/admin/transfer-talepleri',[yonetici::class,'transfertalepleri']);
Route::get('/admin/kiralama-talepleri',[yonetici::class,'kiralamatalepleri']);
Route::post('/admin/transferaracekle',[yonetici::class,'taracekle']);
Route::post('/admin/kiralikaracekle',[yonetici::class,'karacekle']);
Route::get('/admin/transfer-araclari',[yonetici::class,'transferaraclari']);
Route::get('/admin/kiralik-araclar',[yonetici::class,'kiralikaraclar']);
Route::get('/admin/taracsil',[yonetici::class,'taracsil']);
Route::get('/admin/karacsil',[yonetici::class,'karacsil']);
Route::get('/admin/taracduzenle',[yonetici::class,'taracduzenle']);
Route::post('/admin/taracduzenle',[yonetici::class,'taracduzenleup']);
Route::get('/admin/musteriduzenle',[yonetici::class,'musteriduzenle']);
Route::post('/admin/musteriduzenle',[yonetici::class,'musteriduzenleup']);
Route::get('/admin/adminduzenle',[yonetici::class,'adminduzenle']);
Route::post('/admin/adminduzenle',[yonetici::class,'adminduzenleup']);
Route::post('/admin/adminekle',[yonetici::class,'adminekleup']);
Route::get('/admin/adminsil',[yonetici::class,'adminsilup']);
Route::get('/admin/musterisil',[yonetici::class,'musterisil']);
Route::get('/admin/musteridurum',[yonetici::class,'musteridurum']);
Route::get('/admin/ayarlar',[yonetici::class,'ayarlar']);
Route::post('/admin/ayarlar',[yonetici::class,'ayarlarup']);
Route::get('/admin/hesap-numaralari',[yonetici::class,'hesapnumaralari']);
Route::get('/admin/blog',[yonetici::class,'blog']);
Route::get('/admin/is-emri',[yonetici::class,'isemri']);
Route::get('/admin/admins',[yonetici::class,'admins']);
Route::get('/admin/kasa/{mod}',[yonetici::class,'kasa']);
Route::get('/admin/ttalepsil',[yonetici::class,'ttalepsil']);
Route::get('/admin/ktalepsil',[yonetici::class,'ktalepsil']);
Route::get('/admin/turlar',[yonetici::class,'turlar']);
Route::post('/admin/turekle',[yonetici::class,'turekle']);
Route::get('/admin/tursil',[yonetici::class,'tursil']);
Route::get('/admin/turduzenle',[yonetici::class,'turduzenle']);
Route::post('/admin/turduzenle',[yonetici::class,'turduzenleup']);
Route::get('/admin/tur-kategorileri',[yonetici::class,'turkategorileri']);
Route::get('/admin/tur-talepleri',[yonetici::class,'turtalepleri']);
Route::get('/admin/turtalepiptal',[yonetici::class,'turtalepiptal']);
Route::get('/admin/ek-hizmetler',[yonetici::class,'ekhizmet']);
Route::post('/admin/hizmetekle',[yonetici::class,'hizmetekle']);
Route::get('/admin/ekhizmetsil',[yonetici::class,'ekhizmetsil']);
Route::get('/admin/hesapnosil',[yonetici::class,'hesapnosil']);
Route::post('/admin/hesapnoekle',[yonetici::class,'hesapnoekle']);




Route::get('/backup',[gencbeyin::class,'backup']);
Route::get('/yedekle',[gencbeyin::class,'yedekle']);
Route::get('/ac',[gencbeyin::class,'ac']);
Route::get('/restore',[gencbeyin::class,'restore']);
Route::get('/cc', function () {
    // Önbelleği temizle
    Artisan::call('cache:clear');

    // Gerekirse önbellek dosyalarını da sil
    Artisan::call('config:clear');
    Artisan::call('route:clear');
    Artisan::call('view:clear');

    echo "Temizlendi";
});

Route::get('/sef',[gencbeyin::class,'sef']);



Route::get('/basin-kiti',[gencbeyin::class,'basinkiti']);
Route::get('/map',[gencbeyin::class,'map']);
Route::get('/kvkk',[gencbeyin::class,'kvkk']);
Route::get('/havale',[gencbeyin::class,'havale']);
Route::get('/sofor',[gencbeyin::class,'sofor']);
Route::get('/gizlilik-guvenlik',[gencbeyin::class,'gizlilik']);
Route::get('/kullanim-sozlesmesi',[gencbeyin::class,'sozlesme']);
Route::get('/{blogyazi}',[gencbeyin::class,'blogyazi']);
