We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| Conditions | 6 |
| Paths | 5 |
| Total Lines | 14 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 11 | public static function getDefault(SmartCollectionInterface $attributes) |
||
| 12 | { |
||
| 13 | if (backpack_pro() && $attributes->getAttributeValue('relation_type')) { |
||
| 14 | return 'relationship'; |
||
| 15 | } |
||
| 16 | |||
| 17 | switch ($attributes->getAttributeValue('relation_type')) { |
||
| 18 | case 'BelongsTo': |
||
| 19 | return 'select'; |
||
| 20 | case 'BelongsToMany': |
||
| 21 | case 'MorphToMany': |
||
| 22 | return 'select_multiple'; |
||
| 23 | default: |
||
| 24 | return 'text'; |
||
| 25 | } |
||
| 38 |