From 6ccd8c11faff4a8b5209b45c140d12f94d97449b Mon Sep 17 00:00:00 2001 From: Busfreak Date: Tue, 5 Jul 2016 17:09:13 +0200 Subject: Hide tasks within specific columns in dashboard (#2424) --- app/Schema/Mysql.php | 7 ++++++- app/Schema/Postgres.php | 7 ++++++- app/Schema/Sql/mysql.sql | 1 + app/Schema/Sql/postgres.sql | 1 + app/Schema/Sqlite.php | 7 ++++++- 5 files changed, 20 insertions(+), 3 deletions(-) (limited to 'app/Schema') 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) { -- cgit v1.2.3