2020-02-26 13:59:58 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| Web Routes
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
| Here is where you can register web routes for your application. These
|
|
|
|
| routes are loaded by the RouteServiceProvider within a group which
|
|
|
|
| contains the "web" middleware group. Now create something great!
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
//AUTH
|
2020-02-26 23:42:36 +00:00
|
|
|
use Illuminate\Support\Facades\DB;
|
|
|
|
|
2020-02-26 13:59:58 +00:00
|
|
|
Auth::routes([
|
|
|
|
'verify' => true,
|
|
|
|
'register' => true
|
|
|
|
]);
|
|
|
|
|
|
|
|
Route::namespace('Panel')->prefix('panel')->group(function () {
|
|
|
|
//Dashboard
|
|
|
|
Route::get('/home', 'HomeController@index')->name('panel.home');
|
|
|
|
|
|
|
|
//UMS
|
2021-06-27 19:01:43 +00:00
|
|
|
Route::prefix('ums')->group(function () {
|
2020-02-26 13:59:58 +00:00
|
|
|
Route::get('/{page?}/{search?}', 'UMSController@index')->where('page', '[0-9]+')->name('panel.ums');
|
|
|
|
Route::get('/info/{id}', 'UMSController@info')->where('id', '[0-9]+')->name('panel.ums.info');
|
2021-06-27 19:01:43 +00:00
|
|
|
Route::get('/edit/{id}', 'UMSController@edit')->where('id', '[0-9]+')->name('panel.ums.edit');
|
|
|
|
Route::post('/update', 'UMSController@update')->name('panel.ums.update');
|
2020-02-26 13:59:58 +00:00
|
|
|
Route::get('/delete/{id}', 'UMSController@delete')->where('id', '[0-9]+')->name('panel.ums.delete');
|
|
|
|
});
|
2021-06-27 19:01:43 +00:00
|
|
|
|
|
|
|
//Dashboard
|
|
|
|
Route::get('/message', 'MessageController@index')->name('panel.message');
|
|
|
|
Route::post('/message', 'MessageController@change');
|
|
|
|
|
|
|
|
//Shows
|
|
|
|
Route::prefix('show')->group(function () {
|
|
|
|
Route::get('/{page?}/{search?}', 'ShowController@index')->where('page', '[0-9]+')->name('panel.show');
|
|
|
|
Route::get('/add', 'ShowController@add')->name('panel.show.add');
|
|
|
|
Route::post('/create', 'ShowController@create')->name('panel.show.create');
|
|
|
|
Route::get('/info/{id}', 'ShowController@info')->where('id', '[0-9]+')->name('panel.show.info');
|
|
|
|
Route::get('/edit/{id}', 'ShowController@edit')->where('id', '[0-9]+')->name('panel.show.edit');
|
|
|
|
Route::post('/update', 'ShowController@update')->name('panel.show.update');
|
|
|
|
Route::get('/delete/{id}', 'ShowController@delete')->where('id', '[0-9]+')->name('panel.show.delete');
|
|
|
|
});
|
|
|
|
|
|
|
|
Route::prefix('shows')->group(function () {
|
|
|
|
Route::get('/{page?}/{search?}', 'ShowsController@index')->where('page', '[0-9]+')->name('panel.shows');
|
|
|
|
Route::get('/add', 'ShowsController@add')->name('panel.shows.add');
|
|
|
|
Route::post('/search', 'ShowsController@search')->name('panel.shows.search');
|
|
|
|
Route::post('/create', 'ShowsController@create')->name('panel.shows.create');
|
|
|
|
Route::get('/info/{id}', 'ShowsController@info')->where('id', '[0-9]+')->name('panel.shows.info');
|
|
|
|
Route::get('/delete/{id}', 'ShowsController@delete')->where('id', '[0-9]+')->name('panel.shows.delete');
|
|
|
|
});
|
|
|
|
|
2020-02-26 13:59:58 +00:00
|
|
|
});
|
|
|
|
|
|
|
|
//Home
|
|
|
|
Route::get('/home', 'HomeController@index')->name('home');
|
|
|
|
Route::get('/', 'HomeController@index');
|
|
|
|
|
2020-02-26 23:42:36 +00:00
|
|
|
//Status and Ridecount
|
|
|
|
Route::get('/status', 'HomeController@status')->name('status');
|
|
|
|
Route::get('/ridecount/{attraction_id}', 'RidecountController@index')->name('ridecount');
|
|
|
|
|
|
|
|
//Shows
|
|
|
|
Route::get('/shows', 'ShowController@index')->name('shows');
|
|
|
|
Route::get('/order/{show_id}', 'ShowController@order')->name('order');
|
|
|
|
Route::post('/order/make', 'ShowController@makeOrder')->name('makeOrder');
|
|
|
|
|
2021-06-27 19:01:43 +00:00
|
|
|
//Store
|
|
|
|
Route::get('/store', 'HomeController@store')->name('store');
|
|
|
|
|
2020-02-26 23:42:36 +00:00
|
|
|
|
2021-06-27 19:01:43 +00:00
|
|
|
if(DB::getSchemaBuilder()->hasTable('actionfotos'))
|
2020-02-26 23:42:36 +00:00
|
|
|
Route::get('/photo', 'HomeController@photo')->name('photo');
|
|
|
|
|
2021-06-27 19:01:43 +00:00
|
|
|
Route::get('/openaudiomc', 'OpenAudioMCController@index')->name('openaudiomc');
|
|
|
|
|
2020-02-26 13:59:58 +00:00
|
|
|
//Logout Route
|
|
|
|
Route::get('/logout', '\App\Http\Controllers\Auth\LoginController@logout');
|
|
|
|
|
|
|
|
//2FA Authentication
|
|
|
|
Route::prefix('2fa')->group(function () {
|
|
|
|
Route::get('/authenticate', 'TwoFactorController@index')->name('2fa.authenticate');
|
|
|
|
Route::post('/authenticate', 'TwoFactorController@authenticate');
|
|
|
|
Route::post('/toggle', 'ToggleTwoFactorController@toggle')->name('2fa.toggle');
|
|
|
|
});
|
|
|
|
|
2020-02-26 23:42:36 +00:00
|
|
|
//Profile
|
|
|
|
Route::namespace('Profile')->prefix('profile')->group(function() {
|
|
|
|
//User Profile/Security
|
|
|
|
Route::get('/home', 'HomeController@index')->name('profile.home');
|
|
|
|
Route::get('/security/{page?}', 'SecurityController@index')->where('page', '^[1-9]\d*$')->name('security');
|
|
|
|
Route::get('/session/{id}', 'SecurityController@session')->name('session.delete');
|
|
|
|
|
|
|
|
//Change
|
|
|
|
Route::prefix('change')->group(function () {
|
|
|
|
Route::get('/', 'ChangeController@index')->name('change');
|
|
|
|
Route::post('/password', 'ChangeController@changePassword')->name('change.password');
|
|
|
|
Route::post('/email', 'ChangeController@changeEmail')->name('change.email');
|
2021-06-27 19:01:43 +00:00
|
|
|
Route::get('/email/{id}/{token}/{email}', 'ChangeController@verifyEmail')->name('verify_email');
|
2020-02-26 23:42:36 +00:00
|
|
|
});
|
2020-02-26 13:59:58 +00:00
|
|
|
});
|
2021-06-27 19:01:43 +00:00
|
|
|
|
|
|
|
Route::get('/control/{attraction_id}/{pin}', 'ControlController@index');
|