Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
95.79% covered (success)
95.79%
91 / 95
93.33% covered (success)
93.33%
56 / 60
CRAP
0.00% covered (danger)
0.00%
0 / 1
Beleg
95.79% covered (success)
95.79%
91 / 95
93.33% covered (success)
93.33%
56 / 60
65
0.00% covered (danger)
0.00%
0 / 1
 __toString
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getAdresse
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setAdresse
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getAndatevsenden
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setAndatevsenden
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getArchiviert
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setArchiviert
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getAuftrag
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setAuftrag
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBelegart
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBelegart
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBelegdatum
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBelegdatum
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
2
 getBelegnummer
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBelegnummer
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBemerkung
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBemerkung
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBetrag
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBetrag
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getBezeichnung
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setBezeichnung
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getFakturastatus
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setFakturastatus
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getFibubuchungenlfdnr
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setFibubuchungenlfdnr
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getGeprueft
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setGeprueft
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getGeprueftam
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setGeprueftam
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
2
 getGeprueftvon
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setGeprueftvon
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getGesperrt
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setGesperrt
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getLfdnr
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getOffposlfdnr
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setOffposlfdnr
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getStatusprotokoll
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setStatusprotokoll
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getUebertragenandatev
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setUebertragenandatev
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getUebertragenandatevam
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setUebertragenandatevam
75.00% covered (warning)
75.00%
3 / 4
0.00% covered (danger)
0.00%
0 / 1
2.06
 getUebertragenandatevvon
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setUebertragenandatevvon
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getZahlungsstatus
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setZahlungsstatus
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getZubezahlenbis
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setZubezahlenbis
75.00% covered (warning)
75.00%
3 / 4
0.00% covered (danger)
0.00%
0 / 1
2.06
 getExportiert
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setExportiert
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getExportiertam
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setExportiertam
75.00% covered (warning)
75.00%
3 / 4
0.00% covered (danger)
0.00%
0 / 1
2.06
 getExportiertvon
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setExportiertvon
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getIban
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setIban
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getZahlungsreferenznr
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setZahlungsreferenznr
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
 getZahlweise
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 setZahlweise
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3declare(strict_types=1);
4
5namespace Satag\AmicronEntityBundle\Entity;
6
7use Doctrine\DBAL\Types\Types;
8use Doctrine\ORM\Mapping as ORM;
9use Satag\AmicronEntityBundle\Traits\BlameableEntity;
10use Satag\AmicronEntityBundle\Traits\BlameableEntityInterface;
11use Satag\AmicronEntityBundle\Traits\DecimalEntity;
12use Satag\AmicronEntityBundle\Traits\VorlegbareEntity;
13
14/**
15 * Dokumentliste.
16 *
17 * @see \Satag\AmicronEntityBundle\Tests\Entity\BelegTest
18 */
19#[ORM\Entity]
20#[ORM\Table(name: 'BELEGE')]
21class Beleg implements BlameableEntityInterface, \Stringable
22{
23    use BlameableEntity;
24    use DecimalEntity;
25    use VorlegbareEntity;
26
27    #[ORM\ManyToOne(targetEntity: Adresse::class)]
28    #[ORM\JoinColumn(name: 'adressenlfdnr', referencedColumnName: 'lfdnr')]
29    private ?Adresse $adresse = null;
30
31    #[ORM\Column(name: 'andatevsenden', type: Types::INTEGER, nullable: true)]
32    private ?int $andatevsenden = null;
33
34    #[ORM\Column(name: 'archiviert', type: Types::INTEGER, nullable: true)]
35    private ?int $archiviert = null;
36
37    #[ORM\ManyToOne(targetEntity: Auftrag::class)]
38    #[ORM\JoinColumn(name: 'auftraglfdnr', referencedColumnName: 'lfdnr')]
39    private ?Auftrag $auftrag = null;
40
41    #[ORM\Column(name: 'belegart', type: Types::INTEGER, nullable: true)]
42    private ?int $belegart = null;
43
44    #[ORM\Column(name: 'belegdatum', type: Types::DATETIME_IMMUTABLE, nullable: true)]
45    private ?\DateTimeImmutable $belegdatum = null;
46
47    #[ORM\Column(name: 'belegnummer', type: Types::STRING, length: 255, nullable: true)]
48    private ?string $belegnummer = null;
49
50    #[ORM\Column(name: 'bemerkung', type: Types::TEXT, nullable: true)]
51    private ?string $bemerkung = null;
52
53    #[ORM\Column(name: 'betrag', type: 'amicron_decimal', precision: 15, scale: 6, nullable: true)]
54    private ?string $betrag = null;
55
56    #[ORM\Column(name: 'bezeichnung', type: Types::STRING, length: 80, nullable: true)]
57    private ?string $bezeichnung = null;
58
59    #[ORM\Column(name: 'fakturastatus', type: Types::INTEGER, nullable: true)]
60    private ?int $fakturastatus = null;
61
62    #[ORM\ManyToOne(targetEntity: Fibubuchung::class)]
63    #[ORM\JoinColumn(name: 'fibubuchungenlfdnr', referencedColumnName: 'lfdnr')]
64    private ?Fibubuchung $fibubuchungenlfdnr = null;
65
66    #[ORM\Column(name: 'geprueft', type: Types::INTEGER, nullable: true)]
67    private ?int $geprueft = null;
68
69    #[ORM\Column(name: 'geprueftam', type: Types::DATETIME_IMMUTABLE, nullable: true)]
70    private ?\DateTimeImmutable $geprueftam = null;
71
72    #[ORM\Column(name: 'geprueftvon', type: Types::STRING, length: 3, nullable: true)]
73    private ?string $geprueftvon = null;
74
75    #[ORM\Column(name: 'gesperrt', type: Types::INTEGER, nullable: true)]
76    private ?int $gesperrt = null;
77
78    #[ORM\Column(name: 'lfdnr', type: Types::INTEGER, nullable: false)]
79    #[ORM\Id]
80    #[ORM\GeneratedValue(strategy: 'SEQUENCE')]
81    #[ORM\SequenceGenerator(sequenceName: 'GEN_LFDNR', allocationSize: 1, initialValue: 1)]
82    public private(set) ?int $lfdnr = null;
83
84    #[ORM\ManyToOne(targetEntity: OffenerPosten::class)]
85    #[ORM\JoinColumn(name: 'offposlfdnr', referencedColumnName: 'lfdnr')]
86    private ?OffenerPosten $offposlfdnr = null;
87
88    #[ORM\Column(name: 'statusprotokoll', type: Types::TEXT, nullable: true)]
89    private ?string $statusprotokoll = null;
90
91    #[ORM\Column(name: 'uebertragenandatev', type: Types::INTEGER, nullable: true)]
92    private ?int $uebertragenandatev = null;
93
94    #[ORM\Column(name: 'uebertragenandatevam', type: Types::DATETIME_IMMUTABLE, nullable: true)]
95    private ?\DateTimeImmutable $uebertragenandatevam = null;
96
97    #[ORM\Column(name: 'uebertragenandatevvon', type: Types::STRING, length: 3, nullable: true)]
98    private ?string $uebertragenandatevvon = null;
99
100    #[ORM\Column(name: 'zahlungsstatus', type: Types::INTEGER, nullable: true)]
101    private ?int $zahlungsstatus = null;
102
103    #[ORM\Column(name: 'zubezahlenbis', type: Types::DATETIME_IMMUTABLE, nullable: true)]
104    private ?\DateTimeImmutable $zubezahlenbis = null;
105
106    public function __toString(): string
107    {
108        return \sprintf('%s - %s (ID: %s)', $this->getBezeichnung(), $this->getBelegnummer(), $this->lfdnr);
109    }
110
111    public function getAdresse(): ?Adresse
112    {
113        return $this->adresse;
114    }
115
116    public function setAdresse(?Adresse $adresse): self
117    {
118        $this->adresse = $adresse;
119
120        return $this;
121    }
122
123    public function getAndatevsenden(): ?int
124    {
125        return $this->andatevsenden;
126    }
127
128    public function setAndatevsenden(?int $andatevsenden): self
129    {
130        $this->andatevsenden = $andatevsenden;
131
132        return $this;
133    }
134
135    public function getArchiviert(): ?int
136    {
137        return $this->archiviert;
138    }
139
140    public function setArchiviert(?int $archiviert): self
141    {
142        $this->archiviert = $archiviert;
143
144        return $this;
145    }
146
147    public function getAuftrag(): ?Auftrag
148    {
149        return $this->auftrag;
150    }
151
152    public function setAuftrag(?Auftrag $auftrag): self
153    {
154        $this->auftrag = $auftrag;
155
156        return $this;
157    }
158
159    public function getBelegart(): ?int
160    {
161        return $this->belegart;
162    }
163
164    public function setBelegart(?int $belegart): self
165    {
166        $this->belegart = $belegart;
167
168        return $this;
169    }
170
171    public function getBelegdatum(): ?\DateTimeImmutable
172    {
173        return $this->belegdatum;
174    }
175
176    public function setBelegdatum(\DateTimeImmutable|\DateTime|null $belegdatum): self
177    {
178        $this->belegdatum = $belegdatum instanceof \DateTime ? \DateTimeImmutable::createFromMutable($belegdatum) : $belegdatum;
179
180        return $this;
181    }
182
183    public function getBelegnummer(): ?string
184    {
185        return $this->belegnummer;
186    }
187
188    public function setBelegnummer(?string $belegnummer): self
189    {
190        $this->belegnummer = $belegnummer;
191
192        return $this;
193    }
194
195    public function getBemerkung(): ?string
196    {
197        return $this->bemerkung;
198    }
199
200    public function setBemerkung(?string $bemerkung): self
201    {
202        $this->bemerkung = $bemerkung;
203
204        return $this;
205    }
206
207    public function getBetrag(): ?string
208    {
209        return $this->betrag;
210    }
211
212    public function setBetrag(?string $betrag): self
213    {
214        $this->betrag = $betrag;
215
216        return $this;
217    }
218
219    public function getBezeichnung(): ?string
220    {
221        return $this->bezeichnung;
222    }
223
224    public function setBezeichnung(?string $bezeichnung): self
225    {
226        $this->bezeichnung = $bezeichnung;
227
228        return $this;
229    }
230
231    public function getFakturastatus(): ?int
232    {
233        return $this->fakturastatus;
234    }
235
236    public function setFakturastatus(?int $fakturastatus): self
237    {
238        $this->fakturastatus = $fakturastatus;
239
240        return $this;
241    }
242
243    public function getFibubuchungenlfdnr(): ?Fibubuchung
244    {
245        return $this->fibubuchungenlfdnr;
246    }
247
248    public function setFibubuchungenlfdnr(?Fibubuchung $fibubuchungenlfdnr): self
249    {
250        $this->fibubuchungenlfdnr = $fibubuchungenlfdnr;
251
252        return $this;
253    }
254
255    public function getGeprueft(): ?int
256    {
257        return $this->geprueft;
258    }
259
260    public function setGeprueft(?int $geprueft): self
261    {
262        $this->geprueft = $geprueft;
263
264        return $this;
265    }
266
267    public function getGeprueftam(): ?\DateTimeImmutable
268    {
269        return $this->geprueftam;
270    }
271
272    public function setGeprueftam(\DateTimeImmutable|\DateTime|null $geprueftam): self
273    {
274        $this->geprueftam = $geprueftam instanceof \DateTime ? \DateTimeImmutable::createFromMutable($geprueftam) : $geprueftam;
275
276        return $this;
277    }
278
279    public function getGeprueftvon(): ?string
280    {
281        return $this->geprueftvon;
282    }
283
284    public function setGeprueftvon(?string $geprueftvon): self
285    {
286        $this->geprueftvon = $geprueftvon;
287
288        return $this;
289    }
290
291    public function getGesperrt(): ?int
292    {
293        return $this->gesperrt;
294    }
295
296    public function setGesperrt(?int $gesperrt): self
297    {
298        $this->gesperrt = $gesperrt;
299
300        return $this;
301    }
302
303    public function getLfdnr(): ?int
304    {
305        return $this->lfdnr;
306    }
307
308    public function getOffposlfdnr(): ?OffenerPosten
309    {
310        return $this->offposlfdnr;
311    }
312
313    public function setOffposlfdnr(?OffenerPosten $offposlfdnr): self
314    {
315        $this->offposlfdnr = $offposlfdnr;
316
317        return $this;
318    }
319
320    public function getStatusprotokoll(): ?string
321    {
322        return $this->statusprotokoll;
323    }
324
325    public function setStatusprotokoll(?string $statusprotokoll): self
326    {
327        $this->statusprotokoll = $statusprotokoll;
328
329        return $this;
330    }
331
332    public function getUebertragenandatev(): ?int
333    {
334        return $this->uebertragenandatev;
335    }
336
337    public function setUebertragenandatev(?int $uebertragenandatev): self
338    {
339        $this->uebertragenandatev = $uebertragenandatev;
340
341        return $this;
342    }
343
344    public function getUebertragenandatevam(): ?\DateTimeImmutable
345    {
346        return $this->uebertragenandatevam;
347    }
348
349    public function setUebertragenandatevam(\DateTimeImmutable|\DateTime|null $uebertragenandatevam): self
350    {
351        $this->uebertragenandatevam = $uebertragenandatevam instanceof \DateTime
352            ? \DateTimeImmutable::createFromMutable($uebertragenandatevam)
353            : $uebertragenandatevam;
354
355        return $this;
356    }
357
358    public function getUebertragenandatevvon(): ?string
359    {
360        return $this->uebertragenandatevvon;
361    }
362
363    public function setUebertragenandatevvon(?string $uebertragenandatevvon): self
364    {
365        $this->uebertragenandatevvon = $uebertragenandatevvon;
366
367        return $this;
368    }
369
370    public function getZahlungsstatus(): ?int
371    {
372        return $this->zahlungsstatus;
373    }
374
375    public function setZahlungsstatus(?int $zahlungsstatus): self
376    {
377        $this->zahlungsstatus = $zahlungsstatus;
378
379        return $this;
380    }
381
382    public function getZubezahlenbis(): ?\DateTimeImmutable
383    {
384        return $this->zubezahlenbis;
385    }
386
387    public function setZubezahlenbis(\DateTimeImmutable|\DateTime|null $zubezahlenbis): self
388    {
389        $this->zubezahlenbis = $zubezahlenbis instanceof \DateTime
390            ? \DateTimeImmutable::createFromMutable($zubezahlenbis)
391            : $zubezahlenbis;
392
393        return $this;
394    }
395
396    #[ORM\Column(name: 'exportiert', type: Types::INTEGER, nullable: true)]
397    private ?int $exportiert = null;
398
399    #[ORM\Column(name: 'exportiertam', type: Types::DATETIME_IMMUTABLE, nullable: true)]
400    private ?\DateTimeImmutable $exportiertam = null;
401
402    #[ORM\Column(name: 'exportiertvon', type: Types::STRING, length: 3, nullable: true)]
403    private ?string $exportiertvon = null;
404
405    #[ORM\Column(name: 'iban', type: Types::STRING, length: 34, nullable: true)]
406    private ?string $iban = null;
407
408    #[ORM\Column(name: 'zahlungsreferenznr', type: Types::STRING, length: 35, nullable: true)]
409    private ?string $zahlungsreferenznr = null;
410
411    #[ORM\Column(name: 'zahlweise', type: Types::STRING, length: 25, nullable: true)]
412    private ?string $zahlweise = null;
413
414    public function getExportiert(): ?int
415    {
416        return $this->exportiert;
417    }
418
419    public function setExportiert(?int $exportiert): static
420    {
421        $this->exportiert = $exportiert;
422
423        return $this;
424    }
425
426    public function getExportiertam(): ?\DateTimeImmutable
427    {
428        return $this->exportiertam;
429    }
430
431    public function setExportiertam(\DateTimeImmutable|\DateTime|null $dateTime): static
432    {
433        $this->exportiertam = $dateTime instanceof \DateTime
434            ? \DateTimeImmutable::createFromMutable($dateTime)
435            : $dateTime;
436
437        return $this;
438    }
439
440    public function getExportiertvon(): ?string
441    {
442        return $this->exportiertvon;
443    }
444
445    public function setExportiertvon(?string $exportiertvon): static
446    {
447        $this->exportiertvon = $exportiertvon;
448
449        return $this;
450    }
451
452    public function getIban(): ?string
453    {
454        return $this->iban;
455    }
456
457    public function setIban(?string $iban): static
458    {
459        $this->iban = $iban;
460
461        return $this;
462    }
463
464    public function getZahlungsreferenznr(): ?string
465    {
466        return $this->zahlungsreferenznr;
467    }
468
469    public function setZahlungsreferenznr(?string $zahlungsreferenznr): static
470    {
471        $this->zahlungsreferenznr = $zahlungsreferenznr;
472
473        return $this;
474    }
475
476    public function getZahlweise(): ?string
477    {
478        return $this->zahlweise;
479    }
480
481    public function setZahlweise(?string $zahlweise): static
482    {
483        $this->zahlweise = $zahlweise;
484
485        return $this;
486    }
487}