Update with new price management

This commit is contained in:
Ludovic CANDELLIER
2021-03-22 00:47:44 +01:00
parent 083d358fbd
commit 37ffaa938b
64 changed files with 1118 additions and 984 deletions

View File

@@ -3,9 +3,12 @@
namespace App\Models\Shop;
use Illuminate\Database\Eloquent\Model;
use Staudenmeir\EloquentHasManyDeep\HasRelationships;
class ArticleFamily extends Model
{
use HasRelationships;
protected $guarded = ['id'];
protected $table = 'shop_article_families';
@@ -13,4 +16,14 @@ class ArticleFamily extends Model
{
return $this->hasMany('App\Models\Shop\Article');
}
public function prices()
{
return $this->hasMany('App\Models\Shop\Price');
}
public function unities()
{
return $this->hasMany('App\Models\Shop\Unity');
}
}