Attribute.php 384 B

123456789101112131415161718192021
  1. <?php
  2. namespace App\Shop\Attributes;
  3. use App\Shop\AttributeValues\AttributeValue;
  4. use Illuminate\Database\Eloquent\Model;
  5. class Attribute extends Model
  6. {
  7. protected $fillable = [
  8. 'name'
  9. ];
  10. /**
  11. * @return \Illuminate\Database\Eloquent\Relations\HasMany
  12. */
  13. public function values()
  14. {
  15. return $this->hasMany(AttributeValue::class);
  16. }
  17. }