3 namespace Application\Migrations
;
5 use Doctrine\DBAL\Migrations\AbstractMigration
;
6 use Doctrine\DBAL\Schema\Schema
;
9 * Auto-generated Migration: Please modify to your needs!
11 class Version20160120200534_settings
extends AbstractMigration
14 * @param Schema $schema
16 public function up(Schema
$schema)
18 // this up() migration is auto-generated, please modify it to your needs
19 $this->abortIf($this->connection
->getDatabasePlatform()->getName() != 'mysql', 'Migration can only be executed safely on \'mysql\'.');
21 $this->addSql('CREATE TABLE craue_config_setting (name VARCHAR(255) NOT NULL, value VARCHAR(255) DEFAULT NULL, section VARCHAR(255) DEFAULT NULL, UNIQUE INDEX UNIQ_B95BA9425E237E06 (name), PRIMARY KEY(name)) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB');
22 $this->addSql("INSERT INTO `craue_config_setting` (`name`, `value`, `section`) VALUES
23 ('download_pictures', '1', 'entry'),
24 ('carrot', '1', 'entry'),
25 ('share_diaspora', '1', 'entry'),
26 ('diaspora_url', 'http://diasporapod.com', 'entry'),
27 ('share_shaarli', '1', 'entry'),
28 ('shaarli_url', 'http://myshaarli.com', 'entry'),
29 ('share_mail', '1', 'entry'),
30 ('share_twitter', '1', 'entry'),
31 ('export_epub', '1', 'export'),
32 ('export_mobi', '1', 'export'),
33 ('export_pdf', '1', 'export'),
34 ('pocket_consumer_key', NULL, 'import'),
35 ('show_printlink', '1', 'entry'),
36 ('wallabag_support_url', 'https://www.wallabag.org/pages/support.html', 'misc'),
37 ('wallabag_url', 'http://v2.wallabag.org', 'misc')"
42 * @param Schema $schema
44 public function down(Schema
$schema)
46 // this down() migration is auto-generated, please modify it to your needs
47 $this->abortIf($this->connection
->getDatabasePlatform()->getName() != 'mysql', 'Migration can only be executed safely on \'mysql\'.');
49 $this->addSql('DROP TABLE craue_config_setting');