From 7cbae61dbddefb98f1c5b412d8d72bf5ad883ac9 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Sun, 29 Mar 2015 13:51:51 -0400 Subject: Add Hipchat integration --- app/Schema/Mysql.php | 11 ++++++++++- app/Schema/Postgres.php | 11 ++++++++++- app/Schema/Sqlite.php | 11 ++++++++++- 3 files changed, 30 insertions(+), 3 deletions(-) (limited to 'app/Schema') diff --git a/app/Schema/Mysql.php b/app/Schema/Mysql.php index dc0b8b42..f0e0d6b2 100644 --- a/app/Schema/Mysql.php +++ b/app/Schema/Mysql.php @@ -6,7 +6,16 @@ use PDO; use Core\Security; use Model\Link; -const VERSION = 58; +const VERSION = 59; + +function version_59($pdo) +{ + $rq = $pdo->prepare('INSERT INTO settings VALUES (?, ?)'); + $rq->execute(array('integration_hipchat', '0')); + $rq->execute(array('integration_hipchat_api_url', 'https://api.hipchat.com')); + $rq->execute(array('integration_hipchat_room_id', '')); + $rq->execute(array('integration_hipchat_room_token', '')); +} function version_58($pdo) { diff --git a/app/Schema/Postgres.php b/app/Schema/Postgres.php index ea7b84d1..f7a0453d 100644 --- a/app/Schema/Postgres.php +++ b/app/Schema/Postgres.php @@ -6,7 +6,16 @@ use PDO; use Core\Security; use Model\Link; -const VERSION = 39; +const VERSION = 40; + +function version_40($pdo) +{ + $rq = $pdo->prepare('INSERT INTO settings VALUES (?, ?)'); + $rq->execute(array('integration_hipchat', '0')); + $rq->execute(array('integration_hipchat_api_url', 'https://api.hipchat.com')); + $rq->execute(array('integration_hipchat_room_id', '')); + $rq->execute(array('integration_hipchat_room_token', '')); +} function version_39($pdo) { diff --git a/app/Schema/Sqlite.php b/app/Schema/Sqlite.php index 1ffd9405..3ad045e6 100644 --- a/app/Schema/Sqlite.php +++ b/app/Schema/Sqlite.php @@ -6,7 +6,16 @@ use Core\Security; use PDO; use Model\Link; -const VERSION = 57; +const VERSION = 58; + +function version_58($pdo) +{ + $rq = $pdo->prepare('INSERT INTO settings VALUES (?, ?)'); + $rq->execute(array('integration_hipchat', '0')); + $rq->execute(array('integration_hipchat_api_url', 'https://api.hipchat.com')); + $rq->execute(array('integration_hipchat_room_id', '')); + $rq->execute(array('integration_hipchat_room_token', '')); +} function version_57($pdo) { -- cgit v1.2.3