add seo
This commit is contained in:
@@ -3,11 +3,9 @@
|
||||
namespace App\Repositories\Shop;
|
||||
|
||||
use App\Models\Shop\Article;
|
||||
use App\Models\Shop\Merchandise;
|
||||
use App\Repositories\Botanic\Species;
|
||||
use App\Repositories\Botanic\Varieties;
|
||||
use App\Repositories\Core\Comments;
|
||||
use App\Repositories\Core\Tag;
|
||||
use App\Traits\Model\Basic;
|
||||
use App\Traits\Repository\Imageable;
|
||||
use Illuminate\Support\Str;
|
||||
@@ -27,6 +25,11 @@ class Articles
|
||||
return $export;
|
||||
}
|
||||
|
||||
public static function getIDBySlug($slug)
|
||||
{
|
||||
return Article::bySlug($slug)->first()->id;
|
||||
}
|
||||
|
||||
public static function getOffersGroupedByNature($id, $saleChannelId = false)
|
||||
{
|
||||
$articleIds = ArticleSiblings::getSiblingsIds($id);
|
||||
@@ -178,6 +181,7 @@ class Articles
|
||||
'product_name' => $article->product->name,
|
||||
'parent_name' => trim(str_replace($article->product->name, '', $article->name)),
|
||||
'offers' => $article->offers->toArray(),
|
||||
'slug' => $article->slug,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user