CC-3817 : Should use soundcloud icon for recorded & uploaded shows in timeline for past shows to match calendar

This commit is contained in:
Naomi Aro 2012-05-14 15:06:56 +02:00
parent cc71c61fce
commit ff5aebfd6b
3 changed files with 15 additions and 3 deletions
airtime_mvc
application/models
public/js/airtime/showbuilder

View File

@ -246,7 +246,7 @@ class Application_Model_Schedule {
si.starts AS si_starts, si.ends AS si_ends, si.time_filled AS si_time_filled,
si.record AS si_record, si.rebroadcast AS si_rebroadcast, si.instance_id AS parent_show,
si.id AS si_id, si.last_scheduled AS si_last_scheduled,
si.id AS si_id, si.last_scheduled AS si_last_scheduled, si.file_id AS si_file_id,
sched.starts AS sched_starts, sched.ends AS sched_ends, sched.id AS sched_id,
sched.cue_in AS cue_in, sched.cue_out AS cue_out,
@ -274,6 +274,8 @@ class Application_Model_Schedule {
}
$sql .= " ORDER BY si.starts, sched.starts;";
Logging::debug($sql);
$rows = $con->query($sql)->fetchAll();
return $rows;

View File

@ -175,6 +175,12 @@ class Application_Model_ShowBuilder {
}
else if (intval($p_item["si_record"]) === 1) {
$row["record"] = true;
if (Application_Model_Preference::GetUploadToSoundcloudOption()) {
$file = Application_Model_StoredFile::Recall($p_item["si_file_id"]);
$sid = $file->getSoundCloudId();
$row["soundcloud_id"] = $sid;
}
}
if ($startsEpoch < $this->epoch_now && $endsEpoch > $this->epoch_now) {

View File

@ -339,7 +339,8 @@ var AIRTIME = (function(AIRTIME){
r,g,b,a,
$nRow = $(nRow),
$image,
$div;
$div,
headerIcon;
fnPrepareSeparatorRow = function fnPrepareSeparatorRow(sRowContent, sClass, iNodeIndex) {
@ -364,8 +365,11 @@ var AIRTIME = (function(AIRTIME){
cl = 'sb-header';
if (aData.record === true) {
headerIcon = (aData.soundcloud_id > 0) ? "soundcloud" : "recording";
$div = $("<div/>", {
"class": "small-icon recording"
"class": "small-icon " + headerIcon
});
$node.append($div);
}