Merge branch '2.3.x' into 2.3.x-saas
Conflicts: airtime_mvc/application/models/User.php
This commit is contained in:
commit
0a198ae424
20 changed files with 184 additions and 51 deletions
|
@ -696,6 +696,10 @@ SQL;
|
|||
'replay_gain' => $replay_gain,
|
||||
'independent_event' => $independent_event,
|
||||
);
|
||||
|
||||
if ($schedule_item['cue_in'] > $schedule_item['cue_out']) {
|
||||
$schedule_item['cue_in'] = $schedule_item['cue_out'];
|
||||
}
|
||||
self::appendScheduleItem($data, $start, $schedule_item);
|
||||
}
|
||||
|
||||
|
@ -906,7 +910,6 @@ SQL;
|
|||
self::createScheduledEvents($data, $range_start, $range_end);
|
||||
|
||||
self::foldData($data["media"]);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
|
|
@ -136,13 +136,17 @@ class Application_Model_Scheduler
|
|||
|
||||
if ($type === "audioclip") {
|
||||
$file = CcFilesQuery::create()->findPK($id, $this->con);
|
||||
$storedFile = new Application_Model_StoredFile($file->getDbId());
|
||||
|
||||
if (is_null($file) || !$file->visible()) {
|
||||
throw new Exception(_("A selected File does not exist!"));
|
||||
} else {
|
||||
$data = $this->fileInfo;
|
||||
$data["id"] = $id;
|
||||
$data["cliplength"] = $file->getDbLength();
|
||||
$data["cliplength"] = $storedFile->getRealClipLength(
|
||||
$file->getDbCuein(),
|
||||
$file->getDbCueout());
|
||||
|
||||
$data["cuein"] = $file->getDbCuein();
|
||||
$data["cueout"] = $file->getDbCueout();
|
||||
|
||||
|
@ -438,7 +442,6 @@ class Application_Model_Scheduler
|
|||
}
|
||||
|
||||
foreach ($schedFiles as $file) {
|
||||
|
||||
$endTimeDT = $this->findEndTime($nextStartDT, $file['cliplength']);
|
||||
|
||||
//item existed previously and is being moved.
|
||||
|
|
|
@ -227,7 +227,7 @@ class Application_Model_ShowBuilder
|
|||
$row["endDate"] = $showEndDT->format("Y-m-d");
|
||||
$row["endTime"] = $showEndDT->format("H:i");
|
||||
$row["duration"] = floatval($showEndDT->format("U.u")) - floatval($showStartDT->format("U.u"));
|
||||
$row["title"] = $p_item["show_name"];
|
||||
$row["title"] = htmlspecialchars($p_item["show_name"]);
|
||||
$row["instance"] = intval($p_item["si_id"]);
|
||||
$row["image"] = '';
|
||||
|
||||
|
|
|
@ -1285,6 +1285,14 @@ SQL;
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
public function getRealClipLength($p_cuein, $p_cueout) {
|
||||
$sql = "SELECT :cueout::INTERVAL - :cuein::INTERVAL";
|
||||
|
||||
return Application_Common_Database::prepareAndExecute($sql, array(
|
||||
':cueout' => $p_cueout,
|
||||
':cuein' => $p_cuein), 'column');
|
||||
}
|
||||
}
|
||||
|
||||
class DeleteScheduledFileException extends Exception {}
|
||||
|
|
|
@ -343,6 +343,8 @@ class Application_Model_User
|
|||
$res['iTotalDisplayRecords']--;
|
||||
$res['iTotalRecords']--;
|
||||
}
|
||||
|
||||
$record = array_map('htmlspecialchars', $record);
|
||||
}
|
||||
|
||||
$res['aaData'] = array_values($res['aaData']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue