1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace ControleOnline\Entity; |
4
|
|
|
|
5
|
|
|
|
6
|
|
|
|
7
|
|
|
use Doctrine\ORM\Mapping as ORM; |
|
|
|
|
8
|
|
|
|
9
|
|
|
|
10
|
|
|
|
11
|
|
|
use ApiPlatform\Core\Annotation\ApiResource; |
|
|
|
|
12
|
|
|
use Symfony\Component\Serializer\Annotation\Groups; |
|
|
|
|
13
|
|
|
use ApiPlatform\Core\Annotation\ApiFilter; |
|
|
|
|
14
|
|
|
use ApiPlatform\Core\Bridge\Doctrine\Orm\Filter\SearchFilter; |
|
|
|
|
15
|
|
|
|
16
|
|
|
|
17
|
|
|
/** |
18
|
|
|
* @ORM\EntityListeners({ControleOnline\Listener\LogListener::class}) |
19
|
|
|
* @ApiResource( |
20
|
|
|
* attributes={ |
21
|
|
|
* "formats"={"jsonld", "json", "html", "jsonhal", "csv"={"text/csv"}}, |
22
|
|
|
* "access_control"="is_granted('ROLE_CLIENT')" |
23
|
|
|
* }, |
24
|
|
|
* normalizationContext ={"groups"={"queue:read"}}, |
25
|
|
|
* denormalizationContext={"groups"={"queue:write"}}, |
26
|
|
|
* attributes ={"access_control"="is_granted('ROLE_CLIENT')"}, |
27
|
|
|
* collectionOperations ={ |
28
|
|
|
* "get" ={ |
29
|
|
|
* "access_control"="is_granted('ROLE_CLIENT')", |
30
|
|
|
* }, |
31
|
|
|
* }, |
32
|
|
|
* itemOperations ={ |
33
|
|
|
* "get" ={ |
34
|
|
|
* "access_control"="is_granted('ROLE_CLIENT')", |
35
|
|
|
* }, |
36
|
|
|
* "put" ={ |
37
|
|
|
* "access_control"="is_granted('ROLE_CLIENT')", |
38
|
|
|
* }, |
39
|
|
|
* "delete" ={ |
40
|
|
|
* "access_control"="is_granted('ROLE_CLIENT')", |
41
|
|
|
* }, |
42
|
|
|
* } |
43
|
|
|
* ) |
44
|
|
|
* @ORM\Table(name="queue", uniqueConstraints={@ORM\UniqueConstraint(name="queue", columns={"queue", "company_id"})}, indexes={@ORM\Index(name="company_id", columns={"company_id"})}) |
45
|
|
|
* @ORM\Entity |
46
|
|
|
*/ |
47
|
|
|
|
48
|
|
|
|
49
|
|
|
class Queue |
50
|
|
|
{ |
51
|
|
|
/** |
52
|
|
|
* @var int |
53
|
|
|
* |
54
|
|
|
* @ORM\Column(name="id", type="integer", nullable=false) |
55
|
|
|
* @ORM\Id |
56
|
|
|
* @ORM\GeneratedValue(strategy="IDENTITY") |
57
|
|
|
* @Groups({"display_queue:read","product_category:read","order_product_queue:read","product:read","product_group_product:read","order_product:read","order:read","order_details:read","order:write","queue:read", "queue:write"}) |
58
|
|
|
*/ |
59
|
|
|
private $id; |
60
|
|
|
|
61
|
|
|
/** |
62
|
|
|
* @var string |
63
|
|
|
* |
64
|
|
|
* @ORM\Column(name="queue", type="string", length=50, nullable=false) |
65
|
|
|
* @Groups({"display_queue:read","product_category:read","order_product_queue:read","product:read","product_group_product:read","order_product:read","order:read","order_details:read","order:write","queue:read", "queue:write"}) |
66
|
|
|
*/ |
67
|
|
|
private $queue; |
68
|
|
|
|
69
|
|
|
|
70
|
|
|
/** |
71
|
|
|
* @var ControleOnline\Entity\Status |
|
|
|
|
72
|
|
|
* |
73
|
|
|
* @ORM\ManyToOne(targetEntity="ControleOnline\Entity\Status") |
74
|
|
|
* @ORM\JoinColumns({ |
75
|
|
|
* @ORM\JoinColumn(name="status_in_id", referencedColumnName="id") |
76
|
|
|
* }) |
77
|
|
|
* @Groups({"display_queue:read","order:read","order_details:read","order:write","display:read", "display:write"}) |
78
|
|
|
*/ |
79
|
|
|
|
80
|
|
|
|
81
|
|
|
#[ApiFilter(filterClass: SearchFilter::class, properties: ['status_in' => 'exact'])] |
82
|
|
|
|
83
|
|
|
private $status_in; |
84
|
|
|
/** |
85
|
|
|
* @var ControleOnline\Entity\Status |
86
|
|
|
* |
87
|
|
|
* @ORM\ManyToOne(targetEntity="ControleOnline\Entity\Status") |
88
|
|
|
* @ORM\JoinColumns({ |
89
|
|
|
* @ORM\JoinColumn(name="status_working_id", referencedColumnName="id") |
90
|
|
|
* }) |
91
|
|
|
* @Groups({"display_queue:read","order:read","order_details:read","order:write","display:read", "display:write"}) |
92
|
|
|
*/ |
93
|
|
|
|
94
|
|
|
|
95
|
|
|
#[ApiFilter(filterClass: SearchFilter::class, properties: ['status_working' => 'exact'])] |
96
|
|
|
|
97
|
|
|
private $status_working; |
98
|
|
|
/** |
99
|
|
|
* @var ControleOnline\Entity\Status |
100
|
|
|
* |
101
|
|
|
* @ORM\ManyToOne(targetEntity="ControleOnline\Entity\Status") |
102
|
|
|
* @ORM\JoinColumns({ |
103
|
|
|
* @ORM\JoinColumn(name="status_out_id", referencedColumnName="id") |
104
|
|
|
* }) |
105
|
|
|
* @Groups({"display_queue:read","order:read","order_details:read","order:write","display:read", "display:write"}) |
106
|
|
|
*/ |
107
|
|
|
|
108
|
|
|
|
109
|
|
|
#[ApiFilter(filterClass: SearchFilter::class, properties: ['status_out' => 'exact'])] |
110
|
|
|
|
111
|
|
|
private $status_out; |
112
|
|
|
|
113
|
|
|
/** |
114
|
|
|
* @var \People |
|
|
|
|
115
|
|
|
* |
116
|
|
|
* @ORM\ManyToOne(targetEntity="People") |
117
|
|
|
* @ORM\JoinColumns({ |
118
|
|
|
* @ORM\JoinColumn(name="company_id", referencedColumnName="id") |
119
|
|
|
* }) |
120
|
|
|
* @Groups({"display_queue:read","product_category:read","order_product_queue:read","product:read","product_group_product:read","order_product:read","order:read","order_details:read","order:write","queue:read", "queue:write"}) |
121
|
|
|
*/ |
122
|
|
|
#[ApiFilter(filterClass: SearchFilter::class, properties: ['company' => 'exact'])] |
123
|
|
|
|
124
|
|
|
private $company; |
125
|
|
|
|
126
|
|
|
|
127
|
|
|
/** |
128
|
|
|
* @var \Doctrine\Common\Collections\Collection |
|
|
|
|
129
|
|
|
* |
130
|
|
|
* @ORM\OneToMany(targetEntity="ControleOnline\Entity\OrderProductQueue", mappedBy="queue") |
131
|
|
|
*/ |
132
|
|
|
private $orderProductQueue; |
133
|
|
|
|
134
|
|
|
|
135
|
|
|
/** |
136
|
|
|
* @var \Doctrine\Common\Collections\Collection |
137
|
|
|
* |
138
|
|
|
* @ORM\OneToMany(targetEntity="ControleOnline\Entity\DisplayQueue", mappedBy="queue") |
139
|
|
|
*/ |
140
|
|
|
private $displayQueue; |
141
|
|
|
|
142
|
|
|
|
143
|
|
|
/** |
144
|
|
|
* Get the value of id |
145
|
|
|
*/ |
146
|
|
|
public function getId() |
147
|
|
|
{ |
148
|
|
|
return $this->id; |
149
|
|
|
} |
150
|
|
|
|
151
|
|
|
/** |
152
|
|
|
* Set the value of id |
153
|
|
|
*/ |
154
|
|
|
public function setId($id): self |
155
|
|
|
{ |
156
|
|
|
$this->id = $id; |
157
|
|
|
|
158
|
|
|
return $this; |
159
|
|
|
} |
160
|
|
|
|
161
|
|
|
/** |
162
|
|
|
* Get the value of queue |
163
|
|
|
*/ |
164
|
|
|
public function getQueue() |
165
|
|
|
{ |
166
|
|
|
return $this->queue; |
167
|
|
|
} |
168
|
|
|
|
169
|
|
|
/** |
170
|
|
|
* Set the value of queue |
171
|
|
|
*/ |
172
|
|
|
public function setQueue($queue): self |
173
|
|
|
{ |
174
|
|
|
$this->queue = $queue; |
175
|
|
|
|
176
|
|
|
return $this; |
177
|
|
|
} |
178
|
|
|
|
179
|
|
|
/** |
180
|
|
|
* Get the value of company |
181
|
|
|
*/ |
182
|
|
|
public function getCompany() |
183
|
|
|
{ |
184
|
|
|
return $this->company; |
185
|
|
|
} |
186
|
|
|
|
187
|
|
|
/** |
188
|
|
|
* Set the value of company |
189
|
|
|
*/ |
190
|
|
|
public function setCompany($company): self |
191
|
|
|
{ |
192
|
|
|
$this->company = $company; |
193
|
|
|
|
194
|
|
|
return $this; |
195
|
|
|
} |
196
|
|
|
|
197
|
|
|
|
198
|
|
|
|
199
|
|
|
/** |
200
|
|
|
* Add OrderProductQueue |
201
|
|
|
* |
202
|
|
|
* @param \ControleOnline\Entity\OrderProductQueue $invoice_tax |
203
|
|
|
* @return Order |
204
|
|
|
*/ |
205
|
|
|
public function addAOrderProductQueue(\ControleOnline\Entity\OrderProductQueue $orderProductQueue) |
206
|
|
|
{ |
207
|
|
|
$this->orderProductQueue[] = $orderProductQueue; |
208
|
|
|
|
209
|
|
|
return $this; |
|
|
|
|
210
|
|
|
} |
211
|
|
|
|
212
|
|
|
/** |
213
|
|
|
* Remove OrderProductQueue |
214
|
|
|
* |
215
|
|
|
* @param \ControleOnline\Entity\OrderProductQueue $invoice_tax |
216
|
|
|
*/ |
217
|
|
|
public function removeOrderProductQueue(\ControleOnline\Entity\OrderProductQueue $orderProductQueue) |
218
|
|
|
{ |
219
|
|
|
$this->orderProductQueue->removeElement($orderProductQueue); |
220
|
|
|
} |
221
|
|
|
|
222
|
|
|
/** |
223
|
|
|
* Get OrderProductQueue |
224
|
|
|
* |
225
|
|
|
* @return \Doctrine\Common\Collections\Collection |
226
|
|
|
*/ |
227
|
|
|
public function getOrderProductQueue() |
228
|
|
|
{ |
229
|
|
|
return $this->orderProductQueue; |
230
|
|
|
} |
231
|
|
|
|
232
|
|
|
|
233
|
|
|
/** |
234
|
|
|
* Add DisplayQueue |
235
|
|
|
* |
236
|
|
|
* @param \ControleOnline\Entity\DisplayQueue $invoice_tax |
237
|
|
|
* @return Order |
238
|
|
|
*/ |
239
|
|
|
public function addADisplayQueue(\ControleOnline\Entity\DisplayQueue $displayQueue) |
240
|
|
|
{ |
241
|
|
|
$this->displayQueue[] = $displayQueue; |
242
|
|
|
|
243
|
|
|
return $this; |
|
|
|
|
244
|
|
|
} |
245
|
|
|
|
246
|
|
|
/** |
247
|
|
|
* Remove DisplayQueue |
248
|
|
|
* |
249
|
|
|
* @param \ControleOnline\Entity\DisplayQueue $invoice_tax |
250
|
|
|
*/ |
251
|
|
|
public function removeDisplayQueue(\ControleOnline\Entity\DisplayQueue $displayQueue) |
252
|
|
|
{ |
253
|
|
|
$this->displayQueue->removeElement($displayQueue); |
254
|
|
|
} |
255
|
|
|
|
256
|
|
|
/** |
257
|
|
|
* Get DisplayQueue |
258
|
|
|
* |
259
|
|
|
* @return \Doctrine\Common\Collections\Collection |
260
|
|
|
*/ |
261
|
|
|
public function getDisplayQueue() |
262
|
|
|
{ |
263
|
|
|
return $this->displayQueue; |
264
|
|
|
} |
265
|
|
|
|
266
|
|
|
|
267
|
|
|
/** |
268
|
|
|
* Get the value of status_in |
269
|
|
|
*/ |
270
|
|
|
public function getStatusIn() |
271
|
|
|
{ |
272
|
|
|
return $this->status_in; |
273
|
|
|
} |
274
|
|
|
|
275
|
|
|
/** |
276
|
|
|
* Set the value of status_in |
277
|
|
|
*/ |
278
|
|
|
public function setStatusIn($status_in): self |
279
|
|
|
{ |
280
|
|
|
$this->status_in = $status_in; |
281
|
|
|
|
282
|
|
|
return $this; |
283
|
|
|
} |
284
|
|
|
|
285
|
|
|
/** |
286
|
|
|
* Get the value of status_working |
287
|
|
|
*/ |
288
|
|
|
public function getStatusWorking() |
289
|
|
|
{ |
290
|
|
|
return $this->status_working; |
291
|
|
|
} |
292
|
|
|
|
293
|
|
|
/** |
294
|
|
|
* Set the value of status_working |
295
|
|
|
*/ |
296
|
|
|
public function setStatusWorking($status_working): self |
297
|
|
|
{ |
298
|
|
|
$this->status_working = $status_working; |
299
|
|
|
|
300
|
|
|
return $this; |
301
|
|
|
} |
302
|
|
|
|
303
|
|
|
/** |
304
|
|
|
* Get the value of status_out |
305
|
|
|
*/ |
306
|
|
|
public function getStatusOut() |
307
|
|
|
{ |
308
|
|
|
return $this->status_out; |
309
|
|
|
} |
310
|
|
|
|
311
|
|
|
/** |
312
|
|
|
* Set the value of status_out |
313
|
|
|
*/ |
314
|
|
|
public function setStatusOut($status_out): self |
315
|
|
|
{ |
316
|
|
|
$this->status_out = $status_out; |
317
|
|
|
|
318
|
|
|
return $this; |
319
|
|
|
} |
320
|
|
|
} |
321
|
|
|
|
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