From 76b2f6e80b7094028ab7ba8316b685ad3a1178d5 Mon Sep 17 00:00:00 2001 From: naomiaro Date: Sat, 5 Feb 2011 23:49:27 -0500 Subject: [PATCH] order by didn't work for full calendar --- application/models/Shows.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/application/models/Shows.php b/application/models/Shows.php index 0bd66e28a..cc2e2adb9 100644 --- a/application/models/Shows.php +++ b/application/models/Shows.php @@ -119,8 +119,7 @@ class Show { FROM cc_show_instances LEFT JOIN cc_show ON cc_show.id = cc_show_instances.show_id WHERE ((starts >= '{$start_timestamp}' AND starts < '{$end_timestamp}') - OR (ends > '{$start_timestamp}' AND ends <= '{$end_timestamp}')) - ORDER BY starts"; + OR (ends > '{$start_timestamp}' AND ends <= '{$end_timestamp}')); if(isset($excludeInstance)) { foreach($excludeInstance as $instance) { @@ -132,7 +131,7 @@ class Show { $sql = $sql." AND ({$exclude})"; } - //echo $sql; + echo $sql; return $CC_DBC->GetAll($sql); }