Merge branch 'develop' into trunk
This commit is contained in:
commit
730dabdcab
46 changed files with 648 additions and 31331 deletions
|
|
@ -151,10 +151,17 @@ class CustomerController extends Controller
|
|||
/** @var Customers|null */
|
||||
$customer = Customers::where('email', $request->email)->first();
|
||||
|
||||
if ($customer && $customer->isNoLongerEmployed()) {
|
||||
$customer->remember_token = null;
|
||||
$customer->saveOrFail();
|
||||
return back()->withErrors(
|
||||
'Compte bloqué. Veuillez contacter votre RH ou le standard St Laurent au 02 43 62 70 00'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
/** @var \LDC\LDCCRM\CrmApiV2 */
|
||||
$crm = app('crmAPI');
|
||||
|
||||
// * Ne devrait pas survenir, $crm->login throws ApiError::authFailed()
|
||||
if (!$crm->login($request->email, $request->password)) {
|
||||
// * mauvais identifiants
|
||||
|
|
@ -275,7 +282,7 @@ class CustomerController extends Controller
|
|||
Mail::to($email)->send(new PasswordResetMail($token));
|
||||
return back()->with(
|
||||
'success',
|
||||
__("La procédure pour changer votre mot de passe a été envoyé sur votre email.")
|
||||
__("La procédure pour changer votre mot de passe a été envoyée sur votre email.")
|
||||
);
|
||||
} else {
|
||||
return back()->withErrors(__("Cette adresse email n'est pas enregistrée dans nos services."));
|
||||
|
|
|
|||
|
|
@ -7,11 +7,6 @@ use App\Models\Product;
|
|||
use App\Models\Slider;
|
||||
use App\Models\Range;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\Validator;
|
||||
use LDC\LDCCRM\Enums\ApiError;
|
||||
use LDC\LDCCRM\Exceptions\ApiErrorException;
|
||||
use LDC\LDCCRM\Exceptions\CrmException;
|
||||
use LDC\LDCCRM\Models\SingleOptin;
|
||||
|
||||
class HomeController extends Controller
|
||||
{
|
||||
|
|
@ -42,35 +37,4 @@ class HomeController extends Controller
|
|||
|
||||
return view('home', compact('content', 'products', 'slides', 'quickorder_ranges'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the CRM to add a single optin
|
||||
*
|
||||
* @param Request $request
|
||||
* @return \Illuminate\Contracts\View\View
|
||||
*
|
||||
*/
|
||||
public function addOptIn(Request $request)
|
||||
{
|
||||
$validator = Validator::make($request->all(), ['email' => 'required|email']);
|
||||
if ($validator->fails()) {
|
||||
return __('L\'adresse email est incorrecte');
|
||||
}
|
||||
|
||||
try {
|
||||
SingleOptin::setStatus($request->email, true);
|
||||
return trans('Votre inscription à la newsletter a été prise en compte');
|
||||
} catch (ApiErrorException $e) {
|
||||
// * Il y a deja un customerInfo avec optin a true pour ce customer
|
||||
if ($e->getApiError()->equals(ApiError::singleOptinCustomerExists())) {
|
||||
return trans('Vous êtes déjà inscrit avec cette adresse email');
|
||||
}
|
||||
report($e);
|
||||
return trans('Une erreur est survenue, merci de réessayer ultérieurement');
|
||||
} catch (CrmException $e) {
|
||||
report($e);
|
||||
return trans('Une erreur est survenue, merci de réessayer ultérieurement');
|
||||
}
|
||||
return trans('Une erreur est survenue, merci de réessayer ultérieurement ');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,6 +30,13 @@ class OrderTunnelController extends Controller
|
|||
*/
|
||||
public function recapOrder()
|
||||
{
|
||||
if (auth()->user()->isNoLongerEmployed()) {
|
||||
auth()->logout();
|
||||
return redirect()->route('auth.connexion')->withErrors(
|
||||
'Compte bloqué. Veuillez contacter votre RH ou le standard St Laurent au 02 43 62 70 00'
|
||||
);
|
||||
}
|
||||
|
||||
$activestep = 1;
|
||||
Cart::instance('panier');
|
||||
$cart = Cart::content();
|
||||
|
|
|
|||
|
|
@ -11,31 +11,6 @@ use Illuminate\Http\Request;
|
|||
|
||||
class ProductsController extends Controller
|
||||
{
|
||||
/**
|
||||
* One Range page
|
||||
*
|
||||
* @param Request $request
|
||||
* @param string $range_slug
|
||||
* @return \Illuminate\Contracts\View\View
|
||||
*
|
||||
* @phpcs:disable Generic.CodeAnalysis.UnusedFunctionParameter.FoundInExtendedClassBeforeLastUsed
|
||||
*/
|
||||
public function range(Request $request, string $range_slug)
|
||||
{
|
||||
// @phpcs:enable
|
||||
$range = Range::where('slug', $range_slug)->first();
|
||||
if (!$range || !$range->status) {
|
||||
abort(404);
|
||||
}
|
||||
$products = Product::where('range_id', $range->id)->where('status', 1)->paginate(9);
|
||||
// Find promo within range.
|
||||
$offres = Product::where('range_id', $range->id)
|
||||
->where('status', 1)
|
||||
->has('promotions')
|
||||
->with('promotions')->get();
|
||||
return view('range', compact('range', 'products', 'offres'));
|
||||
}
|
||||
|
||||
/**
|
||||
* One product page
|
||||
*
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ namespace App\Http\Requests;
|
|||
use App\Rules\Adult;
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
use Illuminate\Validation\Rule;
|
||||
use Illuminate\Validation\Rules\Password;
|
||||
|
||||
class CustomerRegisterRequest extends FormRequest
|
||||
{
|
||||
|
|
@ -60,8 +61,16 @@ class CustomerRegisterRequest extends FormRequest
|
|||
'address' => 'sometimes|max:255',
|
||||
'postal_code' => 'required',
|
||||
'town' => 'required|string|max:255',
|
||||
'email' => 'required|email:rfc,dns,spoof|max:255',
|
||||
'password' => 'required|confirmed|min:8|max:255',
|
||||
'email' => 'required|unique:customers,email|email:rfc,dns,spoof|max:255',
|
||||
'password' => [
|
||||
'required', 'required_with:password_confirmation', 'confirmed', 'max:255',
|
||||
Password::min(8)
|
||||
->mixedCase()
|
||||
->letters()
|
||||
->numbers()
|
||||
->symbols()
|
||||
->uncompromised()
|
||||
],
|
||||
'ok_cgv' => 'accepted',
|
||||
'optin' => 'sometimes',
|
||||
'birth_date' => ['required',new Adult()],
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ class CustomerUpdatePassword extends FormRequest
|
|||
return [
|
||||
'password_old' => 'required',
|
||||
'password' => [
|
||||
'required', 'confirmed', 'min:8', 'max:255',
|
||||
'required', 'required_with:password_confirmation', 'confirmed', 'max:255',
|
||||
Password::min(8)
|
||||
->mixedCase()
|
||||
->letters()
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ use Illuminate\Foundation\Auth\User as Authenticatable;
|
|||
use App\Models\Salarie;
|
||||
use LDC\LDCCRM\Exceptions\CrmException;
|
||||
use LDC\LDCCRM\Models\Customer as CrmCustomer;
|
||||
use Carbon\Carbon;
|
||||
|
||||
class Customers extends Authenticatable
|
||||
{
|
||||
|
|
@ -113,4 +114,17 @@ class Customers extends Authenticatable
|
|||
return parent::toArray();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if customer is no longer employed
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function isNoLongerEmployed()
|
||||
{
|
||||
if (!$this->salarie->end_date) {
|
||||
return false;
|
||||
}
|
||||
return Carbon::parse($this->salarie->end_date)->lessThanOrEqualTo(Carbon::now());
|
||||
}
|
||||
}
|
||||
|
|
|
|||
17
package-lock.json
generated
17
package-lock.json
generated
|
|
@ -4,7 +4,6 @@
|
|||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "srcs",
|
||||
"devDependencies": {
|
||||
"@fancyapps/fancybox": "^3.5.7",
|
||||
"@fortawesome/fontawesome-free": "^6.2.0",
|
||||
|
|
@ -3284,9 +3283,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/caniuse-lite": {
|
||||
"version": "1.0.30001393",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001393.tgz",
|
||||
"integrity": "sha512-N/od11RX+Gsk+1qY/jbPa0R6zJupEa0lxeBG598EbrtblxVCTJsQwbRBm6+V+rxpc5lHKdsXb9RY83cZIPLseA==",
|
||||
"version": "1.0.30001517",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001517.tgz",
|
||||
"integrity": "sha512-Vdhm5S11DaFVLlyiKu4hiUTkpZu+y1KA/rZZqVQfOD5YdDT/eQKlkt7NaE0WGOFgX32diqt9MiP9CAiFeRklaA==",
|
||||
"dev": true,
|
||||
"funding": [
|
||||
{
|
||||
|
|
@ -3296,6 +3295,10 @@
|
|||
{
|
||||
"type": "tidelift",
|
||||
"url": "https://tidelift.com/funding/github/npm/caniuse-lite"
|
||||
},
|
||||
{
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/ai"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
|
@ -12340,9 +12343,9 @@
|
|||
}
|
||||
},
|
||||
"caniuse-lite": {
|
||||
"version": "1.0.30001393",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001393.tgz",
|
||||
"integrity": "sha512-N/od11RX+Gsk+1qY/jbPa0R6zJupEa0lxeBG598EbrtblxVCTJsQwbRBm6+V+rxpc5lHKdsXb9RY83cZIPLseA==",
|
||||
"version": "1.0.30001517",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001517.tgz",
|
||||
"integrity": "sha512-Vdhm5S11DaFVLlyiKu4hiUTkpZu+y1KA/rZZqVQfOD5YdDT/eQKlkt7NaE0WGOFgX32diqt9MiP9CAiFeRklaA==",
|
||||
"dev": true
|
||||
},
|
||||
"chalk": {
|
||||
|
|
|
|||
4
public/basic/css/app.css
vendored
4
public/basic/css/app.css
vendored
|
|
@ -1,4 +0,0 @@
|
|||
nav ol {
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
30336
public/basic/js/app.js
vendored
30336
public/basic/js/app.js
vendored
File diff suppressed because it is too large
Load diff
|
|
@ -1,25 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('title', __('Connexion'))
|
||||
|
||||
@section('content')
|
||||
<h1>Se connecter</h1>
|
||||
@if ($errors->any())
|
||||
<div class="alert alert-danger">
|
||||
<ul>
|
||||
@foreach ($errors->all() as $error)
|
||||
<li>{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
<br>
|
||||
<form action="{{ route('auth.login.post') }}" method="POST">
|
||||
@csrf
|
||||
<input name="email" type="email" placeholder="Email" required>
|
||||
<br>
|
||||
<input name="password" type="password" placeholder="Mot de passe" required>
|
||||
<br>
|
||||
<input type="submit" value="Connexion">
|
||||
</form>
|
||||
@endsection
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Se connecter</h1>
|
||||
@if ($errors->any())
|
||||
<div class="alert alert-danger">
|
||||
<ul>
|
||||
@foreach ($errors->all() as $error)
|
||||
<li>{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
<br>
|
||||
<form action="{{ route('auth.login.post') }}" method="POST">
|
||||
@csrf
|
||||
<input name="email" type="email" placeholder="Email" required>
|
||||
<br>
|
||||
<input name="password" type="password" placeholder="Mot de passe" required>
|
||||
<br>
|
||||
<input type="submit" value="Connexion">
|
||||
</form>
|
||||
@endsection
|
||||
|
|
@ -1,37 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Inscription</h1>
|
||||
|
||||
@if ($errors->any())
|
||||
<div class="alert alert-danger">
|
||||
<ul>
|
||||
@foreach ($errors->all() as $error)
|
||||
<li>{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if (session('success'))
|
||||
<h1>{{ session('success') }}</h1>
|
||||
@else
|
||||
<form action="{{ route('auth.register.post') }}" method="POST">
|
||||
@csrf
|
||||
<input name="lastname" type="text" placeholder="Nom" required>
|
||||
<input name="firstname" type="text" placeholder="Prénom" required>
|
||||
<br>
|
||||
<label>+18 ans</label><br>
|
||||
<input name="date_of_birth" type="date" required>
|
||||
<br>
|
||||
<input name="email" type="email" placeholder="Votre adresse email" pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$" required>
|
||||
<br>
|
||||
<input name="email_confirmation" type="email" placeholder="Confirmez votre adresse email" pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$" required>
|
||||
<br>
|
||||
<input name="password" type="password" placeholder="Votre mot de passe" required>
|
||||
<br>
|
||||
<input type="submit" value="Valider">
|
||||
</form>
|
||||
@endif
|
||||
|
||||
@endsection
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Mot de passe oublié ?</h1>
|
||||
@endsection
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Mon panier</h1>
|
||||
@endsection
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Contact</h1>
|
||||
@if ($content !== null)
|
||||
{!!$content->value!!}
|
||||
@endif
|
||||
@endsection
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>FAQ</h1><br/>
|
||||
@foreach ($faq as $f)
|
||||
<h3>{{$f->question}}</h3>
|
||||
<p>{{$f->answer}}</p>
|
||||
@endforeach
|
||||
@endsection
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Home</h1>
|
||||
@if ($content !== null)
|
||||
{!!$content->value!!}
|
||||
@endif
|
||||
@endsection
|
||||
7
resources/views/front/basic/js/app.js
vendored
7
resources/views/front/basic/js/app.js
vendored
|
|
@ -1,7 +0,0 @@
|
|||
//front JS for the theme
|
||||
|
||||
require('./bootstrap');
|
||||
|
||||
$(document).ready(function() {
|
||||
console.log('basic theme on');
|
||||
});
|
||||
39
resources/views/front/basic/js/bootstrap.js
vendored
39
resources/views/front/basic/js/bootstrap.js
vendored
|
|
@ -1,39 +0,0 @@
|
|||
window._ = require('lodash');
|
||||
|
||||
/**
|
||||
* We'll load jQuery.
|
||||
* This code may be modified to fit the specific needs of your application.
|
||||
*/
|
||||
|
||||
try {
|
||||
|
||||
window.$ = window.jQuery = require('jquery');
|
||||
|
||||
} catch (e) {}
|
||||
|
||||
/**
|
||||
* We'll load the axios HTTP library which allows us to easily issue requests
|
||||
* to our Laravel back-end. This library automatically handles sending the
|
||||
* CSRF token as a header based on the value of the "XSRF" token cookie.
|
||||
*/
|
||||
|
||||
window.axios = require('axios');
|
||||
|
||||
window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';
|
||||
|
||||
/**
|
||||
* Echo exposes an expressive API for subscribing to channels and listening
|
||||
* for events that are broadcast by Laravel. Echo and event broadcasting
|
||||
* allows your team to easily build robust real-time web applications.
|
||||
*/
|
||||
|
||||
// import Echo from 'laravel-echo';
|
||||
|
||||
// window.Pusher = require('pusher-js');
|
||||
|
||||
// window.Echo = new Echo({
|
||||
// broadcaster: 'pusher',
|
||||
// key: process.env.MIX_PUSHER_APP_KEY,
|
||||
// cluster: process.env.MIX_PUSHER_APP_CLUSTER,
|
||||
// forceTLS: true
|
||||
// });
|
||||
|
|
@ -1,38 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<title>@yield('title') - {{ Config::get('theme.site_name') }}</title>
|
||||
<!-- Styles -->
|
||||
<link href="{{ asset(config('app.theme').'/css/app.css') }}" rel="stylesheet">
|
||||
</head>
|
||||
<body>
|
||||
<nav>
|
||||
<ol>
|
||||
<li><a href="{{ route('home') }}">Accueil</a></li>
|
||||
<li><a href="{{ route('contact') }}">Contact</a></li>
|
||||
<li><a href="{{ route('legal-notice') }}">Mentions Légales</a></li>
|
||||
<li><a href="{{ route('terms') }}">CGV</a></li>
|
||||
<li><a href="{{ route('privacy') }}">Politique de confidentialité</a></li>
|
||||
<li><a href="{{ route('faq') }}">FAQ</a></li>
|
||||
<li>-</li>
|
||||
@auth
|
||||
<li><a href="{{ route('auth.logout') }}">Se déconnecter</a></li>
|
||||
@else
|
||||
<li><a href="{{ route('auth.login') }}">Se connecter</a></li>
|
||||
<li><a href="{{ route('auth.register') }}">Inscription</a></li>
|
||||
{{--<li><a href="{{ route('auth.reset-password') }}">Mot de passe oublié ?</a></li>--}}
|
||||
@endif
|
||||
<li>-</li>
|
||||
{{--<li><a href="{{ route('basket') }}">Mon Panier</a></li>--}}
|
||||
<li>-</li>
|
||||
<li><a href="{{ route('ranges') }}">Gammes de produits</a></li>
|
||||
</ol>
|
||||
</nav>
|
||||
@yield('content')
|
||||
<script src="{{ asset(config('app.theme').'/js/app.js') }}"></script>
|
||||
@yield('scripts')
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Mentions Légales</h1>
|
||||
@if ($content !== null)
|
||||
{!!$content->value!!}
|
||||
@endif
|
||||
@endsection
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Politique de confidentialité</h1>
|
||||
@if ($content !== null)
|
||||
{!!$content->value!!}
|
||||
@endif
|
||||
@endsection
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Produit "{{$product->name}}"</h1>
|
||||
@endsection
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Gamme de produits "{{$range->name}}"</h1>
|
||||
<ul>
|
||||
@foreach($range->products as $product)
|
||||
<li><a href="{{route('product', $product->slug)}}">{{$product->name}}</a></li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endsection
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>Gammes de produits</h1>
|
||||
<ul>
|
||||
@foreach ($published_ranges as $range)
|
||||
<li><a href="{{ route('range', ['rangeSlug' => $range->slug]) }}">Gamme de produits - {{$range->name}}</a></li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endsection
|
||||
6
resources/views/front/basic/sass/app.scss
vendored
6
resources/views/front/basic/sass/app.scss
vendored
|
|
@ -1,6 +0,0 @@
|
|||
//Front CSS for theme
|
||||
nav {
|
||||
ol {
|
||||
list-style: none;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
@extends('layouts.layout')
|
||||
|
||||
@section('content')
|
||||
<h1>CGV</h1>
|
||||
@if ($content !== null)
|
||||
{!!$content->value!!}
|
||||
@endif
|
||||
@endsection
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'theme_name' => 'basic',
|
||||
'site_name' => 'Boutique Générique',
|
||||
'company' => 'LDC',
|
||||
'analytics' => '',
|
||||
'product_image_maxwidth' => '100',
|
||||
'product_image_maxheight' => '100',
|
||||
'product_image_large_maxwidth' => '100',
|
||||
'product_image_large_maxheight' => '100',
|
||||
'range_image_maxwidth' => '100',
|
||||
'range_image_maxheight' => '100',
|
||||
'range_image_large_maxwidth' => '100',
|
||||
'range_image_large_maxheight' => '100',
|
||||
'content_banner_maxwidth' => '100',
|
||||
'content_banner_maxheight' => '100',
|
||||
'slide_image_maxwidth' => '1180',
|
||||
'slide_image_maxheight' => '449',
|
||||
/**
|
||||
* attention ce paramètre est un paramètre de fonctionnement
|
||||
* (y compris du back office) et nons un paramète esthétique.
|
||||
* il est lié au moteur de la boutique et ne doit pas changer
|
||||
* (au moins jamais se reduire lors d'un changement de thème)
|
||||
*/
|
||||
'enum_product_types' => [
|
||||
'foodProduct' => 'Alimentaire',
|
||||
],
|
||||
];
|
||||
|
|
@ -13,7 +13,7 @@
|
|||
<p class="m-0 me-2">Votre mot de passe a bien été modifié.</p>
|
||||
</div>
|
||||
<div class="text-center mt-2">
|
||||
<a class="btn btn-product rounded-4" href="{{ route('account.dashboard') }}">Voir mon profile</a>
|
||||
<a class="btn btn-product rounded-4" href="{{ route('account.dashboard') }}">Voir mon profil</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_confirmation"
|
||||
placeholder="Confirmer votre nouveau mot de passe*"
|
||||
placeholder="Confirmer mot de passe*"
|
||||
value="{{ old('password_confirmation') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -4,193 +4,196 @@
|
|||
@section('description', 'Procédure d\inscription à la boutique.')
|
||||
|
||||
@section('content')
|
||||
<main class="auth-login container d-flex justify-content-center align-items-center">
|
||||
<div class="row">
|
||||
<div class="col my-5">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">Inscription</h1>
|
||||
@if (session('success'))
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<p class="m-0 me-2">Félicitations</p>
|
||||
<p class="m-0">Votre compte a bien été créé !</p>
|
||||
<p class="m-0">Vous allez recevoir un mail de confirmation sur l'adresse {{ $mail }}</p>
|
||||
</div>
|
||||
<div class="text-center mt-2">
|
||||
<a class="btn btn-product rounded-4" href="{{ route('auth.connexion') }}">Connectez-vous</a>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
<form action="{{ route('auth.register.post') }}" method="POST" id="stdinscription">
|
||||
@csrf
|
||||
@if ($errors->any())
|
||||
<div>
|
||||
<ul class="list-group">
|
||||
@foreach ($errors->all() as $error)
|
||||
<li class="list-group-item bg-transparent text-red border-0 text-center">{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
@if (config('bosettings.register_salaries') && config('bosettings.register_public'))
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<button class="btn btn-product rounded-4 mb-2 no-after" onclick="visibility2()" type="button" id="codebutton">J'ai un code d'inscription</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-2" id="codeinscription" style="display: none;">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="matricule"
|
||||
placeholder="Matricule*"
|
||||
value="{{ old('matricule') }}"/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="code"
|
||||
placeholder="Code d'inscription*"
|
||||
value="{{ old('code') }}"/>
|
||||
</div>
|
||||
</div>
|
||||
@elseif (config('bosettings.register_salaries') && !config('bosettings.register_public'))
|
||||
<div class="row mb-2" id="codeinscription">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="matricule"
|
||||
placeholder="Matricule*"
|
||||
value="{{ old('matricule') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="code"
|
||||
placeholder="Code d'inscription*"
|
||||
value="{{ old('code') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="lastname"
|
||||
placeholder="Nom*"
|
||||
value="{{ old('lastname') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="firstname"
|
||||
placeholder="Prénom*"
|
||||
value="{{ old('firstname') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<p class="w-50 m-0">Date de naissance *</p>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="date"
|
||||
name="birth_date"
|
||||
placeholder="Date de naissance*"
|
||||
value="{{ old('birth_date') }}" required>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
name="email"
|
||||
type="email"
|
||||
placeholder="Votre adresse email *"
|
||||
autocomplete="email"
|
||||
pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"
|
||||
value="{{ old('email') }}" required>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password"
|
||||
id="password"
|
||||
placeholder="Mot de passe*"
|
||||
value="{{ old('password') }}" required/>
|
||||
<span class="input-group-btn" id="eyeSlash">
|
||||
<button class="btn no-after reveal" onclick="visibility3()" type="button">
|
||||
<i class="fas fa-eye-slash" aria-hidden="true"></i>
|
||||
</button>
|
||||
</span>
|
||||
<span class="input-group-btn" id="eyeShow" style="display: none;">
|
||||
<button class="btn no-after reveal" onclick="visibility3()" type="button">
|
||||
<i class="fas fa-eye" aria-hidden="true"></i>
|
||||
</button>
|
||||
</span>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_confirmation"
|
||||
id="password_confirmation"
|
||||
placeholder="Confirmer mot de passe*"
|
||||
autocomplete="new-password"
|
||||
value="{{ old('password_confirmation') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="phone"
|
||||
id="phone"
|
||||
autocomplete="tel"
|
||||
placeholder="Téléphone"
|
||||
pattern="[0-9]{10}"
|
||||
value="{{ old('phone') }}">
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="address"
|
||||
placeholder="Adresse postale*"
|
||||
autocomplete="street-address"
|
||||
value="{{ old('address') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="postal_code"
|
||||
placeholder="Code postal*"
|
||||
autocomplete="postal-code"
|
||||
value="{{ old('postal_code') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="town"
|
||||
id="town"
|
||||
autocomplete="tel"
|
||||
placeholder="Ville*"
|
||||
value="{{ old('town') }}">
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="ok_cgv" role="button" id="ok_cgv">
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="ok_cgv">
|
||||
J'ai lu et accepte les <a href="{{ route('terms') }}" target="mentions">conditions générales</a> et la <a href="{{ route('privacy') }}" target="mentions">politique de gestion des données personnelles</a>.
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="remember" role="button" id="optin">
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="optin">
|
||||
Je souhaite m'inscrire à la newsletter {{ Config::get('theme.site_name') }}.
|
||||
</label>
|
||||
</div>
|
||||
<div class="text-center fst-italic my-2">*Champs obligatoires</div>
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<button class="btn btn-product rounded-4" type="submit">S'inscrire</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<p class="m-0 me-2">Déjà inscrit ?</p>
|
||||
<a class="btn btn-product rounded-4" href="{{ route('auth.connexion') }}">Connectez-vous</a>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<main class="auth-login container d-flex justify-content-center align-items-center">
|
||||
<div class="row">
|
||||
<div class="col my-5">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ __('Inscription') }}</h1>
|
||||
@if (session('success'))
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<p class="m-0 me-2">{{ __('Félicitations') }}</p>
|
||||
<p class="m-0">{{ __('Votre compte a bien été créé !') }}</p>
|
||||
<p class="m-0">{{ __('Vous allez recevoir un mail de confirmation sur l\'adresse') }} {{ $mail }}</p>
|
||||
</div>
|
||||
<div class="text-center mt-2">
|
||||
<a class="btn btn-product rounded-4" href="{{ route('auth.connexion') }}">{{ __('Connectez-vous') }}</a>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
<form action="{{ route('auth.register.post') }}" method="POST" id="stdinscription">
|
||||
@csrf
|
||||
@if ($errors->any())
|
||||
<div>
|
||||
<ul class="list-group">
|
||||
@foreach ($errors->all() as $error)
|
||||
<li class="list-group-item bg-transparent text-red border-0 text-center">{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
@if (config('bosettings.register_salaries') && config('bosettings.register_public'))
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<button class="btn btn-product rounded-4 mb-2 no-after" onclick="visibility2()" type="button" id="codebutton">{{ __('J\'ai un code d\'inscription') }}</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mb-2" id="codeinscription" style="display: none;">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="matricule"
|
||||
placeholder="Matricule*"
|
||||
value="{{ old('matricule') }}"/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="code"
|
||||
placeholder="Code d'inscription*"
|
||||
value="{{ old('code') }}"/>
|
||||
</div>
|
||||
</div>
|
||||
@elseif (config('bosettings.register_salaries') && !config('bosettings.register_public'))
|
||||
<div class="row mb-2" id="codeinscription">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="matricule"
|
||||
placeholder="Matricule*"
|
||||
value="{{ old('matricule') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="code"
|
||||
placeholder="Code d'inscription*"
|
||||
value="{{ old('code') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="lastname"
|
||||
placeholder="Nom*"
|
||||
value="{{ old('lastname') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="firstname"
|
||||
placeholder="Prénom*"
|
||||
value="{{ old('firstname') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<p class="w-50 m-0">{{ __('Date de naissance *') }}</p>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="date"
|
||||
name="birth_date"
|
||||
placeholder="Date de naissance*"
|
||||
value="{{ old('birth_date') }}" required>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
name="email"
|
||||
type="email"
|
||||
placeholder="Votre adresse email *"
|
||||
autocomplete="email"
|
||||
pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"
|
||||
value="{{ old('email') }}" required>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password"
|
||||
id="password"
|
||||
placeholder="Mot de passe*"
|
||||
value="{{ old('password') }}" required/>
|
||||
<span class="input-group-btn" id="eyeSlash">
|
||||
<button class="btn no-after reveal" onclick="visibility3()" type="button">
|
||||
<i class="fas fa-eye-slash" aria-hidden="true"></i>
|
||||
</button>
|
||||
</span>
|
||||
<span class="input-group-btn" id="eyeShow" style="display: none;">
|
||||
<button class="btn no-after reveal" onclick="visibility3()" type="button">
|
||||
<i class="fas fa-eye" aria-hidden="true"></i>
|
||||
</button>
|
||||
</span>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_confirmation"
|
||||
id="password_confirmation"
|
||||
placeholder="Confirmer mot de passe*"
|
||||
autocomplete="new-password"
|
||||
value="{{ old('password_confirmation') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<p class="text-center text-muted m-0">
|
||||
{{ __('Le mot de passe doit avoir une longueur minimale de 8 caractères et doit contenir majuscule, minuscule, chiffre et caractère spécial.') }}
|
||||
</p>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="phone"
|
||||
id="phone"
|
||||
autocomplete="tel"
|
||||
placeholder="Téléphone"
|
||||
pattern="[0-9]{10}"
|
||||
value="{{ old('phone') }}">
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="address"
|
||||
placeholder="Adresse postale*"
|
||||
autocomplete="street-address"
|
||||
value="{{ old('address') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="postal_code"
|
||||
placeholder="Code postal*"
|
||||
autocomplete="postal-code"
|
||||
value="{{ old('postal_code') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="town"
|
||||
id="town"
|
||||
autocomplete="tel"
|
||||
placeholder="Ville*"
|
||||
value="{{ old('town') }}">
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="ok_cgv" role="button" id="ok_cgv">
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="ok_cgv">
|
||||
{{ __('J\'ai lu et accepte les') }} <a href="{{ route('terms') }}" target="mentions">{{ __('conditions générales') }}</a> et la <a href="{{ route('privacy') }}" target="mentions">{{ __('politique de gestion des données personnelles') }}</a>.
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="remember" role="button" id="optin">
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="optin">
|
||||
{{ __('Je souhaite m\'inscrire à la newsletter') }} {{ Config::get('theme.site_name') }}.
|
||||
</label>
|
||||
</div>
|
||||
<div class="text-center fst-italic my-2">{{ __('*Champs obligatoires') }}</div>
|
||||
<div class="row">
|
||||
<div class="text-center">
|
||||
<button class="btn btn-product rounded-4" type="submit">{{ __('S\'inscrire') }}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<p class="m-0 me-2">{{ __('Déjà inscrit ?') }}</p>
|
||||
<a class="btn btn-product rounded-4" href="{{ route('auth.connexion') }}">{{ __('Connectez-vous') }}</a>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
</main>
|
||||
@endsection
|
||||
|
||||
<script>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
@section('content')
|
||||
<section class="contact-content">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{!! $content->title !!}</h1>
|
||||
<h1 class="title-big title-sm-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-5">{!! $content->title !!}</h1>
|
||||
<div class="row justify-content-around">
|
||||
<div class="col-12 col-lg-6 p-0 font-Barlow-bold">
|
||||
@if ($content !== null)
|
||||
|
|
|
|||
|
|
@ -4,166 +4,169 @@
|
|||
@section('description', 'Informations concernant votre compte personnel.')
|
||||
|
||||
@section('content')
|
||||
<main class="auth-login container d-flex justify-content-center align-items-center">
|
||||
<div class="row">
|
||||
<div class="col my-5">
|
||||
@if ($errors->any())
|
||||
<div>
|
||||
<ul class="list-group">
|
||||
@foreach ($errors->all() as $error)
|
||||
<li class="list-group-item bg-transparent text-red border-0 text-center">{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
<main class="auth-login container d-flex justify-content-center align-items-center">
|
||||
<div class="row">
|
||||
<div class="col my-5">
|
||||
@if ($errors->any())
|
||||
<div>
|
||||
<ul class="list-group">
|
||||
@foreach ($errors->all() as $error)
|
||||
<li class="list-group-item bg-transparent text-red border-0 text-center">{{ $error }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@elseif (session('success'))
|
||||
<div class="text-green">
|
||||
{{ session('success') }}
|
||||
</div>
|
||||
@endif
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ __('Mon compte') }}</h2>
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-end text-center p-0">
|
||||
<div class="row">
|
||||
<a href="{{ route('account.my-orders') }}">
|
||||
<span class="header-actions__item-icon icon">@include('icons.orders')</span>
|
||||
<button class="btn btn-product rounded-4">{{ __('Mes commandes') }}</button>
|
||||
</a>
|
||||
</div>
|
||||
@elseif (session('success'))
|
||||
<div class="text-green">
|
||||
{{ session('success') }}
|
||||
</div>
|
||||
@endif
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">Mon compte</h2>
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-end text-center p-0">
|
||||
<div class="row">
|
||||
<a href="{{ route('account.my-orders') }}">
|
||||
<span class="header-actions__item-icon icon">@include('icons.orders')</span>
|
||||
<button class="btn btn-product rounded-4">Mes commandes</button>
|
||||
</a>
|
||||
</div>
|
||||
<div class="row">
|
||||
<a href="{{ route('auth.deconnexion') }}">
|
||||
<span class="header-actions__item-icon icon">@include('icons.close')</span>
|
||||
<button class="btn btn-product rounded-4">Se déconnecter</button>
|
||||
</a>
|
||||
</div>
|
||||
<div class="row">
|
||||
<a href="{{ route('auth.deconnexion') }}">
|
||||
<span class="header-actions__item-icon icon">@include('icons.close')</span>
|
||||
<button class="btn btn-product rounded-4">{{ __('Se déconnecter') }}</button>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-2">Mes coordonnées</h2>
|
||||
<p class="text-center m-0">Pour modifier vos informations personnelles,</p>
|
||||
<p class="text-center">il vous suffit de renseigner vos nouvelles données dans le formulaire ci-dessous :</p>
|
||||
<form action="{{ route('account.update-infos') }}" method="POST" class="mx-auto">
|
||||
@csrf
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="lastname"
|
||||
placeholder="Nom*"
|
||||
value="{{ old('lastname', $crmInfos->lastname) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="firstname"
|
||||
placeholder="Prénom*"
|
||||
value="{{ old('firstname', $crmInfos->firstname) }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<p class="w-50 m-0">Date de naissance *</p>
|
||||
<span class="w-50 row">
|
||||
<select name="day" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = 1; $i <= 31; $i++)
|
||||
<option value="{{ $i < 10 ? '0' . $i : $i }}" @if($birthDate[2] == $i) selected @endif>{{ $i < 10 ? '0' . $i : $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
<select name="month" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = 1; $i <= 12; $i++)
|
||||
<option value="{{ $i < 10 ? '0' . $i : $i }}" @if($birthDate[1] == $i) selected @endif>{{ $i < 10 ? '0' . $i : $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
<select name="year" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = date('Y'); $i >= date('Y') - 100; $i--)
|
||||
<option value="{{ $i }}" @if($birthDate[0] == $i) selected @endif>{{ $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
name="email"
|
||||
type="email"
|
||||
placeholder="Votre adresse email *"
|
||||
autocomplete="email"
|
||||
pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"
|
||||
value="{{ old('email', $customer->email) }}" disabled>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="address"
|
||||
placeholder="Adresse postale*"
|
||||
autocomplete="street-address"
|
||||
value="{{ old('address', $crmInfos->address) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="postcode"
|
||||
placeholder="Code postale*"
|
||||
autocomplete="postal-code"
|
||||
value="{{ old('postcode', $crmInfos->postcode) }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="city"
|
||||
placeholder="Ville*"
|
||||
autocomplete="city"
|
||||
value="{{ old('city', $crmInfos->city) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="phone"
|
||||
placeholder="Téléphone*"
|
||||
autocomplete="phone"
|
||||
value="{{ old('phone', $crmInfos->phone) }}"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="optin" role="button" id="optin" @if(old('optin', $crmInfos->opt_in))checked @endif>
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="optin">
|
||||
J'accepte de recevoir les actualités et bons plans {{ Config::get('theme.site_name') }}.
|
||||
</label>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<button class="btn btn-product rounded-4">Enregistrer</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-2">Mot de passe</h2>
|
||||
<form method="post" action="{{ route('account.change-password') }}" class="mx-auto">
|
||||
@csrf
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_old"
|
||||
placeholder="Ancien mot de passe"
|
||||
value="{{ old('password_old') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password"
|
||||
placeholder="Nouveau mot de passe"
|
||||
value="{{ old('password') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_confirmation"
|
||||
placeholder="Confirmer le nouveau mot de passe"
|
||||
value="{{ old('password_confirmation') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<button class="btn btn-product rounded-4">Modifier</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-2">{{ __('Mes coordonnées') }}</h2>
|
||||
<p class="text-center m-0">{{ __('Pour modifier vos informations personnelles,') }}</p>
|
||||
<p class="text-center">{{ __('il vous suffit de renseigner vos nouvelles données dans le formulaire ci-dessous :') }}</p>
|
||||
<form action="{{ route('account.update-infos') }}" method="POST" class="mx-auto">
|
||||
@csrf
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="lastname"
|
||||
placeholder="Nom*"
|
||||
value="{{ old('lastname', $crmInfos->lastname) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="firstname"
|
||||
placeholder="Prénom*"
|
||||
value="{{ old('firstname', $crmInfos->firstname) }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<p class="w-50 m-0">{{ __('Date de naissance *') }}</p>
|
||||
<span class="w-50 row">
|
||||
<select name="day" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = 1; $i <= 31; $i++)
|
||||
<option value="{{ $i < 10 ? '0' . $i : $i }}" @if($birthDate[2] == $i) selected @endif>{{ $i < 10 ? '0' . $i : $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
<select name="month" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = 1; $i <= 12; $i++)
|
||||
<option value="{{ $i < 10 ? '0' . $i : $i }}" @if($birthDate[1] == $i) selected @endif>{{ $i < 10 ? '0' . $i : $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
<select name="year" class="form-control text-center rounded-4 border-dark">
|
||||
@for ($i = date('Y'); $i >= date('Y') - 100; $i--)
|
||||
<option value="{{ $i }}" @if($birthDate[0] == $i) selected @endif>{{ $i }}</option>
|
||||
@endfor
|
||||
</select>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<input class="w-100 form-control rounded-4 border-dark"
|
||||
name="email"
|
||||
type="email"
|
||||
placeholder="Votre adresse email *"
|
||||
autocomplete="email"
|
||||
pattern="[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"
|
||||
value="{{ old('email', $customer->email) }}" disabled>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="address"
|
||||
placeholder="Adresse postale*"
|
||||
autocomplete="street-address"
|
||||
value="{{ old('address', $crmInfos->address) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="postcode"
|
||||
placeholder="Code postal*"
|
||||
autocomplete="postal-code"
|
||||
value="{{ old('postcode', $crmInfos->postcode) }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="text"
|
||||
name="city"
|
||||
placeholder="Ville*"
|
||||
autocomplete="city"
|
||||
value="{{ old('city', $crmInfos->city) }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="number"
|
||||
name="phone"
|
||||
placeholder="Téléphone*"
|
||||
autocomplete="phone"
|
||||
value="{{ old('phone', $crmInfos->phone) }}"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-check d-flex flex-row justify-content-center align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input class="form-check-input m-0" type="checkbox" name="optin" role="button" id="optin" @if(old('optin', $crmInfos->opt_in))checked @endif>
|
||||
<label class="w-75 form-check-label ps-2" role="button" for="optin">
|
||||
{{ __('J\'accepte de recevoir les actualités et bons plans') }} {{ Config::get('theme.site_name') }}.
|
||||
</label>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<button class="btn btn-product rounded-4">{{ __('Enregistrer') }}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<h2 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-2">{{ __('Mot de passe') }}</h2>
|
||||
<form method="post" action="{{ route('account.change-password') }}" class="mx-auto">
|
||||
@csrf
|
||||
<div class="row">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_old"
|
||||
placeholder="Ancien mot de passe"
|
||||
value="{{ old('password_old') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center p-0">
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password"
|
||||
placeholder="Nouveau mot de passe"
|
||||
value="{{ old('password') }}" required/>
|
||||
<input class="w-50 form-control rounded-4 border-dark"
|
||||
type="password"
|
||||
name="password_confirmation"
|
||||
placeholder="Confirmer mot de passe"
|
||||
value="{{ old('password_confirmation') }}" required/>
|
||||
</div>
|
||||
</div>
|
||||
<p class="text-center text-muted m-0">
|
||||
{{ __('Le nouveau mot de passe doit avoir une longueur minimale de 8 caractères et doit contenir majuscule, minuscule, chiffre et caractère spécial.') }}
|
||||
</p>
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex justify-content-center align-items-center text-center">
|
||||
<button class="btn btn-product rounded-4">{{ __('Modifier') }}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
</main>
|
||||
@endsection
|
||||
|
|
|
|||
|
|
@ -6,27 +6,27 @@
|
|||
@section('breadcrumb', 'no')
|
||||
|
||||
@section('content')
|
||||
<section>
|
||||
<div class="row w-100">
|
||||
<div class="col">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ $content->value }}</h1>
|
||||
@if ($content !== null)
|
||||
@foreach ($faq as $key => $f)
|
||||
<div class="row mt-2">
|
||||
<div class="col">
|
||||
<button class="btn btn-product title-small rounded-4 text-dark"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#faqNumber{{ $key }}" aria-expanded="false"
|
||||
aria-controls="faqNumber{{ $key }}">
|
||||
<div class="d-flex flex-row justify-content-center align-items-center">{{ $f->question }}</div>
|
||||
</button>
|
||||
<div id="faqNumber{{ $key }}" class="collapse">
|
||||
<p class="m-0 p-3 pt-2">{{ $f->answer }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
<section>
|
||||
<div class="row w-100">
|
||||
<div class="col">
|
||||
<h1 class="title-big title-sm-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-5">{{ $content->value }}</h1>
|
||||
@if ($content !== null)
|
||||
@foreach ($faq as $key => $f)
|
||||
<div class="row mt-2">
|
||||
<div class="col">
|
||||
<button class="btn btn-product title-small rounded-4 text-dark"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#faqNumber{{ $key }}" aria-expanded="false"
|
||||
aria-controls="faqNumber{{ $key }}">
|
||||
<div class="d-flex flex-row justify-content-center align-items-center">{{ $f->question }}</div>
|
||||
</button>
|
||||
<div id="faqNumber{{ $key }}" class="collapse">
|
||||
<p class="m-0 p-3 pt-2">{{ $f->answer }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</section>
|
||||
@endsection
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<button class="btn icon-small icon-cross" @click="removeItem(item.cartItem.rowId)"></button>
|
||||
<button class="btn icon-small icon-cross" @click="removeItem(item.cartItem.rowId)" :disabled="(disableBtn) ? true : false"></button>
|
||||
</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
|
@ -79,12 +79,12 @@
|
|||
},
|
||||
data() {
|
||||
return {
|
||||
processing: false,
|
||||
success:false,
|
||||
errors:false,
|
||||
showConfirmEmpty:false,
|
||||
response: '',
|
||||
promotion_slide: -1
|
||||
promotion_slide: -1,
|
||||
disableBtn: false,
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
@ -125,23 +125,24 @@
|
|||
.catch(function (error) {
|
||||
console.log(error);
|
||||
this.response = "Erreur lors de la modification du panier.";
|
||||
this.processing = false;
|
||||
});
|
||||
}
|
||||
},
|
||||
removeItem(rowId) {
|
||||
this.disableBtn = true;
|
||||
axios.post('/ajax/remove-from-cart', {
|
||||
rowId: rowId,
|
||||
instance: 'panier',
|
||||
}).then(
|
||||
(response) => {
|
||||
this.updateStore(response.data);
|
||||
this.disableBtn = false;
|
||||
}
|
||||
)
|
||||
.catch(function (error) {
|
||||
console.log(error);
|
||||
this.response = "Erreur lors de la modification du panier.";
|
||||
this.processing = false;
|
||||
this.disableBtn = false;
|
||||
});
|
||||
},
|
||||
emptyCart() {
|
||||
|
|
@ -157,7 +158,6 @@
|
|||
.catch(function (error) {
|
||||
console.log(error);
|
||||
this.response = "Erreur lors de la modification du panier.";
|
||||
this.processing = false;
|
||||
});
|
||||
},
|
||||
confirmEmpty() {
|
||||
|
|
|
|||
|
|
@ -21,89 +21,89 @@
|
|||
<input v-on:change="updatedFilter()" class="form-control w-100 rounded-4 border-dark" :disabled="loading" type="text" id="search" name="search" v-model="search" placeholder="Rechercher...">
|
||||
<!--</form>-->
|
||||
</div>
|
||||
<!-- Filter Promotions -->
|
||||
<!-- <div class="m-3">
|
||||
<button
|
||||
class="btn filters-btn d-flex justify-content-between align-items-center rounded-0 w-100 border-0 p-0 pb-lg-2"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#filterCollapsePromotions"
|
||||
aria-expanded="true" aria-controls="filterCollapsePromotions">
|
||||
<span class="title-small font-Barlow-bold">Promotions</span>
|
||||
<svg id="arrow-down" class="svg" viewBox='0 0 16 16'>
|
||||
<path d="M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z" />
|
||||
</svg>
|
||||
</button>
|
||||
<div class="collapse show" id="filterCollapsePromotions">
|
||||
<div class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="hasPromotion" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button" id="filterPromotions">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button" for="filterPromotions">
|
||||
Promotions
|
||||
</label>
|
||||
<div class="accordion px-3" id="accordionFilters">
|
||||
<!-- Filter Promotions -->
|
||||
<!-- <div class="accordion-item rounded-0 border-0 bg-transparent mt-2">
|
||||
<h2 class="accordion-header" id="headingPromotions">
|
||||
<button class="accordion-button text-dark bg-transparent rounded-0 border-0 border-bottom border-3 border-secondary-subtle px-0 py-2 collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsePromotions" aria-expanded="true" aria-controls="collapsePromotions">
|
||||
<span class="title-small font-Barlow-bold">Promotions</span>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="collapsePromotions" class="accordion-collapse collapse" aria-labelledby="headingPromotions" data-bs-parent="#accordionFilters">
|
||||
<div class="accordion-body p-0">
|
||||
<div class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="hasPromotion" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button" id="filterPromotions">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button" for="filterPromotions">
|
||||
Promotions
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<!-- Filter Ranges -->
|
||||
<div class="accordion-item rounded-0 border-0 bg-transparent mt-2">
|
||||
<h2 class="accordion-header" id="headingRanges">
|
||||
<button class="accordion-button text-dark bg-transparent rounded-0 border-0 border-bottom border-3 border-secondary-subtle px-0 py-2" type="button" data-bs-toggle="collapse" data-bs-target="#collapseRanges" aria-expanded="true" aria-controls="collapseRanges">
|
||||
<span class="title-small font-Barlow-bold">Rayons</span>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="collapseRanges" class="accordion-collapse collapse show" aria-labelledby="headingRanges" data-bs-parent="#accordionFilters">
|
||||
<div class="accordion-body p-0">
|
||||
<!-- Ranges -->
|
||||
<div v-for="(range, rangeIndex) in ranges" :key="rangeIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="range.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterRanges${rangeIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterRanges${rangeIndex}`">
|
||||
{{ range.name }}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<!-- Filter Ranges -->
|
||||
<div class="m-3">
|
||||
<button
|
||||
class="btn filters-btn d-flex justify-content-between align-items-center rounded-0 w-100 border-0 p-0 pb-lg-2"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#filterCollapseRanges"
|
||||
aria-expanded="true" aria-controls="filterCollapseRanges">
|
||||
<span class="title-small font-Barlow-bold">Rayons</span>
|
||||
<i class="fas fa-chevron-down"></i>
|
||||
</button>
|
||||
<div class="collapse show" id="filterCollapseRanges">
|
||||
<!-- Ranges -->
|
||||
<div v-for="(range, rangeIndex) in ranges" :key="rangeIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="range.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterRanges${rangeIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterRanges${rangeIndex}`">
|
||||
{{ range.name }}
|
||||
</label>
|
||||
<!-- Filter Brands -->
|
||||
<div class="accordion-item rounded-0 border-0 bg-transparent mt-2">
|
||||
<h2 class="accordion-header" id="headingBrands">
|
||||
<button class="accordion-button text-dark bg-transparent rounded-0 border-0 border-bottom border-3 border-secondary-subtle px-0 py-2 collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseBrands" aria-expanded="false" aria-controls="collapseBrands">
|
||||
<span class="title-small font-Barlow-bold">Marques</span>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="collapseBrands" class="accordion-collapse collapse" aria-labelledby="headingBrands" data-bs-parent="#accordionFilters">
|
||||
<div class="accordion-body p-0">
|
||||
<!-- Brands -->
|
||||
<div v-for="(brand, brandIndex) in brands" :key="brandIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="brand.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterBrand${brandIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterBrand${brandIndex}`">
|
||||
{{ brand.label }}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Filter Brands -->
|
||||
<div class="m-3">
|
||||
<button
|
||||
class="btn filters-btn d-flex justify-content-between align-items-center rounded-0 w-100 border-0 p-0 pb-lg-2"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#filterCollapseBrand"
|
||||
aria-expanded="true" aria-controls="filterCollapseBrand">
|
||||
<span class="title-small font-Barlow-bold">Marques</span>
|
||||
<i class="fas fa-chevron-down"></i>
|
||||
</button>
|
||||
<div class="collapse show" id="filterCollapseBrand">
|
||||
<!-- Brands -->
|
||||
<div v-for="(brand, brandIndex) in brands" :key="brandIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="brand.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterBrand${brandIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterBrand${brandIndex}`">
|
||||
{{ brand.label }}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Filter Tags -->
|
||||
<div class="m-3">
|
||||
<button
|
||||
class="btn filters-btn d-flex justify-content-between align-items-center rounded-0 w-100 border-0 p-0 pb-lg-2"
|
||||
type="button" data-bs-toggle="collapse" data-bs-target="#filterCollapseTag"
|
||||
aria-expanded="true" aria-controls="filterCollapseTag">
|
||||
<span class="title-small font-Barlow-bold">Spécial</span>
|
||||
<i class="fas fa-chevron-down" aria-hidden="true"></i>
|
||||
</button>
|
||||
<div class="collapse show" id="filterCollapseTag">
|
||||
<!-- Tags -->
|
||||
<div v-for="(tag, tagIndex) in tags" :key="tagIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="tag.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterTag${tagIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterTag${tagIndex}`">
|
||||
{{ tag.label }}
|
||||
</label>
|
||||
<!-- Filter Tags -->
|
||||
<div class="accordion-item rounded-0 border-0 bg-transparent mt-2">
|
||||
<h2 class="accordion-header" id="headingTags">
|
||||
<button class="accordion-button text-dark bg-transparent rounded-0 border-0 border-bottom border-3 border-secondary-subtle px-0 py-2 collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTags" aria-expanded="false" aria-controls="collapseTags">
|
||||
<span class="title-small font-Barlow-bold">Spécial</span>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="collapseTags" class="accordion-collapse collapse" aria-labelledby="headingTags" data-bs-parent="#accordionFilters">
|
||||
<div class="accordion-body p-0">
|
||||
<!-- Tags -->
|
||||
<div v-for="(tag, tagIndex) in tags" :key="tagIndex"
|
||||
class="form-check d-flex flex-row flex-lg-row-reverse justify-content-between align-items-center rounded-2 px-3 py-2 p-lg-0 mt-2 mb-0">
|
||||
<input v-on:click="updatedFilter()" v-model="tag.selected" :disabled="loading" class="form-check-input m-0" type="checkbox" role="button"
|
||||
:id="`filterTag${tagIndex}`">
|
||||
<label class="form-check-label w-100 ps-3 pe-0 ps-lg-0 pe-lg-3" role="button"
|
||||
:for="`filterTag${tagIndex}`">
|
||||
{{ tag.label }}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -169,9 +169,6 @@
|
|||
</div>
|
||||
</article>
|
||||
<div class="d-flex flex-column m-0">
|
||||
<button class="btn btn-more-products my-3" v-bind:class="[this.productsResults > this.products.length ? 'd-none' : (currentPage > 1) ? 'd-none' : '']" v-on:click="checkScroll()">
|
||||
<i class="fas fa-circle-plus" aria-hidden="true"></i>
|
||||
</button>
|
||||
<p class="fst-italic text-center text-muted" v-bind:class="[(this.productsResults * this.currentPage) <= this.products.length ? 'd-none' : '']" v-on:click="checkScroll()">Tous les produits correspondants à votre recherche sont affichés</p>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -227,6 +224,7 @@
|
|||
this.selectFilters();
|
||||
this.responsiveFilters();
|
||||
this.countResults();
|
||||
this.checkScroll();
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -6,18 +6,18 @@
|
|||
@section('breadcrumb', 'no')
|
||||
|
||||
@section('content')
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-big title-sm-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-5">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</section>
|
||||
@endsection
|
||||
|
|
|
|||
|
|
@ -6,18 +6,18 @@
|
|||
@section('breadcrumb', 'no')
|
||||
|
||||
@section('content')
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-big title-sm-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-5">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</section>
|
||||
@endsection
|
||||
|
|
|
|||
|
|
@ -212,6 +212,10 @@ img {
|
|||
}
|
||||
}
|
||||
|
||||
.accordion-button:not(.collapsed)::after {
|
||||
background-image: var(--bs-accordion-btn-icon) !important;
|
||||
}
|
||||
|
||||
blockquote {
|
||||
background-color: #909090;
|
||||
padding: 1rem;
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@
|
|||
font-size: 5em;
|
||||
}
|
||||
|
||||
.title-medium {
|
||||
.title-medium, .title-sm-medium {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
|
|
@ -185,7 +185,7 @@
|
|||
font-size: 7em;
|
||||
}
|
||||
|
||||
.title-medium {
|
||||
.title-medium, .title-sm-medium {
|
||||
font-size: 1.5em;
|
||||
}
|
||||
}
|
||||
|
|
@ -210,7 +210,7 @@
|
|||
font-size: 7em;
|
||||
}
|
||||
|
||||
.title-medium {
|
||||
.title-medium, .title-sm-medium {
|
||||
font-size: 2em;
|
||||
}
|
||||
}
|
||||
|
|
@ -231,7 +231,7 @@
|
|||
// X:::::X X:::::XL::::::::::::::::::::::L
|
||||
// XXXXXXX XXXXXXXLLLLLLLLLLLLLLLLLLLLLLLL
|
||||
@include media-breakpoint-up(xl) { //1200px
|
||||
.title-medium {
|
||||
.title-medium, .title-sm-medium {
|
||||
font-size: 3em;
|
||||
}
|
||||
|
||||
|
|
@ -260,7 +260,7 @@
|
|||
font-size: 10em;
|
||||
}
|
||||
|
||||
.title-medium {
|
||||
.title-medium, .title-sm-medium {
|
||||
font-size: 4em;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@
|
|||
@import '~bootstrap/scss/forms';
|
||||
@import '~bootstrap/scss/nav';
|
||||
@import '~bootstrap/scss/navbar';
|
||||
@import '~bootstrap/scss/accordion';
|
||||
|
||||
// 5. Optionally include utilities API last to generate classes based on the Sass map in `_utilities.scss`
|
||||
@import "~bootstrap/scss/utilities/api";
|
||||
|
|
|
|||
|
|
@ -6,18 +6,18 @@
|
|||
@section('breadcrumb', 'no')
|
||||
|
||||
@section('content')
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-medium font-Barlow-extra-bold text-uppercase text-grey text-center">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center overflow-hidden">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<section>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<h1 class="title-big title-sm-medium font-Barlow-extra-bold text-uppercase text-grey text-center mt-5">{{ $content->title }}</h1>
|
||||
@if ($content !== null)
|
||||
<div class="row mt-2">
|
||||
<div class="col d-flex flex-column justify-content-center overflow-hidden">
|
||||
{!! clean($content->value) !!}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
</section>
|
||||
@endsection
|
||||
|
|
|
|||
|
|
@ -83,10 +83,6 @@ Breadcrumbs::for('sales.confirm', function ($trail, $reference) {
|
|||
});
|
||||
|
||||
// Catalog.
|
||||
Breadcrumbs::for('ranges', function ($trail) {
|
||||
$trail->parent('home');
|
||||
$trail->push(__('Gammes'), route('ranges'));
|
||||
});
|
||||
Breadcrumbs::for('products', function ($trail) {
|
||||
$trail->parent('home');
|
||||
$trail->push(__('Tous les produits'), route('products'));
|
||||
|
|
@ -95,10 +91,6 @@ Breadcrumbs::for('product', function ($trail, $product) {
|
|||
$trail->parent('products');
|
||||
$trail->push($product->name, route('product', ['productSlug' => $product->slug]));
|
||||
});
|
||||
Breadcrumbs::for('search', function ($trail) {
|
||||
$trail->parent('products');
|
||||
$trail->push(__('Recherche'), route('search'));
|
||||
});
|
||||
|
||||
// Account management.
|
||||
Breadcrumbs::for('account.dashboard', function ($trail) {
|
||||
|
|
|
|||
|
|
@ -4,106 +4,99 @@ use Illuminate\Support\Facades\Route;
|
|||
// AUTH.
|
||||
use App\Http\Controllers\Auth\LoginController;
|
||||
// BO.
|
||||
use App\Http\Controllers\Bo\DashboardController;
|
||||
use App\Http\Controllers\Bo\ContentController;
|
||||
use App\Http\Controllers\Bo\FaqController;
|
||||
use App\Http\Controllers\Bo\SettingsController;
|
||||
use App\Http\Controllers\Bo\OrdersController;
|
||||
use App\Http\Controllers\Bo\CreneauxController;
|
||||
use App\Http\Controllers\Bo\DashboardController;
|
||||
use App\Http\Controllers\Bo\FaqController;
|
||||
use App\Http\Controllers\Bo\MagasinsController;
|
||||
use App\Http\Controllers\Bo\OrdersController;
|
||||
use App\Http\Controllers\Bo\ProductsController;
|
||||
use App\Http\Controllers\Bo\PromotionsController;
|
||||
use App\Http\Controllers\Bo\RangesController;
|
||||
use App\Http\Controllers\Bo\SalariesController;
|
||||
use App\Http\Controllers\Bo\SettingsController;
|
||||
use App\Http\Controllers\Bo\SlidersController;
|
||||
use App\Http\Controllers\Bo\SlidesController;
|
||||
use App\Http\Controllers\Bo\TagsController;
|
||||
use App\Http\Controllers\Bo\SalariesController;
|
||||
|
||||
/*
|
||||
* --------------------------------------------------------------------------
|
||||
* 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!
|
||||
*/
|
||||
|
||||
// Actions sur les comptes utilisateurs.
|
||||
Route::name('auth.')
|
||||
->group(
|
||||
function () {
|
||||
// Bo connect.
|
||||
Route::get('/bo/login', [LoginController::class, 'index'])->name('login')->middleware('guest');
|
||||
Route::post('/bo/login', [LoginController::class, 'login'])->name('login.post')->middleware('guest');
|
||||
Route::get('/bo/logout', [LoginController::class, 'logout'])->name('logout')->middleware('auth:web');
|
||||
}
|
||||
);
|
||||
->group(function () {
|
||||
// Bo connect.
|
||||
Route::get('/bo/login', [LoginController::class, 'index'])->name('login')
|
||||
->middleware('guest');
|
||||
Route::post('/bo/login', [LoginController::class, 'login'])->name('login.post')
|
||||
->middleware('guest');
|
||||
Route::get('/bo/logout', [LoginController::class, 'logout'])->name('logout')
|
||||
->middleware('auth:web');
|
||||
});
|
||||
|
||||
Route::namespace('App\Http\Controllers\Bo')
|
||||
->prefix('bo')
|
||||
Route::prefix('bo')
|
||||
->name('bo.')
|
||||
->middleware(['auth', 'is-admin'])
|
||||
->group(
|
||||
function () {
|
||||
Route::middleware(['is-super-admin'])
|
||||
->group(
|
||||
function () {
|
||||
// Salaries.
|
||||
Route::get('/salaries', [SalariesController::class, 'index'])->name('salaries.index');
|
||||
Route::post('/salaries/file', [SalariesController::class, 'import'])->name('salaries.file');
|
||||
}
|
||||
);
|
||||
Route::get('/', [DashboardController::class, 'index'])->name('dashboard');
|
||||
Route::match(['get', 'put'], '/content/{key}', [ContentController::class, 'manage'])->name('content');
|
||||
Route::match(['get', 'put'], '/settings', [SettingsController::class, 'manage'])->name('settings');
|
||||
Route::match(['get', 'put'], '/themesettings', [SettingsController::class, 'manageTheme'])
|
||||
->name('themesettings');
|
||||
// FAQ.
|
||||
Route::get('/faq', [FaqController::class, 'index'])->name('faq');
|
||||
Route::post('/ajax/save-faq', [FaqController::class, 'saveDatas']);
|
||||
Route::post('/ajax/delete-faq', [FaqController::class, 'destroy']);
|
||||
// Creneaux.
|
||||
Route::get('/magasins/{id}/creneaux', [CreneauxController::class, 'settings'])->name('creneaux.settings');
|
||||
Route::post('/magasins/{id}/creneaux', [CreneauxController::class, 'updateSettings'])
|
||||
->name('creneaux.settings.update');
|
||||
// Exceptions de collecte.
|
||||
Route::post('/ajax/save-creneaux-exception', [MagasinsController::class, 'saveExceptions']);
|
||||
Route::post('/ajax/delete-creneaux-exception', [MagasinsController::class, 'destroyExceptions']);
|
||||
// Recherche d'inco.
|
||||
Route::post('/ajax/check-inco-data', [ProductsController::class, 'checkIncoData']);
|
||||
Route::post('/ajax/get-inco-images', [ProductsController::class, 'getPrepareIncoImages']);
|
||||
Route::post('/ajax/set-inco-images', [ProductsController::class, 'setIncoImage']);
|
||||
// Produits.
|
||||
// Route ajoutée avant la déclaration de route resource.
|
||||
// Sinon la forme /products/{product} l'emporte lors du routage.
|
||||
Route::get('/products/starred', [ProductsController::class, 'starred'])->name('products.starred');
|
||||
Route::get('/products/create/{product_type?}', [ProductsController::class, 'create'])
|
||||
->name('products.create');
|
||||
Route::resource('products', 'ProductsController')->except(['create', 'show']);
|
||||
Route::post('/products/{product}/change-published', [ProductsController::class, 'changePublished'])
|
||||
->name('products.change-published');
|
||||
Route::get('/products/change-order/{product}/{direction}', [ProductsController::class, 'changeOrder'])
|
||||
->where('direction', 'up|down')->name('products.change-order');
|
||||
// Slides.
|
||||
Route::resource('slides', SlidesController::class)->except(['show']);
|
||||
Route::resource('sliders', SlidersController::class)->except(['show']);
|
||||
Route::resource('tags', TagsController::class)->except(['show']);
|
||||
Route::resource('promotions', PromotionsController::class)->except(['show']);
|
||||
Route::resource('magasins', MagasinsController::class)->except(['show']);
|
||||
Route::resources(['ranges' => RangesController::class]);
|
||||
Route::get('/slide/change-order/{id}/{action}', [SlidesController::class, 'changeOrder'])
|
||||
->name('slides.change-order');
|
||||
Route::get('/tag/change-order/{id}/{action}', [TagsController::class, 'changeOrder'])
|
||||
->name('tags.change-order');
|
||||
Route::get('/tag/toggle-status/{id}', [TagsController::class, 'toggleStatus'])->name('tags.toggle-status');
|
||||
Route::get('/customer-info/{id}/{mode?}', [OrdersController::class, 'getCustomerInfo'])
|
||||
->name('get-customer-info');
|
||||
Route::get('/magasin-info/{id}/{mode?}', [MagasinsController::class, 'getMagasinInfo'])
|
||||
->name('get-magasin-info');
|
||||
// Commandes.
|
||||
Route::get('/orders', [OrdersController::class, 'index'])->name('orders');
|
||||
Route::get('/orders/today', [OrdersController::class, 'today'])->name('orders.today');
|
||||
Route::get('/orders/{reference}', [OrdersController::class, 'orderDetail'])->name('order-detail');
|
||||
Route::get('/orders/{reference}/advance', [OrdersController::class, 'changeStatus'])
|
||||
->name('change-order-status');
|
||||
Route::get('/orders/{reference}/cancel', [OrdersController::class, 'cancelOrder'])->name('cancel-order');
|
||||
}
|
||||
);
|
||||
->group(function () {
|
||||
Route::middleware(['is-super-admin'])
|
||||
->group(function () {
|
||||
// Salaries.
|
||||
Route::get('/salaries', [SalariesController::class, 'index'])->name('salaries.index');
|
||||
Route::post('/salaries/file', [SalariesController::class, 'import'])
|
||||
->name('salaries.file');
|
||||
});
|
||||
Route::get('/', [DashboardController::class, 'index'])->name('dashboard');
|
||||
Route::match(['get', 'put'], '/content/{key}', [ContentController::class, 'manage'])
|
||||
->name('content');
|
||||
Route::match(['get', 'put'], '/settings', [SettingsController::class, 'manage'])->name('settings');
|
||||
Route::match(['get', 'put'], '/themesettings', [SettingsController::class, 'manageTheme'])
|
||||
->name('themesettings');
|
||||
// FAQ.
|
||||
Route::get('/faq', [FaqController::class, 'index'])->name('faq');
|
||||
Route::post('/ajax/save-faq', [FaqController::class, 'saveDatas']);
|
||||
Route::post('/ajax/delete-faq', [FaqController::class, 'destroy']);
|
||||
// Creneaux.
|
||||
Route::get('/magasins/{id}/creneaux', [CreneauxController::class, 'settings'])
|
||||
->name('creneaux.settings');
|
||||
Route::post('/magasins/{id}/creneaux', [CreneauxController::class, 'updateSettings'])
|
||||
->name('creneaux.settings.update');
|
||||
// Exceptions de collecte.
|
||||
Route::post('/ajax/save-creneaux-exception', [MagasinsController::class, 'saveExceptions']);
|
||||
Route::post('/ajax/delete-creneaux-exception', [MagasinsController::class, 'destroyExceptions']);
|
||||
// Recherche d'inco.
|
||||
Route::post('/ajax/check-inco-data', [ProductsController::class, 'checkIncoData']);
|
||||
Route::post('/ajax/get-inco-images', [ProductsController::class, 'getPrepareIncoImages']);
|
||||
Route::post('/ajax/set-inco-images', [ProductsController::class, 'setIncoImage']);
|
||||
// Produits.
|
||||
// Route ajoutée avant la déclaration de route resource.
|
||||
// Sinon la forme /products/{product} l'emporte lors du routage.
|
||||
Route::get('/products/starred', [ProductsController::class, 'starred'])->name('products.starred');
|
||||
Route::get('/products/create/{product_type?}', [ProductsController::class, 'create'])
|
||||
->name('products.create');
|
||||
Route::resource('products', ProductsController::class)->except(['create', 'show']);
|
||||
Route::post('/products/{product}/change-published', [ProductsController::class, 'changePublished'])
|
||||
->name('products.change-published');
|
||||
Route::get('/products/change-order/{product}/{direction}', [ProductsController::class, 'changeOrder'])
|
||||
->where('direction', 'up|down')->name('products.change-order');
|
||||
// Slides.
|
||||
Route::resource('slides', SlidesController::class)->except(['show']);
|
||||
Route::resource('sliders', SlidersController::class)->except(['show']);
|
||||
Route::resource('tags', TagsController::class)->except(['show']);
|
||||
Route::resource('promotions', PromotionsController::class)->except(['show']);
|
||||
Route::resource('magasins', MagasinsController::class)->except(['show']);
|
||||
Route::resources(['ranges' => RangesController::class]);
|
||||
Route::get('/slide/change-order/{id}/{action}', [SlidesController::class, 'changeOrder'])
|
||||
->name('slides.change-order');
|
||||
Route::get('/tag/change-order/{id}/{action}', [TagsController::class, 'changeOrder'])
|
||||
->name('tags.change-order');
|
||||
Route::get('/tag/toggle-status/{id}', [TagsController::class, 'toggleStatus'])
|
||||
->name('tags.toggle-status');
|
||||
Route::get('/customer-info/{id}/{mode?}', [OrdersController::class, 'getCustomerInfo'])
|
||||
->name('get-customer-info');
|
||||
Route::get('/magasin-info/{id}/{mode?}', [MagasinsController::class, 'getMagasinInfo'])
|
||||
->name('get-magasin-info');
|
||||
// Commandes.
|
||||
Route::get('/orders', [OrdersController::class, 'index'])->name('orders');
|
||||
Route::get('/orders/today', [OrdersController::class, 'today'])->name('orders.today');
|
||||
Route::get('/orders/{reference}', [OrdersController::class, 'orderDetail'])->name('order-detail');
|
||||
Route::get('/orders/{reference}/advance', [OrdersController::class, 'changeStatus'])
|
||||
->name('change-order-status');
|
||||
Route::get('/orders/{reference}/cancel', [OrdersController::class, 'cancelOrder'])
|
||||
->name('cancel-order');
|
||||
});
|
||||
|
|
|
|||
|
|
@ -1,30 +1,17 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Route;
|
||||
// FRONT.
|
||||
// FO.
|
||||
use App\Http\Controllers\IndexController;
|
||||
use App\Http\Controllers\CustomerController;
|
||||
use App\Http\Controllers\OrderTunnelController;
|
||||
// FRONT.
|
||||
use App\Http\Controllers\HomeController;
|
||||
use App\Http\Controllers\BasketController;
|
||||
use App\Http\Controllers\ProductsController;
|
||||
use App\Http\Controllers\ContactController;
|
||||
|
||||
/*
|
||||
* --------------------------------------------------------------------------
|
||||
* 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!
|
||||
*/
|
||||
|
||||
// Actions sur les comptes utilisateurs.
|
||||
Route::name('auth.')
|
||||
->group(
|
||||
function () {
|
||||
->group(function () {
|
||||
// Customer connect.
|
||||
Route::get('/connexion', [CustomerController::class, 'authenticateForm'])->name('connexion')
|
||||
->middleware('guest');
|
||||
|
|
@ -48,14 +35,12 @@ Route::name('auth.')
|
|||
// Changement en crm.
|
||||
Route::post('/reinitialiser-mdp/{token}', [CustomerController::class, 'changePassword'])
|
||||
->name('change-password');
|
||||
}
|
||||
);
|
||||
});
|
||||
|
||||
Route::name('account.')
|
||||
->prefix('compte')
|
||||
->middleware('auth:customer')
|
||||
->group(
|
||||
function () {
|
||||
->prefix('compte')
|
||||
->middleware('auth:customer')
|
||||
->group(function () {
|
||||
Route::get('/profil', [CustomerController::class, 'dashboard'])->name('dashboard');
|
||||
Route::post('/profil', [CustomerController::class, 'updateInfos'])->name('update-infos');
|
||||
Route::post(
|
||||
|
|
@ -64,8 +49,7 @@ Route::name('account.')
|
|||
)->name('change-password');
|
||||
Route::get('/commandes', [CustomerController::class, 'myOrders'])->name('my-orders');
|
||||
Route::get('/commandes/{reference}', [CustomerController::class, 'orderDetail'])->name('order-detail');
|
||||
}
|
||||
);
|
||||
});
|
||||
|
||||
// Tunnel de commande.
|
||||
Route::prefix('commande')
|
||||
|
|
@ -88,25 +72,13 @@ Route::get('/', [HomeController::class, 'index'])->name('home');
|
|||
Route::get('/cgv', [IndexController::class, 'terms'])->name('terms');
|
||||
Route::get('/faq', [IndexController::class, 'faq'])->name('faq');
|
||||
|
||||
// Catalogue.
|
||||
Route::get('/gammes-de-produits', [ProductsController::class, 'allProductsFiltered'])->name('ranges');
|
||||
Route::get('/gamme-de-produits/{rangeSlug}', [ProductsController::class, 'range'])->name('range')
|
||||
->middleware('redirect-slugs');
|
||||
|
||||
// Products display.
|
||||
Route::get('/produits/{filtersMenuIsOpen?}', [ProductsController::class, 'allProductsFiltered'])->name('products');
|
||||
Route::get('/recherche', [ProductsController::class, 'allProductsFiltered'])->name('search');
|
||||
|
||||
// Products filter ajax.
|
||||
Route::get('/produits/filter', [ProductsController::class, 'allProductsFiltered'])->name('products.filters');
|
||||
|
||||
// Product.
|
||||
Route::get('/produit/{productSlug}', [ProductsController::class, 'product'])->name('product')
|
||||
->middleware('redirect-slugs');
|
||||
|
||||
// Route ajax pour Single Optin.
|
||||
Route::post('/optin', [HomeController::class, 'addOptIn'])->name('add-single-optin');
|
||||
|
||||
// Contact.
|
||||
Route::get('/contactez-nous', [ContactController::class, 'contact'])->name('contact');
|
||||
Route::post('/contactez-nous', [ContactController::class, 'contactSubmit'])->name('contact-us.submit');
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue