cc-2167: now playing view with recording shows a gap
-implemented
This commit is contained in:
parent
1337efcdcd
commit
9638f6dd3e
5 changed files with 24 additions and 39 deletions
|
@ -32,6 +32,10 @@ class Application_Model_Nowplaying
|
|||
public static function CreateGapRow($p_gapTime){
|
||||
return array("g", $p_gapTime, "", "", "", "", "", "", "", "", "");
|
||||
}
|
||||
|
||||
public static function CreateRecordingRow($p_showInstance){
|
||||
return array("r", $p_showInstance->getName(), "", "", "", "", "", "", "", "", "");
|
||||
}
|
||||
|
||||
public static function GetDataGridData($viewType, $dateString){
|
||||
|
||||
|
@ -73,7 +77,9 @@ class Application_Model_Nowplaying
|
|||
|
||||
//append show gap time row
|
||||
$gapTime = $si->getShowEndGapTime();
|
||||
if ($gapTime > 0)
|
||||
if ($si->isRecorded())
|
||||
$data[] = Application_Model_Nowplaying::CreateRecordingRow($si);
|
||||
else if ($gapTime > 0)
|
||||
$data[] = Application_Model_Nowplaying::CreateGapRow($gapTime);
|
||||
}
|
||||
|
||||
|
|
|
@ -424,16 +424,6 @@ class Schedule {
|
|||
." ON si.show_id = show.id"
|
||||
." WHERE st.starts < si.ends";
|
||||
|
||||
/*
|
||||
$sql = "SELECT DISTINCT pt.name, ft.track_title, ft.artist_name, ft.album_title, st.starts, st.ends, st.clip_length, st.media_item_played, st.group_id, show.name as show_name, st.instance_id"
|
||||
." FROM $CC_CONFIG[scheduleTable] st, $CC_CONFIG[filesTable] ft, $CC_CONFIG[playListTable] pt, $CC_CONFIG[showInstances] si, $CC_CONFIG[showTable] show"
|
||||
." WHERE st.playlist_id = pt.id"
|
||||
." AND st.file_id = ft.id"
|
||||
." AND st.instance_id = si.id"
|
||||
." AND si.show_id = show.id"
|
||||
." AND st.starts < si.ends";
|
||||
*/
|
||||
|
||||
if ($timePeriod < 0){
|
||||
$sql .= " AND st.ends < TIMESTAMP '$timeStamp'"
|
||||
." AND st.ends > (TIMESTAMP '$timeStamp' - INTERVAL '$interval')"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue