Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Darko 2020-10-10 14:55:14 +02:00
commit 44ffada8a8
13 changed files with 128 additions and 24 deletions

View File

@ -158,13 +158,13 @@ return [
'name' => 'no_of_new_product_homepage',
'title' => 'admin::app.admin.system.allow-no-of-new-product-homepage',
'type' => 'number',
'validation' => 'required|min:0',
'validation' => 'min:0',
],
[
'name' => 'no_of_featured_product_homepage',
'title' => 'admin::app.admin.system.allow-no-of-featured-product-homepage',
'type' => 'number',
'validation' => 'required|min:0',
'validation' => 'min:0',
],
],
], [

View File

@ -0,0 +1,56 @@
<?php
namespace Webkul\Category\Database\Seeders;
use Faker\Generator as Faker;
use Illuminate\Database\Seeder;
use Webkul\Category\Repositories\CategoryRepository;
/*
* CategoryBulkTableSeeder
*
* Command: php artisan db:seed --class=Webkul\\Category\\Database\\Seeders\\CategoryBulkTableSeeder
*
* This seeder has not included anywhere just for development purpose.
*/
class CategoryBulkTableSeeder extends Seeder
{
private $numberOfParentCategories = 10;
private $numberOfChildCategories = 50;
public function __construct(
Faker $faker,
CategoryRepository $categoryRepository
)
{
$this->faker = $faker;
$this->categoryRepository = $categoryRepository;
}
public function run()
{
for ($i = 0; $i < $this->numberOfParentCategories; ++$i) {
$createdCategory = $this->categoryRepository->create([
'slug' => $this->faker->slug,
'name' => $this->faker->firstName,
'description' => $this->faker->text(),
'parent_id' => 1,
'status' => 1,
]);
if ($createdCategory) {
for ($j = 0; $j < $this->numberOfChildCategories; ++$j) {
$this->categoryRepository->create([
'slug' => $this->faker->slug,
'name' => $this->faker->firstName,
'description' => $this->faker->text(),
'parent_id' => $createdCategory->id,
'status' => 1
]);
}
}
}
}
}

View File

@ -163,7 +163,7 @@
var wishlist = " <?php echo $wishListHelper->getWishlistProduct($product); ?> ";
$(document).mousemove(function(event) {
if ($('.add-to-wishlist').length && wishlist != 1) {
if ($('.add-to-wishlist').length || wishlist != 1) {
if (event.pageX > $('.add-to-wishlist').offset().left && event.pageX < $('.add-to-wishlist').offset().left+32 && event.pageY > $('.add-to-wishlist').offset().top && event.pageY < $('.add-to-wishlist').offset().top+32) {
$(".zoomContainer").addClass("show-wishlist");

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,5 +1,5 @@
{
"/js/velocity.js": "/js/velocity.js?id=4f93a5fcaa9e170dd72f",
"/js/velocity.js": "/js/velocity.js?id=c4d3d75a0e1999b9baad",
"/css/velocity-admin.css": "/css/velocity-admin.css?id=4322502d80a0e4a0affd",
"/css/velocity.css": "/css/velocity.css?id=ef3e2ae913e88dcaa09d"
"/css/velocity.css": "/css/velocity.css?id=a37ae1fb6f34223126b8"
}

View File

@ -1,9 +1,25 @@
<template>
<form method="POST" @submit.prevent="addToCart">
<!-- for move to cart from wishlist -->
<a
:href="wishlistMoveRoute"
:disabled="isButtonEnable == 'false' || isButtonEnable == false"
:class="`btn btn-add-to-cart ${addClassToBtn}`"
v-if="moveToCart"
>
<i class="material-icons text-down-3" v-if="showCartIcon">shopping_cart</i>
<span class="fs14 fw6 text-uppercase text-up-4" v-text="btnText"></span>
</a>
<!-- for add to cart -->
<button
type="submit"
:disabled="isButtonEnable == 'false' || isButtonEnable == false"
:class="`btn btn-add-to-cart ${addClassToBtn}`">
:class="`btn btn-add-to-cart ${addClassToBtn}`"
v-else
>
<i class="material-icons text-down-3" v-if="showCartIcon">shopping_cart</i>
@ -22,6 +38,7 @@
'productId',
'reloadPage',
'moveToCart',
'wishlistMoveRoute',
'showCartIcon',
'addClassToBtn',
'productFlatId',

View File

@ -1861,6 +1861,7 @@
background: $light-color;
border-left: 1px solid $border-common;
box-shadow: 0 10px 20px rgba(0,0,0,0.19), 0 6px 6px rgba(0,0,0,0.23);
overflow-y: auto;
li:nth-last-of-type(1) {
margin-bottom: 10px;

View File

@ -721,6 +721,7 @@ body::after {
.description-text {
word-break: break-word;
overflow: auto;
}
}

View File

@ -107,7 +107,7 @@
type="search"
class="form-control"
placeholder="{{ __('velocity::app.header.search-text') }}"
:value="searchedQuery.term ? searchedQuery.term.split('+').join(' ') : ''" />
:value="searchedQuery.term ? decodeURIComponent(searchedQuery.term.split('+').join(' ')) : ''" />
<image-search-component></image-search-component>

View File

@ -23,7 +23,7 @@
{!! view_render_event('bagisto.shop.customers.account.wishlist.list.before', ['wishlist' => $items]) !!}
<div class="account-items-list row wishlist-container">
<div class="wishlist-container">
@if ($items->count())
@foreach ($items as $item)
@ -33,19 +33,22 @@
@endphp
@include ('shop::products.list.card', [
'checkmode' => true,
'moveToCart' => true,
'addToCartForm' => true,
'removeWishlist' => true,
'reloadPage' => true,
'itemId' => $item->id,
'product' => $item->product,
'btnText' => $moveToCartText,
'addToCartBtnClass' => 'small-padding',
'list' => true,
'checkmode' => true,
'moveToCart' => true,
'wishlistMoveRoute' => route('customer.wishlist.move', $item->id),
'addToCartForm' => true,
'removeWishlist' => true,
'reloadPage' => true,
'itemId' => $item->id,
'product' => $item->product,
'additionalAttributes' => true,
'btnText' => $moveToCartText,
'addToCartBtnClass' => 'small-padding',
])
@endforeach
<div class="bottom-toolbar">
<div>
{{ $items->links() }}
</div>
@else

View File

@ -67,10 +67,11 @@
product-id="{{ $product->product_id }}"
reload-page="{{ $reloadPage ?? false }}"
move-to-cart="{{ $moveToCart ?? false }}"
wishlist-move-route="{{ $wishlistMoveRoute ?? false }}"
add-class-to-btn="{{ $addToCartBtnClass ?? '' }}"
is-enable={{ ! $product->isSaleable() ? 'false' : 'true' }}
show-cart-icon={{ !(isset($showCartIcon) && !$showCartIcon) }}
btn-text="{{ ($product->type == 'booking') ? __('shop::app.products.book-now') : $btnText ?? __('shop::app.products.add-to-cart') }}">
show-cart-icon={{ ! (isset($showCartIcon) && ! $showCartIcon) }}
btn-text="{{ (! isset($moveToCart) && $product->type == 'booking') ? __('shop::app.products.book-now') : $btnText ?? __('shop::app.products.add-to-cart') }}">
</add-to-cart>
@endif
</div>

View File

@ -26,7 +26,7 @@
$galleryImages = $productImageHelper->getGalleryImages($product);
$priceHTML = view('shop::products.price', ['product' => $product])->render();
$product->__set('priceHTML', $priceHTML);
$product->__set('avgRating', $avgRatings);
$product->__set('totalReviews', $totalReviews);
@ -73,6 +73,18 @@
<span class="fs16">{{ $product->name }}</span>
</a>
@if (isset($additionalAttributes) && $additionalAttributes)
@if (isset($item->additional['attributes']))
<div class="item-options">
@foreach ($item->additional['attributes'] as $attribute)
<b>{{ $attribute['attribute_name'] }} : </b>{{ $attribute['option_label'] }}</br>
@endforeach
</div>
@endif
@endif
</div>
<div class="product-price">
@ -115,7 +127,7 @@
{{-- <product-quick-view-btn :quick-view-details="product"></product-quick-view-btn> --}}
<product-quick-view-btn :quick-view-details="{{ json_encode($product) }}"></product-quick-view-btn>
</a>
@if ($product->new)
<div class="sticker new">
{{ __('shop::app.products.new') }}
@ -130,6 +142,18 @@
class="unset">
<span class="fs16">{{ $product->name }}</span>
@if (isset($additionalAttributes) && $additionalAttributes)
@if (isset($item->additional['attributes']))
<div class="item-options">
@foreach ($item->additional['attributes'] as $attribute)
<b>{{ $attribute['attribute_name'] }} : </b>{{ $attribute['option_label'] }}</br>
@endforeach
</div>
@endif
@endif
</a>
</div>
@ -155,6 +179,7 @@
'product' => $product,
'btnText' => $btnText ?? null,
'moveToCart' => $moveToCart ?? null,
'wishlistMoveRoute' => $wishlistMoveRoute ?? null,
'reloadPage' => $reloadPage ?? null,
'addToCartForm' => $addToCartForm ?? false,
'addToCartBtnClass' => $addToCartBtnClass ?? '',