Commit c358be44 by Yvon

remove content of buggy migration

parent d321290e
......@@ -38,17 +38,22 @@ final class Version20220329182822 extends AbstractMigration implements Container
public function postUp(Schema $schema): void
{
$presta = $this->em->getRepository(Prestataire::class)->getPrestataireSolidoume();
// this up() migration is auto-generated, please modify it to your needs
$account = new AccountPrestataire();
$account
->setBalance(0)
->setCurrency(CurrencyEnum::CURRENCY_EMLC)
;
$presta->addAccount($account);
$this->em->persist($account);
$this->em->persist($presta);
$this->em->flush();
//EXPLANATION FOR CONTENT REMOVAL OF THIS VERSION :
//We have added new attributes in class Prestataire which cause this migration to fail
//Removing the content of this migration should not cause any issue because it does not
//modify the database structure and because data will be purged at the next install step
// $presta = $this->em->getRepository(Prestataire::class)->getPrestataireSolidoume();
// // this up() migration is auto-generated, please modify it to your needs
// $account = new AccountPrestataire();
// $account
// ->setBalance(0)
// ->setCurrency(CurrencyEnum::CURRENCY_EMLC)
// ;
// $presta->addAccount($account);
// $this->em->persist($account);
// $this->em->persist($presta);
// $this->em->flush();
}
public function down(Schema $schema): void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment