From 3e66363cdd49bd400280dee43674b0634ec43e2e Mon Sep 17 00:00:00 2001 From: drigato Date: Fri, 14 Aug 2015 08:43:47 -0400 Subject: [PATCH] SAAS-1017: Move top nav bar to side Reload datatable if user clicks the browser's back button --- airtime_mvc/public/js/airtime/library/_library.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/airtime_mvc/public/js/airtime/library/_library.js b/airtime_mvc/public/js/airtime/library/_library.js index 6452d734e..5d7ff3b8a 100644 --- a/airtime_mvc/public/js/airtime/library/_library.js +++ b/airtime_mvc/public/js/airtime/library/_library.js @@ -1262,6 +1262,14 @@ $(document).ready(function() { } $("a[href$='"+location.hash+"']").parent().addClass("selected"); + $(window).on('hashchange', function() { + $(".media_type_selector").each(function () { + $(this).removeClass("selected"); + }); + $("a[href$='"+location.hash+"']").parent().addClass("selected"); + oTable.fnDraw(); + }); + $(".media_type_selector").on("click", function() { if (!$(this).hasClass("selected")) { AIRTIME.library.selectNone();