¨4.0.1¨
This commit is contained in:
@@ -27,21 +27,25 @@ class ProductAttributeValue extends Model
|
||||
*/
|
||||
protected $appends = ['value'];
|
||||
|
||||
|
||||
public function exists()
|
||||
{
|
||||
return ! is_null($this->attributeValue);
|
||||
return !is_null($this->attributeValue);
|
||||
}
|
||||
|
||||
|
||||
public function attributeValue()
|
||||
{
|
||||
return $this->belongsTo(AttributeValue::class, 'attribute_value_id');
|
||||
}
|
||||
|
||||
|
||||
public function getIdAttribute()
|
||||
{
|
||||
return $this->attributeValue->id;
|
||||
}
|
||||
|
||||
|
||||
public function getValueAttribute()
|
||||
{
|
||||
return $this->attributeValue->value;
|
||||
|
||||
Reference in New Issue
Block a user