Merge branch 'devel' of dev.sourcefabric.org:airtime into devel

This commit is contained in:
James 2012-04-17 15:43:39 -04:00
commit 5df1fede9f
23 changed files with 239 additions and 115 deletions

View file

@ -65,7 +65,8 @@ class Application_Model_PlayoutHistory {
$historyTable = "(
select count(schedule.file_id) as played, schedule.file_id as file_id
from cc_schedule as schedule
where schedule.starts >= '{$start}' and schedule.starts < '{$end}'
where schedule.starts >= '{$start}' and schedule.starts < '{$end}'
and schedule.playout_status > 0 and schedule.media_item_played != FALSE
group by schedule.file_id
)
AS playout left join cc_files as file on (file.id = playout.file_id)";

View file

@ -446,7 +446,7 @@ class Application_Model_Schedule {
Logging::debug("Get Schedule: Less than 3 results returned. Do another query in an attempt to get 3.");
$dt = new DateTime("@".time());
$dt->add(new DateInterval("PT30M"));
$dt->add(new DateInterval("PT24H"));
$range_end = $dt->format("Y-m-d H:i:s");
$predicates = " WHERE st.ends > '$p_startTime'"