delboy1978uk /
country
| 1 | <?php |
||
| 2 | |||
| 3 | declare(strict_types=1); |
||
| 4 | |||
| 5 | namespace Del\Traits; |
||
| 6 | |||
| 7 | use Bone\BoneDoctrine\Attributes\Visibility; |
||
|
0 ignored issues
–
show
|
|||
| 8 | use Del\Entity\Country; |
||
| 9 | use Del\Factory\CountryFactory; |
||
| 10 | use Del\Form\Field\Attributes\Field; |
||
| 11 | use Del\Form\Field\CountrySelect; |
||
| 12 | use Doctrine\ORM\Mapping as ORM; |
||
|
0 ignored issues
–
show
The type
Doctrine\ORM\Mapping was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths Loading history...
|
|||
| 13 | |||
| 14 | trait HasCountryTrait |
||
| 15 | { |
||
| 16 | #[ORM\Column(type: 'string', length:3, nullable: false)] |
||
| 17 | #[Field(rules: 'custom', fieldClass: CountrySelect::class)] |
||
| 18 | #[Visibility('all')] |
||
| 19 | private string $country; |
||
| 20 | |||
| 21 | public function getCountry(): Country |
||
| 22 | { |
||
| 23 | return CountryFactory::generate($this->country); |
||
| 24 | } |
||
| 25 | |||
| 26 | public function setCountry(Country $country): void |
||
| 27 | { |
||
| 28 | $this->country = $country->getIso(); |
||
| 29 | } |
||
| 30 | } |
||
| 31 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths