aboutsummaryrefslogtreecommitdiffhomepage
path: root/migrations
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2015-01-20 07:40:39 +0100
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2015-01-20 07:40:39 +0100
commit6ad93dff69d7c2beb2196e73f641e6484fccbeb7 (patch)
tree12430b858be2a41029fc11d1afa1fa2a120b96f9 /migrations
parentc78c1a3f08815aab99752026ccdf1dcf63cf43c1 (diff)
downloadwallabag-6ad93dff69d7c2beb2196e73f641e6484fccbeb7.tar.gz
wallabag-6ad93dff69d7c2beb2196e73f641e6484fccbeb7.tar.zst
wallabag-6ad93dff69d7c2beb2196e73f641e6484fccbeb7.zip
new folders
Diffstat (limited to 'migrations')
-rw-r--r--migrations/20150119171459_init_database.php27
1 files changed, 27 insertions, 0 deletions
diff --git a/migrations/20150119171459_init_database.php b/migrations/20150119171459_init_database.php
new file mode 100644
index 00000000..48a7d4b6
--- /dev/null
+++ b/migrations/20150119171459_init_database.php
@@ -0,0 +1,27 @@
1<?php
2
3use Phinx\Migration\AbstractMigration;
4
5class InitDatabase extends AbstractMigration
6{
7 /**
8 * Migrate Up.
9 */
10 public function up()
11 {
12 $this->execute("CREATE TABLE IF NOT EXISTS `montest` (
13 `id` int(11) NOT NULL AUTO_INCREMENT,
14 `name` varchar(255) NOT NULL,
15 `value` varchar(255) NOT NULL,
16 PRIMARY KEY (`id`)
17) ENGINE=InnoDB DEFAULT CHARSET=utf8;");
18 }
19
20 /**
21 * Migrate Down.
22 */
23 public function down()
24 {
25 $this->execute("DROP DATABASE montest;");
26 }
27} \ No newline at end of file