| 1 | <?php namespace Arcanedev\LaravelSeo\Traits; |
||
| 13 | trait Seoable |
||
| 14 | { |
||
| 15 | /* ------------------------------------------------------------------------------------------------ |
||
| 16 | | Relationships |
||
| 17 | | ------------------------------------------------------------------------------------------------ |
||
| 18 | */ |
||
| 19 | /** |
||
| 20 | * SEO relationship. |
||
| 21 | * |
||
| 22 | * @return \Illuminate\Database\Eloquent\Relations\MorphOne |
||
| 23 | */ |
||
| 24 | 36 | public function seo() |
|
| 28 | |||
| 29 | /* ------------------------------------------------------------------------------------------------ |
||
| 30 | | Main Functions |
||
| 31 | | ------------------------------------------------------------------------------------------------ |
||
| 32 | */ |
||
| 33 | /** |
||
| 34 | * Create a seo. |
||
| 35 | * |
||
| 36 | * @param array $attributes |
||
| 37 | * |
||
| 38 | * @return \Arcanedev\LaravelSeo\Models\Seo |
||
| 39 | */ |
||
| 40 | 36 | public function createSeo(array $attributes) |
|
| 44 | |||
| 45 | /** |
||
| 46 | * Update a seo. |
||
| 47 | * |
||
| 48 | * @param array $attributes |
||
| 49 | * |
||
| 50 | * @return bool |
||
| 51 | */ |
||
| 52 | 9 | public function updateSeo(array $attributes) |
|
| 56 | |||
| 57 | /** |
||
| 58 | * Delete a seo. |
||
| 59 | * |
||
| 60 | * @return bool|null |
||
| 61 | */ |
||
| 62 | 9 | public function deleteSeo() |
|
| 66 | |||
| 67 | /** |
||
| 68 | * Check if it has seo. |
||
| 69 | * |
||
| 70 | * @return bool |
||
| 71 | */ |
||
| 72 | 36 | public function hasSeo() |
|
| 76 | } |
||
| 77 |