2018-09-25 12:30:50 +01:00
|
|
|
<?php namespace BookStack\Actions;
|
|
|
|
|
|
|
|
use BookStack\Model;
|
2016-05-06 20:33:08 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Class Attribute
|
|
|
|
* @package BookStack
|
|
|
|
*/
|
2016-05-13 21:20:21 +01:00
|
|
|
class Tag extends Model
|
2016-05-06 20:33:08 +01:00
|
|
|
{
|
2016-05-12 23:12:05 +01:00
|
|
|
protected $fillable = ['name', 'value', 'order'];
|
2016-05-06 20:33:08 +01:00
|
|
|
|
|
|
|
/**
|
2016-05-13 21:20:21 +01:00
|
|
|
* Get the entity that this tag belongs to
|
2016-05-06 20:33:08 +01:00
|
|
|
* @return \Illuminate\Database\Eloquent\Relations\MorphTo
|
|
|
|
*/
|
|
|
|
public function entity()
|
|
|
|
{
|
|
|
|
return $this->morphTo('entity');
|
|
|
|
}
|
2018-01-28 16:58:52 +00:00
|
|
|
}
|