Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
e2f8d8e0e7
|
@ -441,6 +441,7 @@ class ApiController extends Zend_Controller_Action
|
|||
try {
|
||||
$show_inst = new Application_Model_ShowInstance($show_instance_id);
|
||||
$show_inst->setRecordedFile($file_id);
|
||||
//$show_start_time = Application_Common_DateHelper::ConvertToLocalDateTimeString($show_inst->getShowInstanceStart());
|
||||
|
||||
} catch (Exception $e) {
|
||||
//we've reached here probably because the show was
|
||||
|
@ -563,13 +564,14 @@ class ApiController extends Zend_Controller_Action
|
|||
// to some unique id.
|
||||
$request = $this->getRequest();
|
||||
$responses = array();
|
||||
$params = $request->getParams();
|
||||
//$params = $request->getParams();
|
||||
$valid_modes = array('delete_dir', 'delete', 'moved', 'modify', 'create');
|
||||
foreach ($params as $k => $raw_json) {
|
||||
// Valid requests must start with mdXXX where XXX represents at
|
||||
// least 1 digit
|
||||
if ( !preg_match('/^md\d+$/', $k) ) { continue; }
|
||||
$info_json = json_decode($raw_json, $assoc = true);
|
||||
unset( $info_json["is_record"] );
|
||||
// Log invalid requests
|
||||
if ( !array_key_exists('mode', $info_json) ) {
|
||||
Logging::info("Received bad request(key=$k), no 'mode' parameter. Bad request is:");
|
||||
|
|
|
@ -270,7 +270,7 @@ class LibraryController extends Zend_Controller_Action
|
|||
$mediaItems = $this->_getParam('media', null);
|
||||
|
||||
$user = Application_Model_User::getCurrentUser();
|
||||
$isAdminOrPM = $user->isUserType(array(UTYPE_ADMIN, UTYPE_PROGRAM_MANAGER));
|
||||
//$isAdminOrPM = $user->isUserType(array(UTYPE_ADMIN, UTYPE_PROGRAM_MANAGER));
|
||||
|
||||
$files = array();
|
||||
$playlists = array();
|
||||
|
|
|
@ -298,7 +298,6 @@ class PlaylistController extends Zend_Controller_Action
|
|||
$ids = $this->_getParam('ids');
|
||||
$ids = (!is_array($ids)) ? array($ids) : $ids;
|
||||
$afterItem = $this->_getParam('afterItem', null);
|
||||
$modified = $this->_getParam('modified');
|
||||
$type = $this->_getParam('obj_type');
|
||||
|
||||
try {
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -353,7 +353,7 @@ var AIRTIME = (function(AIRTIME) {
|
|||
var label = "";
|
||||
if (ele.mDataProp == "bit_rate") {
|
||||
label = " (bps)";
|
||||
} else if (ele.mDataProp == "utime" || ele.mDataPro == "mtime" || ele.mDataPro == "lptime") {
|
||||
} else if (ele.mDataProp == "utime" || ele.mDataProp == "mtime" || ele.mDataProp == "lptime") {
|
||||
label = " (yyyy-mm-dd)";
|
||||
} else if (ele.mDataProp == "length") {
|
||||
label = " (hh:mm:ss.t)";
|
||||
|
|
|
@ -58,7 +58,7 @@ def get_file_type(file_path):
|
|||
elif re.search(r'flac$', file_path, re.IGNORECASE):
|
||||
file_type = 'flac'
|
||||
else:
|
||||
mime_type = get_mime_type(file_path) == "audio/mpeg"
|
||||
mime_type = get_mime_type(file_path)
|
||||
if 'mpeg' in mime_type:
|
||||
file_type = 'mp3'
|
||||
elif 'ogg' in mime_type:
|
||||
|
|
Loading…
Reference in New Issue