<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20230216153512 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE TABLE has_concierge (id INT AUTO_INCREMENT NOT NULL, element_id INT NOT NULL, welcome_fr LONGTEXT DEFAULT NULL, welcome_en LONGTEXT DEFAULT NULL, wifi TINYINT(1) DEFAULT NULL, wifi_identifier VARCHAR(255) DEFAULT NULL, wifi_password VARCHAR(255) DEFAULT NULL, check_in TIME DEFAULT NULL, check_in_message_fr LONGTEXT DEFAULT NULL, check_in_message_en LONGTEXT DEFAULT NULL, check_out TIME DEFAULT NULL, check_out_message_fr LONGTEXT DEFAULT NULL, check_out_message_en LONGTEXT DEFAULT NULL, life_rules_fr LONGTEXT DEFAULT NULL, life_rules_en LONGTEXT DEFAULT NULL, UNIQUE INDEX UNIQ_7A40C79B1F1F2A24 (element_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
$this->addSql('ALTER TABLE has_concierge ADD CONSTRAINT FK_7A40C79B1F1F2A24 FOREIGN KEY (element_id) REFERENCES element (id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE has_concierge');
}
}