217 lines
9.3 KiB
PHP
217 lines
9.3 KiB
PHP
<?php
|
|
|
|
use Illuminate\Support\Facades\Auth;
|
|
use Illuminate\Support\Facades\Route;
|
|
|
|
/*
|
|
|--------------------------------------------------------------------------
|
|
| 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::routes([
|
|
'reset' => false,
|
|
'verify' => false,
|
|
'register' => false
|
|
]);
|
|
|
|
Route::namespace('Bo')
|
|
->prefix('bo')
|
|
->name('bo.')
|
|
->middleware(['auth', 'is-admin'])
|
|
->group(function () {
|
|
// Tableau de bord
|
|
Route::get('/', 'DashboardController@index')->name('dashboard');
|
|
// Utilisateurs BO
|
|
Route::resource('users', 'UsersController');
|
|
// Type de viandes
|
|
Route::resource('meat-types', 'MeatTypesController');
|
|
// Moment consommation
|
|
Route::resource('consumption-times', 'ConsumptionTimesController');
|
|
// Pictogrammes
|
|
Route::resource('product-pictograms', 'ProductPictogramsController');
|
|
// Gammes
|
|
Route::resource('ranges', 'RangesController');
|
|
Route::get('/ranges/change-order/{id}/{action}', 'RangesController@changeOrder')->name('ranges.change-order');
|
|
// La marque
|
|
Route::resource('ads', 'AdsController');
|
|
// Sliders
|
|
Route::resource('home-slider-pictures', 'HomeSliderPicturesController');
|
|
Route::get('/home-slider-pictures/change-order/{id}/{action}', 'HomeSliderPicturesController@changeOrder')->name('home-slider-pictures.change-order');
|
|
Route::resource('news-slider-pictures', 'NewsSliderPicturesController');
|
|
Route::get('/news-slider-pictures/change-order/{id}/{action}', 'NewsSliderPicturesController@changeOrder')->name('news-slider-pictures.change-order');
|
|
Route::resource('product-slider-pictures', 'ProductSliderPicturesController');
|
|
Route::get('/product-slider-pictures/change-order/{id}/{action}', 'ProductSliderPicturesController@changeOrder')->name('product-slider-pictures.change-order');
|
|
Route::get('/recipes/highlights/choice', 'RecipesController@highlights')->name('recipes.highlights');
|
|
Route::put('/recipes/highlights/store', 'RecipesController@storeHighlights')->name('recipes.store-highlights');
|
|
// Recettes
|
|
Route::resource('recipes', 'RecipesController');
|
|
// Articles
|
|
Route::resource('articles', 'ArticlesController');
|
|
// QR codes
|
|
Route::resource('qr-codes', 'QrCodesController');
|
|
// FAQ
|
|
Route::resource('faq-themes', 'FaqThemesController');
|
|
Route::get('/faq-themes/change-order/{id}/{action}', 'FaqThemesController@changeOrder')->name('faq-themes.change-order');
|
|
Route::resource('faq-questions', 'FaqQuestionsController');
|
|
// Menus équilibrés
|
|
Route::resource('balanced-menus', 'BalancedMenusController');
|
|
// Oui c'est bon
|
|
Route::get('/ocb/content/{type}', 'ContentOCBController@index')->name('ocb.content');
|
|
Route::resource('ocb', 'ContentOCBController');
|
|
Route::get('/ocb/change-order/{id}/{type}/{action}', 'ContentOCBController@changeOrder')->name('ocb.change-order');
|
|
// Eleveurs
|
|
Route::get('/breeders/content/{type}', 'BreedersController@index')->name('breeders.content');
|
|
Route::resource('breeders', 'BreedersController');
|
|
// En ce moment
|
|
Route::resource('moments', 'MomentsController');
|
|
Route::get('/moments/change-star/{id}', 'MomentsController@setStar')->name('moments.change-star');
|
|
// Traçabilité
|
|
Route::put('/traceability/filters', 'TraceabilityController@filter')->name('traceability.filter');
|
|
Route::get('/traceability', 'TraceabilityController@index')->name('traceability.index');
|
|
// Réductions
|
|
Route::get('/reductions', 'ReductionsController@index')->name('reductions.index');
|
|
Route::post('/ajax/reductions/save', 'ReductionsController@saveDatas');
|
|
// Produits
|
|
Route::resource('products', 'ProductsController');
|
|
Route::get('/products/change-order/{id}/{action}', 'ProductsController@changeOrder')->name('products.change-order');
|
|
Route::get('/products/change-star/{id}', 'ProductsController@changeStar')->name('products.change-star');
|
|
// Forum
|
|
Route::get('/forum/themes', 'ForumController@index')->name('forum-themes');
|
|
Route::get('/forum/theme/{id?}', 'ForumController@manage')->name('manage-forum-themes');
|
|
Route::match(['post', 'put'], '/forum/theme/process/{id?}', 'ForumController@process')->name('process-forum-themes');
|
|
});
|
|
|
|
Route::get('/', 'HomeController@index')->name('home');
|
|
Route::get('/de-smaak-om-te-delen', function (){
|
|
die('home nl');
|
|
})->name('home-nl');
|
|
|
|
Route::post('/inscription', 'CustomerController@store')->name('inscription');
|
|
Route::post('/activer', 'CustomerController@activate')->name('activer');
|
|
Route::get('/connexion', 'CustomerController@authenticateForm')->name('form-connexion');
|
|
Route::post('/connexion', 'CustomerController@authenticate')->name('connexion');
|
|
Route::get('/deconnexion', 'CustomerController@logout')->name('deconnexion')->middleware('auth:customer');
|
|
Route::get('/reinitialiser-mdp', 'CustomerController@passwordReset')->name('reinit-mdp');
|
|
Route::post('/change-mdp/{token}', 'CustomerController@changePassword')->name('change-mdp');
|
|
|
|
Route::get('/contactez-nous', function (){
|
|
die('Nous contacter');
|
|
})->name('contact-us');
|
|
|
|
Route::get('/faq', function (){
|
|
die('FAQ');
|
|
})->name('faq');
|
|
|
|
Route::get('/reclamation-produit', function (){
|
|
die('reclamation-produit');
|
|
})->name('product-request');
|
|
|
|
Route::get('/mentions-legales', function (){
|
|
return view('front.legals');
|
|
})->name('legal-notice');
|
|
|
|
Route::prefix('/produits')
|
|
->name('products.')
|
|
->group(function() {
|
|
Route::get('/', 'ProductsController@index')->name('index');
|
|
Route::get('/gamme/{gammeSlug}', 'ProductsController@filter')->name('range');
|
|
Route::get('/type-viande/{slugTypeViande}', 'ProductsController@filter')->name('meat-type');
|
|
Route::get('/moment-conso/{slugMoment}', 'ProductsController@filter')->name('consumption-times');
|
|
Route::get('/departaimants', 'ProductsController@departaimants')->name('departaimants');
|
|
});
|
|
|
|
Route::get('/produit/{slug}', function() {
|
|
return view('front.products.product');
|
|
})->name('product');
|
|
|
|
Route::prefix('/cote-cuisine')
|
|
->name('kitchen-side.')
|
|
->group(function(){
|
|
Route::get('/', function (){
|
|
die('Côté cuisine');
|
|
})->name('index');
|
|
|
|
Route::get('/sante-et-nutrition', function (){
|
|
die('Côté cuisine sante-et-nutrition');
|
|
})->name('health-nutrition');
|
|
});
|
|
|
|
Route::get('/recettes', function (){
|
|
die('Recettes');
|
|
})->name('recipes');
|
|
|
|
Route::get('/recette/{slug}', function($slug) {
|
|
die("Recette " . $slug);
|
|
})->name('recipe');
|
|
|
|
Route::prefix('/la-marque')
|
|
->name('brand.')
|
|
->group(function(){
|
|
Route::get('/', function (){
|
|
die('La Marque');
|
|
})->name('index');
|
|
Route::get('/notre-histoire', function (){
|
|
die('La Marque notre histoire');
|
|
})->name('history');
|
|
Route::get('/saga-publicitaire', function (){
|
|
die('La Marque saga-publicitaire');
|
|
})->name('pub');
|
|
Route::get('/volailles-francaises', function (){
|
|
die('La Marque volailles-francaises');
|
|
})->name('french-poultry');
|
|
Route::get('/nos-engagements-qualite', function (){
|
|
die('Nnos-engagements-qualite');
|
|
})->name('our-quality-commitments');
|
|
Route::get('/tracabilite', function (){
|
|
return view('front.traceability');
|
|
})->name('traceability');
|
|
Route::get('/tracabilite/search', 'TraceabilityController@search')->name('traceability-search');
|
|
});
|
|
|
|
Route::prefix('/oui-cest-bon')
|
|
->name('ocb.')
|
|
->group(function(){
|
|
Route::get('/', function (){
|
|
return view('front.ocb.index');
|
|
})->name('index');
|
|
Route::get('/volaille', 'OCBController@poultry')->name('poultry');
|
|
Route::get('/oeuf', function() {
|
|
return view('front.ocb.egg');
|
|
})->name('egg');
|
|
// TODO : Voir si on garde ce format avec ID
|
|
Route::get('/eleveurs/{slug}', 'OCBController@breeder')->name('breeders');
|
|
});
|
|
|
|
Route::get('/en-ce-moment/{slug}', 'MomentsController@index')->name('moment');
|
|
|
|
Route::prefix('/le-club-des-gaulois')
|
|
->name('club.')
|
|
->group(function(){
|
|
Route::get('/', function (){
|
|
die('le-club-des-gaulois');
|
|
})->name('index');
|
|
Route::get('/les-infos-du-club', function (){
|
|
die('Les infos du club');
|
|
})->name('infos');
|
|
Route::get('/les-infos-du-club/{slug}', function (){
|
|
die('Les infos du club enfant');
|
|
})->name('infos.child');
|
|
Route::get('/les-departaimants', function() {
|
|
die('Les départaimants');
|
|
})->name('departaimants');
|
|
Route::get('/les-infos-du-club/categorie/astuces', function () {
|
|
die('Les astuces le gaulois');
|
|
})->name('tips');
|
|
Route::get('/les-promos', function() {
|
|
die('Les promos');
|
|
})->name('reductions');
|
|
});
|
|
|
|
Auth::routes();
|
|
|
|
Route::get('/home', 'HomeController@index')->name('home');
|