|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
namespace ControleOnline\Entity\Particulars; |
|
4
|
|
|
|
|
5
|
|
|
use ApiPlatform\Metadata\GetCollection; |
|
|
|
|
|
|
6
|
|
|
use ApiPlatform\Metadata\Get; |
|
|
|
|
|
|
7
|
|
|
use ApiPlatform\Metadata\ApiResource; |
|
|
|
|
|
|
8
|
|
|
use ApiPlatform\Metadata\ApiProperty; |
|
|
|
|
|
|
9
|
|
|
use ApiPlatform\Metadata\ApiFilter; |
|
|
|
|
|
|
10
|
|
|
use Doctrine\ORM\Mapping as ORM; |
|
|
|
|
|
|
11
|
|
|
use Symfony\Component\Serializer\Annotation\Groups; |
|
|
|
|
|
|
12
|
|
|
/** |
|
13
|
|
|
* @ORM\EntityListeners ({App\Listener\LogListener::class}) |
|
14
|
|
|
* @ORM\Table (name="particulars") |
|
15
|
|
|
* @ORM\Entity (repositoryClass="ControleOnline\Repository\ParticularsRepository") |
|
16
|
|
|
*/ |
|
17
|
|
|
#[ApiResource(operations: [new Get(security: 'is_granted(\'ROLE_CLIENT\')'), new GetCollection(security: 'is_granted(\'ROLE_CLIENT\')')], formats: ['jsonld', 'json', 'html', 'jsonhal', 'csv' => ['text/csv']], normalizationContext: ['groups' => ['particulars_read']], denormalizationContext: ['groups' => ['particulars_write']])] |
|
18
|
|
|
class Particulars |
|
19
|
|
|
{ |
|
20
|
|
|
/** |
|
21
|
|
|
* @var integer |
|
22
|
|
|
* |
|
23
|
|
|
* @ORM\Column(name="id", type="integer", nullable=false) |
|
24
|
|
|
* @ORM\Id |
|
25
|
|
|
* @ORM\GeneratedValue(strategy="IDENTITY") |
|
26
|
|
|
*/ |
|
27
|
|
|
private $id; |
|
28
|
|
|
/** |
|
29
|
|
|
* @var \ControleOnline\Entity\Particulars\ParticularsType |
|
30
|
|
|
* |
|
31
|
|
|
* @ORM\ManyToOne(targetEntity="ControleOnline\Entity\Particulars\ParticularsType") |
|
32
|
|
|
* @ORM\JoinColumns({ |
|
33
|
|
|
* @ORM\JoinColumn(name="particulars_type_id", referencedColumnName="id") |
|
34
|
|
|
* }) |
|
35
|
|
|
* @Groups({"particulars_read"}) |
|
36
|
|
|
*/ |
|
37
|
|
|
private $type; |
|
38
|
|
|
/** |
|
39
|
|
|
* @var \ControleOnline\Entity\People |
|
40
|
|
|
* |
|
41
|
|
|
* @ORM\ManyToOne(targetEntity="ControleOnline\Entity\People") |
|
42
|
|
|
* @ORM\JoinColumns({ |
|
43
|
|
|
* @ORM\JoinColumn(name="people_id", referencedColumnName="id") |
|
44
|
|
|
* }) |
|
45
|
|
|
*/ |
|
46
|
|
|
private $people; |
|
47
|
|
|
/** |
|
48
|
|
|
* @ORM\Column(name="particular_value", type="string", nullable=false) |
|
49
|
|
|
* @Groups({"particulars_read"}) |
|
50
|
|
|
*/ |
|
51
|
|
|
private $value; |
|
52
|
|
|
/** |
|
53
|
|
|
* Constructor |
|
54
|
|
|
*/ |
|
55
|
|
|
public function __construct() |
|
56
|
|
|
{ |
|
57
|
|
|
} |
|
58
|
|
|
/** |
|
59
|
|
|
* Get id |
|
60
|
|
|
* |
|
61
|
|
|
* @return integer |
|
62
|
|
|
*/ |
|
63
|
|
|
public function getId() |
|
64
|
|
|
{ |
|
65
|
|
|
return $this->id; |
|
66
|
|
|
} |
|
67
|
|
|
public function setType(ParticularsType $type) : self |
|
68
|
|
|
{ |
|
69
|
|
|
$this->type = $type; |
|
70
|
|
|
return $this; |
|
71
|
|
|
} |
|
72
|
|
|
public function getType() : ParticularsType |
|
73
|
|
|
{ |
|
74
|
|
|
return $this->type; |
|
75
|
|
|
} |
|
76
|
|
|
public function setPeople(People $people) : self |
|
|
|
|
|
|
77
|
|
|
{ |
|
78
|
|
|
$this->people = $people; |
|
79
|
|
|
return $this; |
|
80
|
|
|
} |
|
81
|
|
|
public function getPeople() : People |
|
82
|
|
|
{ |
|
83
|
|
|
return $this->people; |
|
84
|
|
|
} |
|
85
|
|
|
public function setValue(string $value) : self |
|
86
|
|
|
{ |
|
87
|
|
|
$this->value = $value; |
|
88
|
|
|
return $this; |
|
89
|
|
|
} |
|
90
|
|
|
public function getValue() : string |
|
91
|
|
|
{ |
|
92
|
|
|
return $this->value; |
|
93
|
|
|
} |
|
94
|
|
|
} |
|
95
|
|
|
|
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