diff --git a/packages/Webkul/Product/src/Models/Product.php b/packages/Webkul/Product/src/Models/Product.php index 248ab4efc..c29e47110 100755 --- a/packages/Webkul/Product/src/Models/Product.php +++ b/packages/Webkul/Product/src/Models/Product.php @@ -285,4 +285,12 @@ class Product extends Model implements ProductContract return new \Webkul\Product\Database\Eloquent\Builder($query); } + /** + * Return the product id attribute. + */ + public function getProductIdAttribute() + { + return $image = $this->id; + } + } \ No newline at end of file diff --git a/packages/Webkul/Shop/src/Resources/views/products/add-buttons.blade.php b/packages/Webkul/Shop/src/Resources/views/products/add-buttons.blade.php index d54a36796..22c22ef3a 100644 --- a/packages/Webkul/Shop/src/Resources/views/products/add-buttons.blade.php +++ b/packages/Webkul/Shop/src/Resources/views/products/add-buttons.blade.php @@ -1,6 +1,4 @@ -@if (Route::currentRouteName() == "shop.products.index") - @include ('shop::products.add-to', ['product' => $product]) -@else + @if ($product->type == "configurable")
@@ -21,5 +19,4 @@ @include('shop::products.wishlist')
- @endif -@endif \ No newline at end of file + @endif \ No newline at end of file