Initial Commit
The initial public commit of MVGL website code.
This commit is contained in:
commit
b39ecf1638
2043 changed files with 215154 additions and 0 deletions
21
routes/api.php
Normal file
21
routes/api.php
Normal file
|
@ -0,0 +1,21 @@
|
|||
<?php
|
||||
|
||||
use App\Http\Controllers\Auth\AuthenticatedSessionController;
|
||||
use App\Http\Controllers\Auth\PasswordResetLinkController;
|
||||
use App\Http\Controllers\Auth\RegisteredUserController;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| API Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here is where you can register API routes for your application. These
|
||||
| routes are loaded by the RouteServiceProvider within a group which
|
||||
| is assigned the "api" middleware group. Enjoy building your API!
|
||||
|
|
||||
*/
|
||||
|
||||
/*Route::middleware('auth:api')->get('/user', function (Request $request) {
|
||||
return $request->user();
|
||||
});*/
|
64
routes/auth.php
Normal file
64
routes/auth.php
Normal file
|
@ -0,0 +1,64 @@
|
|||
<?php
|
||||
|
||||
use App\Http\Controllers\Auth\AuthenticatedSessionController;
|
||||
use App\Http\Controllers\Auth\ConfirmablePasswordController;
|
||||
use App\Http\Controllers\Auth\EmailVerificationNotificationController;
|
||||
use App\Http\Controllers\Auth\EmailVerificationPromptController;
|
||||
use App\Http\Controllers\Auth\NewPasswordController;
|
||||
use App\Http\Controllers\Auth\PasswordResetLinkController;
|
||||
use App\Http\Controllers\Auth\RegisteredUserController;
|
||||
use App\Http\Controllers\Auth\VerifyEmailController;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
Route::get('/register', [RegisteredUserController::class, 'create'])
|
||||
->middleware('guest')
|
||||
->name('register');
|
||||
|
||||
Route::post('/register', [RegisteredUserController::class, 'store'])
|
||||
->middleware('guest');
|
||||
|
||||
Route::get('/login', [AuthenticatedSessionController::class, 'create'])
|
||||
->middleware('guest')
|
||||
->name('login');
|
||||
|
||||
Route::post('/login', [AuthenticatedSessionController::class, 'store'])
|
||||
->middleware('guest');
|
||||
|
||||
Route::get('/forgot-password', [PasswordResetLinkController::class, 'create'])
|
||||
->middleware('guest')
|
||||
->name('password.request');
|
||||
|
||||
Route::post('/forgot-password', [PasswordResetLinkController::class, 'store'])
|
||||
->middleware('guest')
|
||||
->name('password.email');
|
||||
|
||||
Route::get('/reset-password/{token}', [NewPasswordController::class, 'create'])
|
||||
->middleware('guest')
|
||||
->name('password.reset');
|
||||
|
||||
Route::post('/reset-password', [NewPasswordController::class, 'store'])
|
||||
->middleware('guest')
|
||||
->name('password.update');
|
||||
|
||||
Route::get('/verify-email', [EmailVerificationPromptController::class, '__invoke'])
|
||||
->middleware('auth')
|
||||
->name('verification.notice');
|
||||
|
||||
Route::get('/verify-email/{id}/{hash}', [VerifyEmailController::class, '__invoke'])
|
||||
->middleware(['auth', 'signed', 'throttle:6,1'])
|
||||
->name('verification.verify');
|
||||
|
||||
Route::post('/email/verification-notification', [EmailVerificationNotificationController::class, 'store'])
|
||||
->middleware(['auth', 'throttle:6,1'])
|
||||
->name('verification.send');
|
||||
|
||||
Route::get('/confirm-password', [ConfirmablePasswordController::class, 'show'])
|
||||
->middleware('auth')
|
||||
->name('password.confirm');
|
||||
|
||||
Route::post('/confirm-password', [ConfirmablePasswordController::class, 'store'])
|
||||
->middleware('auth');
|
||||
|
||||
Route::post('/logout', [AuthenticatedSessionController::class, 'destroy'])
|
||||
->middleware('auth')
|
||||
->name('logout');
|
18
routes/channels.php
Normal file
18
routes/channels.php
Normal file
|
@ -0,0 +1,18 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Broadcast;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Broadcast Channels
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may register all of the event broadcasting channels that your
|
||||
| application supports. The given channel authorization callbacks are
|
||||
| used to check if an authenticated user can listen to the channel.
|
||||
|
|
||||
*/
|
||||
|
||||
Broadcast::channel('App.Models.User.{id}', function ($user, $id) {
|
||||
return (int) $user->id === (int) $id;
|
||||
});
|
19
routes/console.php
Normal file
19
routes/console.php
Normal file
|
@ -0,0 +1,19 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Foundation\Inspiring;
|
||||
use Illuminate\Support\Facades\Artisan;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Console Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This file is where you may define all of your Closure based console
|
||||
| commands. Each Closure is bound to a command instance allowing a
|
||||
| simple approach to interacting with each command's IO methods.
|
||||
|
|
||||
*/
|
||||
|
||||
Artisan::command('inspire', function () {
|
||||
$this->comment(Inspiring::quote());
|
||||
})->purpose('Display an inspiring quote');
|
199
routes/web.php
Normal file
199
routes/web.php
Normal file
|
@ -0,0 +1,199 @@
|
|||
<?php
|
||||
|
||||
use App\Http\Controllers\Account\SettingsController;
|
||||
use App\Http\Controllers\GameController;
|
||||
use App\Http\Controllers\GameListController;
|
||||
use App\Http\Controllers\GameSearchController;
|
||||
// use App\Http\Controllers\GameReviewController;
|
||||
// use App\Http\Controllers\PagesController;
|
||||
use App\Http\Controllers\PlatformController;
|
||||
use App\Http\Controllers\UserController;
|
||||
use App\Http\Controllers\WishlistController;
|
||||
use App\Models\Game;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
// Include our authentication routes.
|
||||
require __DIR__ . '/auth.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!
|
||||
|
|
||||
*/
|
||||
|
||||
Route::get('/', function () {
|
||||
return view('pages.index');
|
||||
})->name('index');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Account Settings Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(SettingsController::class)->group(function () {
|
||||
Route::middleware(['auth', 'verified'])->group(function () {
|
||||
Route::prefix('account')->group(function () {
|
||||
Route::get('settings', 'index')->name('settings.index');
|
||||
Route::put('settings', 'update')->name('settings.update');
|
||||
Route::put('settings/email', 'changeEmail')->name('settings.changeEmail');
|
||||
Route::put('settings/password', 'changePassword')->name('settings.changePassword');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Game Profile Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(GameController::class)->group(function () {
|
||||
Route::middleware(['auth', 'verified'])->group(function () {
|
||||
Route::get('/admin/games', 'index')->name('admin.games.index');
|
||||
Route::get('/admin/game/create', 'create')->name('admin.game.create');
|
||||
Route::get('/admin/game/clone/{gameId}', 'clone')->name('admin.game.clone');
|
||||
Route::post('/admin/game/create', 'store')->name('admin.game.store');
|
||||
Route::get('/admin/game/{game}/edit', 'edit')->name('admin.game.edit');
|
||||
Route::put('/admin/game/{game}', 'update')->name('admin.game.update');
|
||||
Route::delete('/admin/game/{game}', 'destroy')->name('admin.game.destroy');
|
||||
});
|
||||
Route::get('/game/{gameId}', function ($gameId) {
|
||||
$gameName = str_replace('/', '_', str_replace(' ', '_', Game::findOrFail($gameId)->name));
|
||||
return redirect()->route('game.show', ['gameId' => $gameId, 'gameName' => $gameName]);
|
||||
})->whereNumber('gameId')->name('game.redirect.show');
|
||||
Route::get('/game/{gameId}/{gameName}', 'show')->name('game.show');
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Game List Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(GameListController::class)->group(function () {
|
||||
Route::middleware(['auth', 'verified'])->group(function () {
|
||||
Route::get('/list', 'index')->name('games.list.index');
|
||||
Route::get('/list/create/{gameId}', 'create')->name('games.list.create');
|
||||
Route::post('/list/create', 'store')->name('games.list.store');
|
||||
Route::get('/list/edit/{gameList}', 'edit')->name('games.list.edit');
|
||||
Route::put('/list/{gameList}', 'update')->name('games.list.update');
|
||||
Route::delete('/list/{gameList}', 'destroy')->name('games.list.destroy');
|
||||
});
|
||||
Route::get('/list/{user}', 'index')->name('games.list.user.index');
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Game Reviews Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
// Route::controller(GameReviewController::class)->group(function () {
|
||||
// Route::get('/game-reviews', 'index')->name('game-reviews.index');
|
||||
// });
|
||||
Route::get('/game-reviews', function () {
|
||||
return view('pages.game-reviews.index');
|
||||
})->name('game-reviews.index');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Game Search Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(GameSearchController::class)->group(function () {
|
||||
Route::paginate('/search/games', 'search')->name('game.search');
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Misc Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::get('/contact-us', function () {
|
||||
return view('pages.contact-us.index');
|
||||
})->name('contact-us.index');
|
||||
|
||||
Route::get('/newly-added-games', function () {
|
||||
return view('pages.misc.newly-added-games');
|
||||
})->name('misc.newly-added-games');
|
||||
|
||||
Route::get('/privacy-policy', function () {
|
||||
return view('pages.privacy-policy.index');
|
||||
})->name('privacy-policy');
|
||||
|
||||
Route::get('/recent-gamer-updates', function () {
|
||||
return view('pages.misc.recent-gamer-updates');
|
||||
})->name('misc.recent-gamer-updates');
|
||||
|
||||
Route::get('/terms-of-service', function () {
|
||||
return view('pages.terms-of-service.index');
|
||||
})->name('terms-of-service');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Platform Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(PlatformController::class)->group(function () {
|
||||
Route::get('/platforms', 'index')->name('platforms.index');
|
||||
Route::paginate('/platform/{platform}', 'show')->name('platform.show');
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Profile Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(UserController::class)->group(function () {
|
||||
Route::middleware(['auth', 'verified'])->group(function () {
|
||||
Route::get('/profile', 'show')->name('profile.show');
|
||||
});
|
||||
Route::get('/profile/{user}', 'show')->name('profile.user.show');
|
||||
});
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Support Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::get('/support', function () {
|
||||
return view('pages.support.index');
|
||||
})->name('support.index');
|
||||
|
||||
Route::get('/support/knowledgebase', function () {
|
||||
return view('pages.support.knowledgebase.index');
|
||||
})->name('support.knowledgebase.index');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Wishlist Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
*/
|
||||
|
||||
Route::controller(WishlistController::class)->group(function () {
|
||||
Route::middleware(['auth', 'verified'])->group(function () {
|
||||
Route::get('/wishlist', 'show')->name('wishlist.show');
|
||||
});
|
||||
Route::get('/wishlist/{user}', 'show')->name('wishlist.user.show');
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue