commit
563b558ad9
|
|
@ -315,4 +315,50 @@ Route::group(['middleware' => ['web']], function () {
|
|||
])->name('admin.sliders.store');
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
//customer routes starts here
|
||||
Route::prefix('customer')->group(function () {
|
||||
|
||||
// Login Routes
|
||||
Route::get('login', 'Webkul\Customer\Http\Controllers\SessionController@show')->defaults('_config', [
|
||||
'view' => 'shop::customers.session.index',
|
||||
])->name('customer.session.index');
|
||||
|
||||
Route::post('login', 'Webkul\Customer\Http\Controllers\SessionController@create')->defaults('_config', [
|
||||
'redirect' => 'customer.account.profile'
|
||||
])->name('customer.session.create');
|
||||
|
||||
|
||||
// Registration Routes
|
||||
Route::get('register', 'Webkul\Customer\Http\Controllers\RegistrationController@show')->defaults('_config', [
|
||||
'view' => 'shop::customers.signup.index' //hint path
|
||||
])->name('customer.register.index');
|
||||
|
||||
Route::post('register', 'Webkul\Customer\Http\Controllers\RegistrationController@create')->defaults('_config', [
|
||||
'redirect' => 'customer.account.profile',
|
||||
])->name('customer.register.create'); //redirect attribute will get changed immediately to account.index when account's index page will be made
|
||||
|
||||
// Auth Routes
|
||||
Route::group(['middleware' => ['customer']], function () {
|
||||
|
||||
//route for logout which will be under the auth guard of the customer by default
|
||||
Route::get('logout', 'Webkul\Customer\Http\Controllers\SessionController@destroy')->defaults('_config', [
|
||||
'redirect' => 'customer.session.index'
|
||||
])->name('customer.session.destroy');
|
||||
|
||||
//customer account
|
||||
Route::prefix('account')->group(function () {
|
||||
Route::get('profile', 'Webkul\Customer\Http\Controllers\CustomerController@profile')->defaults('_config', [
|
||||
'view' => 'shop::customers.account.profile.home.index'
|
||||
])->name('customer.account.profile');
|
||||
|
||||
//profile edit
|
||||
Route::get('profile/edit', 'Webkul\Customer\Http\Controllers\CustomerController@editProfile')->defaults('_config', [
|
||||
'view' => 'shop::customers.account.profile.edit.index'
|
||||
])->name('customer.profile.edit');
|
||||
});
|
||||
});
|
||||
});
|
||||
//customer routes end here
|
||||
});
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ class CreateCustomersTable extends Migration
|
|||
$table->string('first_name');
|
||||
$table->string('last_name');
|
||||
$table->enum('gender', ['Male', 'Female']);
|
||||
$table->date('date_of_birth');
|
||||
$table->date('date_of_birth')->nullable();
|
||||
$table->string('phone')->unique()->nullable();
|
||||
$table->string('email')->unique();
|
||||
$table->string('password');
|
||||
|
|
|
|||
|
|
@ -1,46 +0,0 @@
|
|||
<?php
|
||||
|
||||
Route::group(['middleware' => ['web']], function () {
|
||||
Route::prefix('customer')->group(function () {
|
||||
|
||||
// Login Routes
|
||||
Route::get('login', 'Webkul\Customer\Http\Controllers\SessionController@show')->defaults('_config', [
|
||||
'view' => 'shop::customers.session.index',
|
||||
])->name('customer.session.index');
|
||||
|
||||
Route::post('login', 'Webkul\Customer\Http\Controllers\SessionController@create')->defaults('_config', [
|
||||
'redirect' => 'customer.account.profile'
|
||||
])->name('customer.session.create');
|
||||
|
||||
|
||||
// Registration Routes
|
||||
Route::get('register', 'Webkul\Customer\Http\Controllers\RegistrationController@show')->defaults('_config', [
|
||||
'view' => 'shop::customers.signup.index' //hint path
|
||||
])->name('customer.register.index');
|
||||
|
||||
Route::post('register', 'Webkul\Customer\Http\Controllers\RegistrationController@create')->defaults('_config', [
|
||||
'redirect' => 'customer.account.profile',
|
||||
])->name('customer.register.create'); //redirect attribute will get changed immediately to account.index when account's index page will be made
|
||||
|
||||
// Auth Routes
|
||||
Route::group(['middleware' => ['customer']], function () {
|
||||
|
||||
//route for logout which will be under the auth guard of the customer by default
|
||||
Route::get('logout', 'Webkul\Customer\Http\Controllers\SessionController@destroy')->defaults('_config', [
|
||||
'redirect' => 'customer.session.index'
|
||||
])->name('customer.session.destroy');
|
||||
|
||||
//customer account
|
||||
Route::prefix('account')->group(function () {
|
||||
Route::get('profile', 'Webkul\Customer\Http\Controllers\CustomerController@profile')->defaults('_config', [
|
||||
'view' => 'shop::customers.account.profile.home.index'
|
||||
])->name('customer.account.profile');
|
||||
|
||||
//profile edit
|
||||
Route::get('profile/edit', 'Webkul\Customer\Http\Controllers\CustomerController@editProfile')->defaults('_config', [
|
||||
'view' => 'shop::customers.account.profile.edit.index'
|
||||
])->name('customer.profile.edit');
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
@ -13,7 +13,7 @@ class CustomerServiceProvider extends ServiceProvider
|
|||
{
|
||||
public function boot(Router $router)
|
||||
{
|
||||
include __DIR__ . '/../Http/routes.php';
|
||||
// include __DIR__ . '/../Http/routes.php';
|
||||
|
||||
$this->publishes([
|
||||
__DIR__ . '/../../publishable/assets' => public_path('vendor/webkul/customer/assets'),
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<li>
|
||||
<a href="">{{ this.item['translations'][0].name }} <i class="icon dropdown-right-icon"
|
||||
v-if="haveChildren"></i></a>
|
||||
v-if="haveChildren && item.parent_id != null"></i></a>
|
||||
<ul v-if="haveChildren">
|
||||
<category-item
|
||||
v-for="(child, index) in item.children"
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@
|
|||
v-for="(item, index) in items"
|
||||
:key="index"
|
||||
:url="url"
|
||||
:item="item">
|
||||
:item="item"
|
||||
:parent="index">
|
||||
</category-item>
|
||||
<li>
|
||||
<img src="vendor/webkul/shop/assets/images/offer-zone.svg"/>
|
||||
|
|
|
|||
|
|
@ -214,6 +214,7 @@ body {
|
|||
.nav > li {
|
||||
float: left;
|
||||
margin-right: 1px;
|
||||
|
||||
}
|
||||
|
||||
.nav > li > a {
|
||||
|
|
@ -267,7 +268,7 @@ body {
|
|||
.nav > li li:hover > ul {
|
||||
left: 100%;
|
||||
margin-left: 1px;
|
||||
top: -1px;
|
||||
top: -2px;
|
||||
}
|
||||
|
||||
.nav > li:hover > a:first-child:nth-last-child(2):before {
|
||||
|
|
@ -281,6 +282,7 @@ body {
|
|||
.nav li li:hover > a:first-child:nth-last-child(2):before {
|
||||
right: 10px;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -36,13 +36,13 @@
|
|||
|
||||
<div class="control-group" :class="[errors.has('password') ? 'has-error' : '']">
|
||||
<label for="password">{{ __('shop::app.customer.signup-form.password') }}</label>
|
||||
<input type="password" class="control" name="password" v-validate="'required|min:8'" ref="password">
|
||||
<input type="password" class="control" name="password" v-validate="'required|min:6'" ref="password">
|
||||
<span class="control-error" v-if="errors.has('password')">@{{ errors.first('password') }}</span>
|
||||
</div>
|
||||
|
||||
<div class="control-group" :class="[errors.has('confirm_password') ? 'has-error' : '']">
|
||||
<label for="confirm_password">{{ __('shop::app.customer.signup-form.confirm_pass') }}</label>
|
||||
<input type="password" class="control" name="confirm_password" v-validate="'required|min:8|confirm:$password'">
|
||||
<input type="password" class="control" name="password_confirmation" v-validate="'required|min:6|confirmed:password'">
|
||||
<span class="control-error" v-if="errors.has('confirm_password')">@{{ errors.first('confirm_password') }}</span>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -332,7 +332,7 @@ body {
|
|||
.header .header-bottom .nav > li li:hover > ul {
|
||||
left: 100%;
|
||||
margin-left: 1px;
|
||||
top: -1px;
|
||||
top: -2px;
|
||||
}
|
||||
|
||||
.header .header-bottom .nav > li:hover > a:first-child:nth-last-child(2):before {
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue