17 Nov - Static Sites to laravel

This commit is contained in:
Kevin Adametz 2018-11-17 02:01:22 +01:00
parent 610aa1e202
commit 5ff57a21a7
3661 changed files with 569001 additions and 771 deletions

View file

@ -2,6 +2,7 @@
namespace App\Models;
use Cviebrock\EloquentSluggable\Sluggable;
use Illuminate\Database\Eloquent\Model;
/**
@ -32,12 +33,24 @@ use Illuminate\Database\Eloquent\Model;
*/
class ProductImage extends Model
{
use Sluggable;
protected $table = 'product_images';
protected $fillable = [
'product_id', 'filename', 'original_name', 'ext', 'mine', 'size'
];
public function sluggable()
{
return [
'slug' => [
'source' => 'original_name'
]
];
}
public function product()
{