From b588b3b9a441c15e030d3ff5c4d87ccbcf7730da Mon Sep 17 00:00:00 2001 From: denise Date: Tue, 12 Jun 2012 14:40:18 -0400 Subject: [PATCH 1/4] CC-3849: PlaylistLibrary->Edit Metadata: The deletion of metadata entries has no effect after saving -set track_number as a required field on form --- airtime_mvc/application/forms/EditAudioMD.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/airtime_mvc/application/forms/EditAudioMD.php b/airtime_mvc/application/forms/EditAudioMD.php index 3123c93e0..76f48b062 100644 --- a/airtime_mvc/application/forms/EditAudioMD.php +++ b/airtime_mvc/application/forms/EditAudioMD.php @@ -33,7 +33,8 @@ class Application_Form_EditAudioMD extends Zend_Form 'label' => 'Track:', 'class' => 'input_text', 'filters' => array('StringTrim'), - 'validators' => array('Int') + 'validators' => array('Int'), + 'required' => true )); // Add genre field From 8a63478c7378cc61642ec20c15370eb897b194fa Mon Sep 17 00:00:00 2001 From: denise Date: Tue, 12 Jun 2012 14:58:33 -0400 Subject: [PATCH 2/4] CC-3972: it is not possible to select tracks in Now Playing tab -fixed --- airtime_mvc/public/js/airtime/showbuilder/builder.js | 1 + 1 file changed, 1 insertion(+) diff --git a/airtime_mvc/public/js/airtime/showbuilder/builder.js b/airtime_mvc/public/js/airtime/showbuilder/builder.js index 6681eee49..94ce25608 100644 --- a/airtime_mvc/public/js/airtime/showbuilder/builder.js +++ b/airtime_mvc/public/js/airtime/showbuilder/builder.js @@ -301,6 +301,7 @@ var AIRTIME = (function(AIRTIME){ if (!$el.hasClass("ui-state-disabled")) { $el.addClass("ui-state-hover"); + $("#show_builder .ui-icon-document-b").contextMenu(true); } else { $("#show_builder .ui-icon-document-b").contextMenu(false); From 55634ddd4671ae59911fae9367359d49950b7e34 Mon Sep 17 00:00:00 2001 From: denise Date: Tue, 12 Jun 2012 15:41:10 -0400 Subject: [PATCH 3/4] CC-3928: Use liquidsoap to test whether file is playable on upload. -done -tests return value and output --- airtime_mvc/application/models/StoredFile.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/airtime_mvc/application/models/StoredFile.php b/airtime_mvc/application/models/StoredFile.php index 31aee00b4..3dd72ff4b 100644 --- a/airtime_mvc/application/models/StoredFile.php +++ b/airtime_mvc/application/models/StoredFile.php @@ -886,9 +886,9 @@ Logging::log("getting media! - 2"); } // Check if file is playable - $command = sprintf("/usr/bin/airtime-liquidsoap -c 'output.dummy(audio_to_stereo(single(\"%s\")))' > /dev/null 2>&1", $audio_file); + $command = sprintf("/usr/bin/airtime-liquidsoap -c 'output.dummy(audio_to_stereo(single(\"%s\")))' 2>&1", $audio_file); exec($command, $output, $rv); - if ($rv != 0) { + if ($rv != 0 || count($output) != 0) { $result = array("code" => 110, "message" => "This file appears to be corrupted and will not be added to media library."); } else { From 548a6ce16a4e6c87f4b508a019ceceeee42e2fe9 Mon Sep 17 00:00:00 2001 From: James Date: Tue, 12 Jun 2012 17:49:34 -0400 Subject: [PATCH 4/4] CC-3957: Make Schedule Widgets show future Sunday instead of past Sunday - bug fix --- airtime_mvc/application/common/DateHelper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airtime_mvc/application/common/DateHelper.php b/airtime_mvc/application/common/DateHelper.php index 3f7e29006..84c5feb0c 100644 --- a/airtime_mvc/application/common/DateHelper.php +++ b/airtime_mvc/application/common/DateHelper.php @@ -53,7 +53,7 @@ class Application_Common_DateHelper */ function getWeekStartDate() { - $startDate = date('w') == 0 ? date('Y-m-d') : date('Y-m-d', strtotime('monday')); + $startDate = date('w') == 0 ? date('Y-m-d') : date('Y-m-d', strtotime('monday this week')); $startDateTime = new DateTime($startDate); return $startDateTime->format('Y-m-d H:i:s'); }