Sylius/app/migrations/Version20151028183600.php
2015-11-10 07:26:59 +00:00

33 lines
1.3 KiB
PHP

<?php
namespace Sylius\Migrations;
use Doctrine\DBAL\Migrations\AbstractMigration;
use Doctrine\DBAL\Schema\Schema;
/**
* Auto-generated Migration: Please modify to your needs!
*/
class Version20151028183600 extends AbstractMigration
{
/**
* @param Schema $schema
*/
public function up(Schema $schema)
{
$this->addSql("ALTER TABLE sylius_payment_security_token CHANGE payment_name gateway_name VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '';");
$this->addSql("ALTER TABLE sylius_payment_config CHANGE payment_name gateway_name VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '';");
$this->addSql('RENAME TABLE `sylius_payment_config` TO `sylius_gateway_config`;');
}
/**
* @param Schema $schema
*/
public function down(Schema $schema)
{
$this->addSql("ALTER TABLE payment_name gateway_name CHANGE sylius_payment_security_token VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '';");
$this->addSql("ALTER TABLE payment_name gateway_name CHANGE sylius_payment_config VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT '';");
$this->addSql('RENAME TABLE `sylius_gateway_config` TO `sylius_payment_config`;');
}
}