diff --git a/src/Bundle/ChillMainBundle/Command/LoadPostalCodesCommand.php b/src/Bundle/ChillMainBundle/Command/LoadPostalCodesCommand.php index 6b047a04b..7655c2ed8 100644 --- a/src/Bundle/ChillMainBundle/Command/LoadPostalCodesCommand.php +++ b/src/Bundle/ChillMainBundle/Command/LoadPostalCodesCommand.php @@ -193,7 +193,7 @@ class LoadPostalCodesCommand extends Command ; if (NULL != $row[3]){ - $postalCode->setRefId($row[3]); + $postalCode->setRefPostalCodeId($row[3]); } if (NULL != $row[4] & NULL != $row[5]){ @@ -201,7 +201,7 @@ class LoadPostalCodesCommand extends Command } if (NULL != $row[6]){ - $postalCode->setSource($row[6]); + $postalCode->setPostalCodeSource($row[6]); } $errors = $this->validator->validate($postalCode); diff --git a/src/Bundle/ChillMainBundle/Entity/PostalCode.php b/src/Bundle/ChillMainBundle/Entity/PostalCode.php index cd7e8aa5f..8855c40f1 100644 --- a/src/Bundle/ChillMainBundle/Entity/PostalCode.php +++ b/src/Bundle/ChillMainBundle/Entity/PostalCode.php @@ -69,7 +69,7 @@ class PostalCode * @ORM\Column(type="string", length=255, nullable=true) * @groups({"write", "read"}) */ - private $refId; + private $refPostalCodeId; /** * @var string @@ -77,7 +77,7 @@ class PostalCode * @ORM\Column(type="string", length=255, nullable=true) * @groups({"write", "read"}) */ - private $source; + private $postalCodeSource; /** * @var Point @@ -195,26 +195,26 @@ class PostalCode return $this->country; } - public function getRefId(): ?string + public function getRefPostalCodeId(): ?string { - return $this->refId; + return $this->refPostalCodeId; } - public function setRefId(?string $refId): self + public function setRefPostalCodeId(?string $refPostalCodeId): self { - $this->refId = $refId; + $this->refPostalCodeId = $refPostalCodeId; return $this; } - public function getSource(): ?string + public function getPostalCodeSource(): ?string { - return $this->source; + return $this->postalCodeSource; } - public function setSource(?string $source): self + public function setPostalCodeSource(?string $postalCodeSource): self { - $this->source = $source; + $this->postalCodeSource = $postalCodeSource; return $this; } diff --git a/src/Bundle/ChillMainBundle/migrations/Version20211006151653.php b/src/Bundle/ChillMainBundle/migrations/Version20211006151653.php index c3853b568..9f4508ba8 100644 --- a/src/Bundle/ChillMainBundle/migrations/Version20211006151653.php +++ b/src/Bundle/ChillMainBundle/migrations/Version20211006151653.php @@ -20,14 +20,14 @@ final class Version20211006151653 extends AbstractMigration public function up(Schema $schema): void { $this->addSql('ALTER TABLE chill_main_postal_code ADD refPostalCodeId VARCHAR(255) DEFAULT NULL'); - $this->addSql('ALTER TABLE chill_main_postal_code ADD source VARCHAR(255) DEFAULT NULL'); + $this->addSql('ALTER TABLE chill_main_postal_code ADD postalCodeSource VARCHAR(255) DEFAULT NULL'); $this->addSql('ALTER TABLE chill_main_postal_code ADD center geometry(POINT,4326) DEFAULT NULL'); } public function down(Schema $schema): void { $this->addSql('ALTER TABLE chill_main_postal_code DROP refPostalCodeId'); - $this->addSql('ALTER TABLE chill_main_postal_code DROP source'); + $this->addSql('ALTER TABLE chill_main_postal_code DROP postalCodeSource'); $this->addSql('ALTER TABLE chill_main_postal_code DROP center'); } }