Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenvdlinde authored and StyleCIBot committed Jan 13, 2020
1 parent bdedb81 commit 2107a43
Show file tree
Hide file tree
Showing 45 changed files with 636 additions and 611 deletions.
6 changes: 3 additions & 3 deletions api/src/Command/ApiHelmCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
} else {
// outputs multiple lines to the console (adding "\n" at the end of each line)
$output->writeln([
'Helm Chart Creator',
'============',
$chart,
'Helm Chart Creator',
'============',
$chart,
]);
}
}
Expand Down
4 changes: 2 additions & 2 deletions api/src/DataFixtures/AppFixtures.php
Original file line number Diff line number Diff line change
Expand Up @@ -206,15 +206,15 @@ public function load(ObjectManager $manager)
$this->loadFromExcel($manager);
}

public function createReader() :PhpSpreadsheet\Reader\Xlsx
public function createReader(): PhpSpreadsheet\Reader\Xlsx
{
$reader = new PhpSpreadsheet\Reader\Xlsx();
$reader->setReadDataOnly(true);

return $reader;
}

public function loadXlsx(string $filename) :PhpSpreadsheet\Spreadsheet
public function loadXlsx(string $filename): PhpSpreadsheet\Spreadsheet
{
$reader = $this->createReader();

Expand Down
23 changes: 13 additions & 10 deletions api/src/Entity/AangaanHuwelijkPartnerschap.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@

namespace App\Entity;

use ApiPlatform\Core\Annotation\ApiResource;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Ramsey\Uuid\UuidInterface;
use Symfony\Component\Serializer\Annotation\Groups;
use ApiPlatform\Core\Annotation\ApiResource;
use ApiPlatform\Core\Annotation\ApiProperty;
use Symfony\Component\Serializer\Annotation\MaxDepth;
use Symfony\Component\Validator\Constraints as Assert;

/**
* @ApiResource(
Expand All @@ -23,6 +21,7 @@ class AangaanHuwelijkPartnerschap
{
/**
* @var UuidInterface
*
* @example e2984465-190a-4562-829e-a8cca81aa35d
*
* @Groups({"read"})
Expand All @@ -31,10 +30,11 @@ class AangaanHuwelijkPartnerschap
* @ORM\GeneratedValue(strategy="CUSTOM")
* @ORM\CustomIdGenerator(class="Ramsey\Uuid\Doctrine\UuidGenerator")
*/
private $uuid;
private $uuid;

/**
* @var string $datum Datum this huwelijk has been requested
* @var string Datum this huwelijk has been requested
*
* @example 01-01-2000
*
* @Groups({"read","write"})
Expand All @@ -44,7 +44,8 @@ class AangaanHuwelijkPartnerschap
private $datum;

/**
* @var string $land Land this huwelijk is in
* @var string Land this huwelijk is in
*
* @example The Netherlands
*
* @Groups({"read","write"})
Expand All @@ -55,7 +56,8 @@ class AangaanHuwelijkPartnerschap
private $land;

/**
* @var string $plaats Plaats this huwelijk is in
* @var string Plaats this huwelijk is in
*
* @example Amsterdam
*
* @Groups({"read","write"})
Expand All @@ -74,7 +76,8 @@ class AangaanHuwelijkPartnerschap
private $inOnderzoek;

/**
* @var Partner $partner Other partner of this huwelijk
* @var Partner Other partner of this huwelijk
*
* @example John
*
* @Groups({"read","write"})
Expand All @@ -87,12 +90,12 @@ class AangaanHuwelijkPartnerschap
// On an object level we stil want to be able to gett the id
public function getId(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getUuid(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getDatum()
Expand Down
35 changes: 18 additions & 17 deletions api/src/Entity/Geboorte.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,14 @@

namespace App\Entity;

use ApiPlatform\Core\Annotation\ApiResource;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Ramsey\Uuid\UuidInterface;
use Symfony\Component\Serializer\Annotation\Groups;
use Gedmo\Mapping\Annotation as Gedmo;
use ApiPlatform\Core\Annotation\ApiResource;
use ApiPlatform\Core\Annotation\ApiProperty;
use Symfony\Component\Serializer\Annotation\MaxDepth;
use Symfony\Component\Validator\Constraints as Assert;

/**
* @ApiResource(
Expand All @@ -25,6 +23,7 @@ class Geboorte
{
/**
* @var UuidInterface
*
* @example e2984465-190a-4562-829e-a8cca81aa35d
*
* @Groups({"read"})
Expand All @@ -33,10 +32,11 @@ class Geboorte
* @ORM\GeneratedValue(strategy="CUSTOM")
* @ORM\CustomIdGenerator(class="Ramsey\Uuid\Doctrine\UuidGenerator")
*/
private $uuid;
private $uuid;

/**
* @var string $land Land this person is born in
* @var string Land this person is born in
*
* @example The Netherlands
*
* @Groups({"read", "write"})
Expand All @@ -48,7 +48,8 @@ class Geboorte
private $land;

/**
* @var string $plaats Plaats this person is born in
* @var string Plaats this person is born in
*
* @example Amsterdam
*
* @Groups({"read", "write"})
Expand All @@ -60,7 +61,8 @@ class Geboorte
private $plaats;

/**
* @var string $datum Datum this person is born at
* @var string Datum this person is born at
*
* @example 01-01-2000
*
* @Groups({"read", "write"})
Expand Down Expand Up @@ -89,16 +91,15 @@ public function __construct()
$this->ingeschrevenpersonen = new ArrayCollection();
}


// On an object level we stil want to be able to gett the id
public function getId(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getUuid(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getDatum()
Expand All @@ -115,26 +116,26 @@ public function setDatum($datum): self

public function getLand(): ?Waardetabel
{
return $this->land;
return $this->land;
}

public function setLand(?Waardetabel $land): self
{
$this->land = $land;
$this->land = $land;

return $this;
return $this;
}

public function getPlaats(): ?Waardetabel
{
return $this->plaats;
return $this->plaats;
}

public function setPlaats(?Waardetabel $plaats): self
{
$this->plaats = $plaats;
$this->plaats = $plaats;

return $this;
return $this;
}

public function getInOnderzoek()
Expand Down
20 changes: 10 additions & 10 deletions api/src/Entity/Gezagsverhouding.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@

namespace App\Entity;

use ApiPlatform\Core\Annotation\ApiResource;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Ramsey\Uuid\UuidInterface;
use Symfony\Component\Serializer\Annotation\Groups;
use ApiPlatform\Core\Annotation\ApiResource;
use ApiPlatform\Core\Annotation\ApiProperty;
use Symfony\Component\Serializer\Annotation\MaxDepth;
use Symfony\Component\Validator\Constraints as Assert;

Expand All @@ -23,6 +22,7 @@ class Gezagsverhouding
{
/**
* @var UuidInterface
*
* @example e2984465-190a-4562-829e-a8cca81aa35d
*
* @Groups({"read"})
Expand All @@ -31,7 +31,7 @@ class Gezagsverhouding
* @ORM\GeneratedValue(strategy="CUSTOM")
* @ORM\CustomIdGenerator(class="Ramsey\Uuid\Doctrine\UuidGenerator")
*/
private $uuid;
private $uuid;

/**
* @todo docblocks
Expand Down Expand Up @@ -74,12 +74,12 @@ class Gezagsverhouding
// On an object level we stil want to be able to gett the id
public function getId(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getUuid(): ?string
{
return $this->uuid;
return $this->uuid;
}

public function getIndicatieCurateleRegister(): ?bool
Expand Down Expand Up @@ -120,17 +120,17 @@ public function setInOnderzoek($inOnderzoek): self

public function getIngeschrevenpersoon(): ?Ingeschrevenpersoon
{
return $this->ingeschrevenpersoon;
return $this->ingeschrevenpersoon;
}

public function setIngeschrevenpersoon(?Ingeschrevenpersoon $ingeschrevenpersoon): self
{
$this->ingeschrevenpersoon = $ingeschrevenpersoon;
$this->ingeschrevenpersoon = $ingeschrevenpersoon;

// set (or unset) the owning side of the relation if necessary
$newGezagsverhouding = $ingeschrevenpersoon=== null ? null : $this;
if ($newGezagsverhouding !== $ingeschrevenpersoon->getGezagsverhouding()) {
$ingeschrevenpersoon->setGezagsverhouding($newGezagsverhouding);
$newGezagsverhouding = $ingeschrevenpersoon === null ? null : $this;
if ($newGezagsverhouding !== $ingeschrevenpersoon->getGezagsverhouding()) {
$ingeschrevenpersoon->setGezagsverhouding($newGezagsverhouding);
}

return $this;
Expand Down
Loading

0 comments on commit 2107a43

Please sign in to comment.