| Total Complexity | 3 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 5 | trait Lincable |
||
| 6 | { |
||
| 7 | /** |
||
| 8 | * Boot the model statically. |
||
| 9 | * |
||
| 10 | * @return void |
||
| 11 | */ |
||
| 12 | public static function bootLincable() |
||
| 16 | }); |
||
| 17 | } |
||
| 18 | |||
| 19 | /** |
||
| 20 | * Add the lincable fields to model fillables. |
||
| 21 | * |
||
| 22 | * @return void |
||
| 23 | */ |
||
| 24 | public function addLincableFields() |
||
| 25 | { |
||
| 26 | $this->fillable(array_merge( |
||
|
|
|||
| 27 | $this->getFillable(), |
||
| 28 | $this->getLincableFields() |
||
| 29 | )); |
||
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * Return the fields to link the model. |
||
| 34 | * |
||
| 35 | * @return array |
||
| 36 | */ |
||
| 37 | public function getLincableFields() |
||
| 42 | ]; |
||
| 43 | } |
||
| 44 | } |