From cd5f1149af8d52a8f054c45f6c638af02a82a956 Mon Sep 17 00:00:00 2001 From: denise Date: Thu, 14 Feb 2013 11:43:29 -0500 Subject: [PATCH] CC-4924: Calendar: "View Recorded File Metadata" for record show still uses old Metadata Editor -fixed --- airtime_mvc/public/js/airtime/library/library.js | 7 ++++++- airtime_mvc/public/js/airtime/schedule/schedule.js | 8 +++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/airtime_mvc/public/js/airtime/library/library.js b/airtime_mvc/public/js/airtime/library/library.js index 132cacf8e..9cb2ed96c 100644 --- a/airtime_mvc/public/js/airtime/library/library.js +++ b/airtime_mvc/public/js/airtime/library/library.js @@ -1368,7 +1368,12 @@ $(document).ready(function() { data = $("#edit-md-dialog form").serializeArray(); $.post(baseUrl+'library/edit-file-md', {format: "json", id: file_id, data: data}, function() { $("#edit-md-dialog").dialog().remove(); - oTable.fnStandingRedraw(); + + // don't redraw the library table if we are on calendar page + // we would be on calendar if viewing recorded file metadata + if ($("#schedule_calendar").length === 0) { + oTable.fnStandingRedraw(); + } }); }); diff --git a/airtime_mvc/public/js/airtime/schedule/schedule.js b/airtime_mvc/public/js/airtime/schedule/schedule.js index 3c4f9fd3b..d31cbb1c3 100644 --- a/airtime_mvc/public/js/airtime/schedule/schedule.js +++ b/airtime_mvc/public/js/airtime/schedule/schedule.js @@ -399,7 +399,7 @@ $(document).ready(function() { oItems.edit.callback = callback; } } - + //define a content callback. if (oItems.content !== undefined) { @@ -440,9 +440,11 @@ $(document).ready(function() { //define a view recorded callback. if (oItems.view_recorded !== undefined) { - callback = function() { - document.location.href = oItems.view_recorded.url; + $.get(oItems.view_recorded.url, {format: "json"}, function(json){ + //in library.js + buildEditMetadataDialog(json); + }); }; oItems.view_recorded.callback = callback; }