summaryrefslogtreecommitdiff
path: root/app/Schema
diff options
context:
space:
mode:
authorBusfreak <Busfreak@users.noreply.github.com>2016-07-05 17:09:13 +0200
committerFrédéric Guillot <fred@kanboard.net>2016-07-05 11:09:13 -0400
commit6ccd8c11faff4a8b5209b45c140d12f94d97449b (patch)
tree74fda85e7f5d1ab359e4aa77c8b944e92da59805 /app/Schema
parentb215296f971eaf35773218740d3d6696f8dc2310 (diff)
Hide tasks within specific columns in dashboard (#2424)
Diffstat (limited to 'app/Schema')
-rw-r--r--app/Schema/Mysql.php7
-rw-r--r--app/Schema/Postgres.php7
-rw-r--r--app/Schema/Sql/mysql.sql1
-rw-r--r--app/Schema/Sql/postgres.sql1
-rw-r--r--app/Schema/Sqlite.php7
5 files changed, 20 insertions, 3 deletions
diff --git a/app/Schema/Mysql.php b/app/Schema/Mysql.php
index 82ccb8c8..99fed66f 100644
--- a/app/Schema/Mysql.php
+++ b/app/Schema/Mysql.php
@@ -6,7 +6,12 @@ use PDO;
use Kanboard\Core\Security\Token;
use Kanboard\Core\Security\Role;
-const VERSION = 111;
+const VERSION = 112;
+
+function version_112(PDO $pdo)
+{
+ $pdo->exec('ALTER TABLE columns ADD COLUMN hide_in_dashboard INT DEFAULT 0 NOT NULL');
+}
function version_111(PDO $pdo)
{
diff --git a/app/Schema/Postgres.php b/app/Schema/Postgres.php
index 229cbd25..b982bcae 100644
--- a/app/Schema/Postgres.php
+++ b/app/Schema/Postgres.php
@@ -6,7 +6,12 @@ use PDO;
use Kanboard\Core\Security\Token;
use Kanboard\Core\Security\Role;
-const VERSION = 90;
+const VERSION = 91;
+
+function version_91(PDO $pdo)
+{
+ $pdo->exec("ALTER TABLE columns ADD COLUMN hide_in_dashboard BOOLEAN DEFAULT '0'");
+}
function version_90(PDO $pdo)
{
diff --git a/app/Schema/Sql/mysql.sql b/app/Schema/Sql/mysql.sql
index 9583989d..8d2f2dc0 100644
--- a/app/Schema/Sql/mysql.sql
+++ b/app/Schema/Sql/mysql.sql
@@ -44,6 +44,7 @@ CREATE TABLE `columns` (
`position` int(11) NOT NULL,
`project_id` int(11) NOT NULL,
`task_limit` int(11) DEFAULT '0',
+ `hide_in_dashboard` int(11) DEFAULT '0',
`description` text,
PRIMARY KEY (`id`),
UNIQUE KEY `idx_title_project` (`title`,`project_id`),
diff --git a/app/Schema/Sql/postgres.sql b/app/Schema/Sql/postgres.sql
index 94239054..ae8b4fd5 100644
--- a/app/Schema/Sql/postgres.sql
+++ b/app/Schema/Sql/postgres.sql
@@ -98,6 +98,7 @@ CREATE TABLE "columns" (
"position" integer,
"project_id" integer NOT NULL,
"task_limit" integer DEFAULT 0,
+ "hide_in_dashboard" integer DEFAULT 0,
"description" "text"
);
diff --git a/app/Schema/Sqlite.php b/app/Schema/Sqlite.php
index dac348d4..2a7735ee 100644
--- a/app/Schema/Sqlite.php
+++ b/app/Schema/Sqlite.php
@@ -6,7 +6,12 @@ use Kanboard\Core\Security\Token;
use Kanboard\Core\Security\Role;
use PDO;
-const VERSION = 102;
+const VERSION = 103;
+
+function version_103(PDO $pdo)
+{
+ $pdo->exec("ALTER TABLE columns ADD COLUMN hide_in_dashboard INTEGER DEFAULT 0 NOT NULL");
+}
function version_102(PDO $pdo)
{