From 192bc861150f6a0367aa07533121d7f33886ef4c Mon Sep 17 00:00:00 2001 From: "paul.baranowski" Date: Mon, 18 Oct 2010 16:00:31 +0200 Subject: [PATCH 1/2] Fixed a bug in campcaster-import: "require_once" statements were out of order. Fixed bug in statusbar.tpl - syntax error. --- htmlUI/templates/statusbar.tpl | 2 +- utils/campcaster-import.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/htmlUI/templates/statusbar.tpl b/htmlUI/templates/statusbar.tpl index bf736e505..d314f9afb 100644 --- a/htmlUI/templates/statusbar.tpl +++ b/htmlUI/templates/statusbar.tpl @@ -9,7 +9,7 @@ - {assign var="_now value=$SCHEDULER->getSchedulerTime(true)} + {assign var="_now" value=$SCHEDULER->getSchedulerTime()} {if !$_now} {assign var="_now" value=$smarty.now} {/if} diff --git a/utils/campcaster-import.php b/utils/campcaster-import.php index a5f3e2746..50e1735f7 100644 --- a/utils/campcaster-import.php +++ b/utils/campcaster-import.php @@ -12,10 +12,10 @@ set_time_limit(0); error_reporting(E_ALL); set_error_handler("camp_import_error_handler", E_ALL & !E_NOTICE); -require_once('DB.php'); -require_once('Console/Getopt.php'); require_once(dirname(__FILE__)."/../conf.php"); require_once(dirname(__FILE__)."/../backend/GreenBox.php"); +require_once('DB.php'); +require_once('Console/Getopt.php'); function camp_import_error_handler() { From e428535d330ce9320e4b3561ee71d8dce3306497 Mon Sep 17 00:00:00 2001 From: "paul.baranowski" Date: Mon, 18 Oct 2010 19:16:37 +0200 Subject: [PATCH 2/2] Added "schedule_group_id_seq" to the install process. Was missing, oops! --- install/install.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/install/install.php b/install/install.php index 1dda825b7..45780c181 100644 --- a/install/install.php +++ b/install/install.php @@ -471,10 +471,18 @@ if (!camp_db_table_exists($CC_CONFIG['scheduleTable'])) { ." CONSTRAINT cc_schedule_pkey PRIMARY KEY (id)," ." CONSTRAINT unique_id UNIQUE (id))"; camp_install_query($sql); + } else { echo " * Skipping: database table already exists: ".$CC_CONFIG['scheduleTable']."\n"; } +if (!camp_db_sequence_exists("schedule_group_id_seq")) { + echo " * Creating sequence 'schedule_group_id_seq'..."; + $sql = "CREATE SEQUENCE schedule_group_id_seq"; + camp_install_query($sql); +} else { + echo " * Skipping: sequence already exists 'schedule_group_id_seq'.\n"; +} if (!camp_db_table_exists($CC_CONFIG['backupTable'])) { echo " * Creating database table ".$CC_CONFIG['backupTable']."...";