mirror of
https://github.com/maelgangloff/domain-watchdog.git
synced 2025-12-29 16:15:04 +00:00
feat: update Connector entity
This commit is contained in:
@@ -10,7 +10,7 @@ use Doctrine\Migrations\AbstractMigration;
|
||||
/**
|
||||
* Auto-generated Migration: Please modify to your needs!
|
||||
*/
|
||||
final class Version20240728191337 extends AbstractMigration
|
||||
final class Version20240728210044 extends AbstractMigration
|
||||
{
|
||||
public function getDescription(): string
|
||||
{
|
||||
@@ -20,7 +20,8 @@ final class Version20240728191337 extends AbstractMigration
|
||||
public function up(Schema $schema): void
|
||||
{
|
||||
// this up() migration is auto-generated, please modify it to your needs
|
||||
$this->addSql('CREATE TABLE connector (provider VARCHAR(255) NOT NULL, user_id INT NOT NULL, auth_data JSON NOT NULL, PRIMARY KEY(provider, user_id))');
|
||||
$this->addSql('CREATE SEQUENCE connector_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
||||
$this->addSql('CREATE TABLE connector (id INT NOT NULL, user_id INT NOT NULL, auth_data JSON NOT NULL, provider VARCHAR(255) NOT NULL, PRIMARY KEY(id))');
|
||||
$this->addSql('CREATE INDEX IDX_148C456EA76ED395 ON connector (user_id)');
|
||||
$this->addSql('ALTER TABLE connector ADD CONSTRAINT FK_148C456EA76ED395 FOREIGN KEY (user_id) REFERENCES "user" (id) NOT DEFERRABLE INITIALLY IMMEDIATE');
|
||||
}
|
||||
@@ -29,6 +30,7 @@ final class Version20240728191337 extends AbstractMigration
|
||||
{
|
||||
// this down() migration is auto-generated, please modify it to your needs
|
||||
$this->addSql('CREATE SCHEMA public');
|
||||
$this->addSql('DROP SEQUENCE connector_id_seq CASCADE');
|
||||
$this->addSql('ALTER TABLE connector DROP CONSTRAINT FK_148C456EA76ED395');
|
||||
$this->addSql('DROP TABLE connector');
|
||||
}
|
||||
Reference in New Issue
Block a user