<?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 Version20180820171921 extends AbstractMigration
{
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->abortIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('RENAME TABLE customers_tax_returns TO customer_tax_return');
$this->addSql('ALTER TABLE customer_tax_return ENGINE = InnoDB');
$this->addSql('ALTER TABLE customer_tax_return CHARACTER SET = utf8mb4');
$this->addSql('UPDATE customer_tax_return SET is_biz = 0 WHERE is_biz IS NULL');
$this->addSql('
ALTER TABLE customer_tax_return
ADD created_at DATETIME DEFAULT NULL,
ADD modified_at DATETIME DEFAULT NULL
');
$this->addSql('UPDATE customer_tax_return ct SET ct.created_at = (SELECT c.created_at FROM customer c WHERE c.id = ct.customers_id)');
$this->addSql('UPDATE customer_tax_return SET modified_at = created_at');
$this->addSql('
ALTER TABLE customer_tax_return
CHANGE customers_id customer_id INT DEFAULT NULL,
CHANGE administrators_id user_id INT DEFAULT NULL,
CHANGE year_type type VARCHAR(255) DEFAULT NULL,
CHANGE method method VARCHAR(255) DEFAULT NULL,
CHANGE type form VARCHAR(255) DEFAULT NULL,
CHANGE year year INT DEFAULT NULL,
CHANGE is_biz biz TINYINT(1) NOT NULL,
CHANGE completed_date completed_at DATETIME DEFAULT NULL,
CHANGE created_at created_at DATETIME NOT NULL,
CHANGE modified_at modified_at DATETIME NOT NULL
');
$this->addSql('UPDATE customer_tax_return SET created_at = (SELECT IF(converted_at IS NOT NULL, converted_at, created_at) FROM customer WHERE id = customer_id)');
$this->addSql('UPDATE customer_tax_return SET modified_at = IF(completed_at IS NOT NULL, completed_at, created_at)');
$this->addSql('UPDATE customer_tax_return SET form = \'1040_w2\' WHERE form = \'1040 W2\'');
$this->addSql('UPDATE customer_tax_return SET form = \'schedule_a\' WHERE form = \'Schedule A\'');
$this->addSql('UPDATE customer_tax_return SET form = \'schedule_c\' WHERE form = \'Schedule C\'');
$this->addSql('UPDATE customer_tax_return SET form = \'schedule_e\' WHERE form = \'Schedule E\'');
$this->addSql('UPDATE customer_tax_return SET form = \'schedule_f\' WHERE form = \'Schedule F\'');
$this->addSql('UPDATE customer_tax_return SET form = \'1040_plus_schedules\' WHERE form = \'1040 + Schedules\'');
$this->addSql('UPDATE customer_tax_return SET form = \'1120_s\' WHERE form = \'1120-S\'');
$this->addSql('UPDATE customer_tax_return SET form = \'1120_c\' WHERE form = \'1120-C\'');
$this->addSql('UPDATE customer_tax_return SET form = \'1065_p\' WHERE form = \'1065-P\'');
$this->addSql('UPDATE customer_tax_return SET form = \'1041\' WHERE form = \'1041\'');
$this->addSql('UPDATE customer_tax_return SET method = \'amended\' WHERE method = \'Amended\'');
$this->addSql('UPDATE customer_tax_return SET method = \'regular\' WHERE method = \'Regular\'');
$this->addSql('UPDATE customer_tax_return SET type = \'state\' WHERE type = \'State\'');
$this->addSql('UPDATE customer_tax_return SET type = \'federal\' WHERE type = \'Federal\'');
$this->addSql('ALTER TABLE customer_tax_return CHANGE form form ENUM(\'1040_w2\', \'schedule_a\', \'schedule_c\', \'schedule_e\', \'schedule_f\', \'1040_plus_schedules\', \'1120_s\', \'1120_c\', \'1065_p\', \'1041\') DEFAULT NULL COMMENT \'(DC2Type:TaxReturnFormType)\'');
$this->addSql('ALTER TABLE customer_tax_return CHANGE method method ENUM(\'regular\', \'amended\') DEFAULT NULL COMMENT \'(DC2Type:TaxReturnMethodType)\'');
$this->addSql('ALTER TABLE customer_tax_return CHANGE type type ENUM(\'state\', \'federal\') DEFAULT NULL COMMENT \'(DC2Type:TaxReturnType)\'');
$this->addSql('DROP INDEX idx_customers_id ON customer_tax_return');
$this->addSql('DROP INDEX idx_administrators_id ON customer_tax_return');
$this->addSql('CREATE INDEX IDX_168D51269395C3F3 ON customer_tax_return (customer_id)');
$this->addSql('CREATE INDEX IDX_168D5126A76ED395 ON customer_tax_return (user_id)');
$this->addSql('RENAME TABLE customers_upsell_requests TO customer_upsell_request');
$this->addSql('ALTER TABLE customer_upsell_request ENGINE = InnoDB');
$this->addSql('ALTER TABLE customer_upsell_request CHARACTER SET = utf8mb4');
$this->addSql('
ALTER TABLE customer_upsell_request
CHANGE customers_id customer_id INT DEFAULT NULL,
CHANGE from_administrators_id user_id INT DEFAULT NULL,
CHANGE to_administrators_id target_user_id INT DEFAULT NULL,
CHANGE level level_id INT DEFAULT NULL,
CHANGE category category VARCHAR(255) DEFAULT NULL,
CHANGE notes message LONGTEXT DEFAULT NULL,
CHANGE fee fee NUMERIC(10, 2) DEFAULT NULL,
CHANGE status status VARCHAR(255) DEFAULT NULL,
CHANGE date_added created_at DATETIME NOT NULL,
CHANGE last_modified modified_at DATETIME NOT NULL
');
$this->addSql('UPDATE customer_upsell_request SET category = NULL WHERE category = \'0\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'tax_return\' WHERE category = \'1\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'new_poa\' WHERE category = \'2\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'new_debt\' WHERE category = \'3\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'state_issue\' WHERE category = \'4\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'levy\' WHERE category = \'5\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'late_qa\' WHERE category = \'6\'');
$this->addSql('UPDATE customer_upsell_request SET category = \'misc\' WHERE category = \'7\'');
$this->addSql('UPDATE customer_upsell_request SET status = \'open\' WHERE status = \'1\'');
$this->addSql('UPDATE customer_upsell_request SET status = \'close\' WHERE status = \'0\'');
$this->addSql('UPDATE customer_upsell_request SET status = \'sold\' WHERE status = \'2\'');
$this->addSql('ALTER TABLE customer_upsell_request CHANGE category category ENUM(\'tax_return\', \'new_poa\', \'new_debt\', \'state_issue\', \'levy\', \'late_qa\', \'misc\') DEFAULT NULL COMMENT \'(DC2Type:UpsellRequestCategoryType)\'');
$this->addSql('ALTER TABLE customer_upsell_request CHANGE status status ENUM(\'open\', \'close\', \'sold\') DEFAULT NULL COMMENT \'(DC2Type:UpsellRequestStatusType)\'');
$this->addSql('DROP INDEX idx_customers_id ON customer_upsell_request');
$this->addSql('DROP INDEX idx_from_administrators_id ON customer_upsell_request');
$this->addSql('DROP INDEX idx_to_administrators_id ON customer_upsell_request');
$this->addSql('CREATE INDEX IDX_B5C8A21A9395C3F3 ON customer_upsell_request (customer_id)');
$this->addSql('CREATE INDEX IDX_B5C8A21AA76ED395 ON customer_upsell_request (user_id)');
$this->addSql('CREATE INDEX IDX_B5C8A21A6C066AFE ON customer_upsell_request (target_user_id)');
$this->addSql('CREATE INDEX IDX_B5C8A21A5FB14BA7 ON customer_upsell_request (level_id)');
$this->addSql('RENAME TABLE customers_comments TO customer_comment');
$this->addSql('ALTER TABLE customer_comment ENGINE = InnoDB');
$this->addSql('ALTER TABLE customer_comment CHARACTER SET = utf8mb4');
$this->addSql('ALTER TABLE customer_comment ADD modified_at DATETIME DEFAULT NULL');
$this->addSql('UPDATE customer_comment SET modified_at = date_added');
$this->addSql('
ALTER TABLE customer_comment
DROP comments_id,
ADD complaint_id INT DEFAULT NULL,
ADD tax_return_id INT DEFAULT NULL,
ADD upsell_request_id INT DEFAULT NULL,
ADD type ENUM(\'complaint\', \'tax_return\', \'upsell_request\') NOT NULL COMMENT \'(DC2Type:CustomerCommentType)\',
CHANGE customers_id customer_id INT DEFAULT NULL,
CHANGE from_administrators_id user_id INT DEFAULT NULL,
CHANGE to_administrators_id target_user_id INT DEFAULT NULL,
CHANGE comments body LONGTEXT NOT NULL,
CHANGE date_added created_at DATETIME NOT NULL,
CHANGE modified_at modified_at DATETIME NOT NULL
');
$this->addSql('UPDATE customer_comment SET type = \'complaint\', complaint_id = object_id WHERE object_name = \'complaints\'');
$this->addSql('UPDATE customer_comment SET type = \'tax_return\', tax_return_id = object_id WHERE object_name = \'tax_returns\'');
$this->addSql('UPDATE customer_comment SET type = \'upsell_request\', upsell_request_id = object_id WHERE object_name = \'upsell_requests\'');
$this->addSql('
ALTER TABLE customer_comment
DROP object_id,
DROP object_name
');
$this->addSql('DROP INDEX idx_customers_id ON customer_comment');
$this->addSql('DROP INDEX idx_from_administrators_id ON customer_comment');
$this->addSql('DROP INDEX idx_to_administrators_id ON customer_comment');
$this->addSql('CREATE INDEX IDX_88A9F6D29395C3F3 ON customer_comment (customer_id)');
$this->addSql('CREATE INDEX IDX_88A9F6D2A76ED395 ON customer_comment (user_id)');
$this->addSql('CREATE INDEX IDX_88A9F6D26C066AFE ON customer_comment (target_user_id)');
$this->addSql('CREATE INDEX IDX_88A9F6D2EDAE188E ON customer_comment (complaint_id)');
$this->addSql('CREATE INDEX IDX_88A9F6D2E4D1CFF ON customer_comment (tax_return_id)');
$this->addSql('CREATE INDEX IDX_88A9F6D26A6F8AD7 ON customer_comment (upsell_request_id)');
$this->addSql('DELETE FROM customer_comment WHERE customer_id NOT IN (SELECT id FROM customer)');
$this->addSql('UPDATE customer_comment SET user_id = NULL WHERE user_id NOT IN (SELECT id FROM user)');
$this->addSql('UPDATE customer_comment SET target_user_id = NULL WHERE target_user_id NOT IN (SELECT id FROM user)');
$this->addSql('DELETE FROM customer_comment WHERE complaint_id NOT IN (SELECT id FROM customer_complaint)');
$this->addSql('DELETE FROM customer_comment WHERE tax_return_id NOT IN (SELECT id FROM customer_tax_return)');
$this->addSql('DELETE FROM customer_comment WHERE upsell_request_id NOT IN (SELECT id FROM customer_upsell_request)');
$this->addSql('DELETE FROM customer_tax_return WHERE customer_id NOT IN (SELECT id FROM customer)');
$this->addSql('UPDATE customer_tax_return SET user_id = NULL WHERE user_id NOT IN (SELECT id FROM user)');
$this->addSql('DELETE FROM customer_upsell_request WHERE customer_id NOT IN (SELECT id FROM customer)');
$this->addSql('UPDATE customer_upsell_request SET user_id = NULL WHERE user_id NOT IN (SELECT id FROM user)');
$this->addSql('UPDATE customer_upsell_request SET target_user_id = NULL WHERE target_user_id NOT IN (SELECT id FROM user)');
$this->addSql('UPDATE customer_upsell_request SET level_id = NULL WHERE level_id NOT IN (SELECT id FROM config_level)');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D29395C3F3 FOREIGN KEY (customer_id) REFERENCES customer (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D2A76ED395 FOREIGN KEY (user_id) REFERENCES user (id) ON DELETE SET NULL');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D26C066AFE FOREIGN KEY (target_user_id) REFERENCES user (id) ON DELETE SET NULL');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D2EDAE188E FOREIGN KEY (complaint_id) REFERENCES customer_complaint (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D2E4D1CFF FOREIGN KEY (tax_return_id) REFERENCES customer_tax_return (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_comment ADD CONSTRAINT FK_88A9F6D26A6F8AD7 FOREIGN KEY (upsell_request_id) REFERENCES customer_upsell_request (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_tax_return ADD CONSTRAINT FK_168D51269395C3F3 FOREIGN KEY (customer_id) REFERENCES customer (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_tax_return ADD CONSTRAINT FK_168D5126A76ED395 FOREIGN KEY (user_id) REFERENCES user (id) ON DELETE SET NULL');
$this->addSql('ALTER TABLE customer_upsell_request ADD CONSTRAINT FK_B5C8A21A9395C3F3 FOREIGN KEY (customer_id) REFERENCES customer (id) ON DELETE CASCADE');
$this->addSql('ALTER TABLE customer_upsell_request ADD CONSTRAINT FK_B5C8A21AA76ED395 FOREIGN KEY (user_id) REFERENCES user (id) ON DELETE SET NULL');
$this->addSql('ALTER TABLE customer_upsell_request ADD CONSTRAINT FK_B5C8A21A6C066AFE FOREIGN KEY (target_user_id) REFERENCES user (id) ON DELETE SET NULL');
$this->addSql('ALTER TABLE customer_upsell_request ADD CONSTRAINT FK_B5C8A21A5FB14BA7 FOREIGN KEY (level_id) REFERENCES config_level (id) ON DELETE SET NULL');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->abortIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('ALTER TABLE customer_upsell_request DROP FOREIGN KEY FK_B5C8A21A5FB14BA7');
$this->addSql('ALTER TABLE customer_upsell_request DROP FOREIGN KEY FK_B5C8A21A6C066AFE');
$this->addSql('ALTER TABLE customer_upsell_request DROP FOREIGN KEY FK_B5C8A21AA76ED395');
$this->addSql('ALTER TABLE customer_upsell_request DROP FOREIGN KEY FK_B5C8A21A9395C3F3');
$this->addSql('ALTER TABLE customer_tax_return DROP FOREIGN KEY FK_168D5126A76ED395');
$this->addSql('ALTER TABLE customer_tax_return DROP FOREIGN KEY FK_168D51269395C3F3');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D26A6F8AD7');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D2E4D1CFF');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D2EDAE188E');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D26C066AFE');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D2A76ED395');
$this->addSql('ALTER TABLE customer_comment DROP FOREIGN KEY FK_88A9F6D29395C3F3');
$this->addSql('RENAME TABLE customer_tax_return TO customers_tax_returns');
$this->addSql('ALTER TABLE customers_tax_returns ENGINE = InnoDB');
$this->addSql('ALTER TABLE customers_tax_returns CHARACTER SET = utf8mb4');
$this->addSql('
ALTER TABLE customers_tax_returns
DROP created_at,
DROP modified_at,
CHANGE customer_id customers_id INT DEFAULT NULL,
CHANGE user_id administrators_id INT DEFAULT NULL,
CHANGE type year_type VARCHAR(255) DEFAULT NULL,
CHANGE method method VARCHAR(255) DEFAULT NULL,
CHANGE form type VARCHAR(255) DEFAULT NULL,
CHANGE year year SMALLINT(6) DEFAULT NULL,
CHANGE biz is_biz TINYINT(1) DEFAULT \'0\',
CHANGE completed_at completed_date DATE DEFAULT NULL
');
$this->addSql('UPDATE customers_tax_returns SET type = \'1040 W2\' WHERE type = \'1040_w2\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'Schedule A\' WHERE type = \'schedule_a\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'Schedule C\' WHERE type = \'schedule_c\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'Schedule E\' WHERE type = \'schedule_e\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'Schedule F\' WHERE type = \'schedule_f\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'1040 + Schedules\' WHERE type = \'1040_plus_schedules\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'1120-S\' WHERE type = \'1120_s\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'1120-C\' WHERE type = \'1120_c\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'1065-P\' WHERE type = \'1065_p\'');
$this->addSql('UPDATE customers_tax_returns SET type = \'1041\' WHERE type = \'1041\'');
$this->addSql('UPDATE customers_tax_returns SET method = \'Amended\' WHERE method = \'amended\'');
$this->addSql('UPDATE customers_tax_returns SET method = \'Regular\' WHERE method = \'regular\'');
$this->addSql('UPDATE customers_tax_returns SET year_type = \'State\' WHERE year_type = \'state\'');
$this->addSql('UPDATE customers_tax_returns SET year_type = \'Federal\' WHERE year_type = \'federal\'');
$this->addSql('ALTER TABLE customers_tax_returns CHANGE type type ENUM(\'1040 W2\', \'Schedule A\', \'Schedule C\', \'Schedule E\', \'Schedule F\', \'1040 + Schedules\', \'1120-S\', \'1120-C\', \'1065-P\', \'1041\') DEFAULT NULL');
$this->addSql('ALTER TABLE customers_tax_returns CHANGE method method ENUM(\'Regular\', \'Amended\') DEFAULT \'Regular\'');
$this->addSql('ALTER TABLE customers_tax_returns CHANGE year_type year_type ENUM(\'State\', \'Federal\') DEFAULT \'Federal\'');
$this->addSql('DROP INDEX IDX_168D51269395C3F3 ON customers_tax_returns');
$this->addSql('DROP INDEX IDX_168D5126A76ED395 ON customers_tax_returns');
$this->addSql('CREATE INDEX idx_customers_id ON customers_tax_returns (customers_id)');
$this->addSql('CREATE INDEX idx_administrators_id ON customers_tax_returns (administrators_id)');
$this->addSql('RENAME TABLE customer_upsell_request TO customers_upsell_requests');
$this->addSql('ALTER TABLE customers_upsell_requests ENGINE = InnoDB');
$this->addSql('ALTER TABLE customers_upsell_requests CHARACTER SET = utf8mb4');
$this->addSql('
ALTER TABLE customers_upsell_requests
CHANGE customer_id customers_id INT NOT NULL,
CHANGE user_id from_administrators_id INT NOT NULL,
CHANGE target_user_id to_administrators_id INT NOT NULL,
CHANGE level_id level TINYINT(1) DEFAULT \'0\',
CHANGE category category VARCHAR(255) DEFAULT NULL,
CHANGE message notes TEXT DEFAULT NULL,
CHANGE fee fee INT DEFAULT NULL,
CHANGE status status VARCHAR(255) DEFAULT NULL,
CHANGE created_at date_added DATETIME DEFAULT NULL,
CHANGE modified_at last_modified DATETIME DEFAULT NULL
');
$this->addSql('UPDATE customers_upsell_requests SET category = \'1\' WHERE category = \'tax_return\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'2\' WHERE category = \'new_poa\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'3\' WHERE category = \'new_debt\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'4\' WHERE category = \'state_issue\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'5\' WHERE category = \'levy\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'6\' WHERE category = \'late_qa\'');
$this->addSql('UPDATE customers_upsell_requests SET category = \'7\' WHERE category = \'misc\'');
$this->addSql('UPDATE customers_upsell_requests SET status = \'1\' WHERE status = \'open\'');
$this->addSql('UPDATE customers_upsell_requests SET status = \'0\' WHERE status = \'close\'');
$this->addSql('UPDATE customers_upsell_requests SET status = \'2\' WHERE status = \'sold\'');
$this->addSql('ALTER TABLE customers_upsell_requests CHANGE category category TINYINT(1) DEFAULT \'0\'');
$this->addSql('ALTER TABLE customers_upsell_requests CHANGE status status TINYINT(1) DEFAULT \'0\'');
$this->addSql('DROP INDEX IDX_B5C8A21A9395C3F3 ON customers_upsell_requests');
$this->addSql('DROP INDEX IDX_B5C8A21AA76ED395 ON customers_upsell_requests');
$this->addSql('DROP INDEX IDX_B5C8A21A6C066AFE ON customers_upsell_requests');
$this->addSql('DROP INDEX IDX_B5C8A21A5FB14BA7 ON customers_upsell_requests');
$this->addSql('CREATE INDEX idx_from_administrators_id ON customers_upsell_requests (from_administrators_id)');
$this->addSql('CREATE INDEX idx_to_administrators_id ON customers_upsell_requests (to_administrators_id)');
$this->addSql('CREATE INDEX idx_customers_id ON customers_upsell_requests (customers_id)');
$this->addSql('RENAME TABLE customer_comment TO customers_comments');
$this->addSql('ALTER TABLE customers_comments ENGINE = InnoDB');
$this->addSql('ALTER TABLE customers_comments CHARACTER SET = utf8mb4');
$this->addSql('
ALTER TABLE customers_comments
DROP modified_at,
ADD object_name VARCHAR(255) DEFAULT NULL AFTER customers_id,
ADD object_id INT NOT NULL AFTER object_name,
ADD comments_id INT NOT NULL AFTER object_id,
CHANGE customer_id customers_id INT NOT NULL,
CHANGE user_id from_administrators_id INT NOT NULL,
CHANGE target_user_id to_administrators_id INT NOT NULL,
CHANGE body comments TEXT DEFAULT NULL,
CHANGE created_at date_added DATETIME DEFAULT NULL
');
$this->addSql('UPDATE customers_comments SET object_name = \'complaints\', object_id = complaint_id WHERE type = \'complaint\'');
$this->addSql('UPDATE customers_comments SET object_name = \'tax_returns\', object_id = tax_return_id WHERE type = \'tax_return\'');
$this->addSql('UPDATE customers_comments SET object_name = \'upsell_requests\', object_id = upsell_request_id WHERE type = \'upsell_request\'');
$this->addSql('
ALTER TABLE customers_comments
DROP complaint_id,
DROP tax_return_id,
DROP upsell_request_id,
DROP type
');
$this->addSql('DROP INDEX IDX_88A9F6D29395C3F3 ON customers_comments');
$this->addSql('DROP INDEX IDX_88A9F6D2A76ED395 ON customers_comments');
$this->addSql('DROP INDEX IDX_88A9F6D26C066AFE ON customers_comments');
$this->addSql('CREATE INDEX idx_customers_id ON customers_comments (customers_id)');
$this->addSql('CREATE INDEX idx_object ON customers_comments (object_name, object_id)');
$this->addSql('CREATE INDEX idx_comments_id ON customers_comments (comments_id)');
$this->addSql('CREATE INDEX idx_from_administrators_id ON customers_comments (from_administrators_id)');
$this->addSql('CREATE INDEX idx_to_administrators_id ON customers_comments (to_administrators_id)');
}
}