<?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 Version20211124093222 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('ALTER TABLE lang ADD code VARCHAR(5) NOT NULL');
$this->addSql('ALTER TABLE resource ADD phone_valid TINYINT(1) DEFAULT NULL, ADD phone_lookup TINYINT(1) DEFAULT \'0\' NOT NULL, ADD phone_carrier VARCHAR(255) DEFAULT NULL, ADD phone_type VARCHAR(10) DEFAULT NULL');
$this->addSql('ALTER TABLE scenario_project ADD click_to_call TINYINT(1) DEFAULT \'0\' NOT NULL, ADD calling_number VARCHAR(255) DEFAULT NULL');
$this->addSql('UPDATE lang SET code = "fr" WHERE id = 1');
$this->addSql('UPDATE lang SET code = "en" WHERE id = 2');
$this->addSql('UPDATE lang SET code = "no" WHERE id = 3');
$this->addSql('UPDATE lang SET code = "sv" WHERE id = 4');
$this->addSql('UPDATE lang SET code = "nl" WHERE id = 5');
$this->addSql('UPDATE lang SET code = "pl" WHERE id = 6');
$this->addSql('UPDATE lang SET code = "ar" WHERE id = 7');
$this->addSql('UPDATE lang SET code = "af" WHERE id = 8');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE lang DROP code');
$this->addSql('ALTER TABLE resource DROP phone_valid, DROP phone_lookup, DROP phone_carrier, DROP phone_type');
$this->addSql('ALTER TABLE scenario_project DROP click_to_call, DROP calling_number');
}
}