From d60bab3499b94e97f1ad3214a182084dbc3d558d Mon Sep 17 00:00:00 2001 From: dmacias72 Date: Sun, 1 Oct 2017 01:34:00 -0600 Subject: [PATCH] fix stickyheaders for new themes add status for installed --- .../plugins/NerdPack/js/jquery.NerdPack.js | 28 +++++++++++++------ 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/source/NerdPack/usr/local/emhttp/plugins/NerdPack/js/jquery.NerdPack.js b/source/NerdPack/usr/local/emhttp/plugins/NerdPack/js/jquery.NerdPack.js index caaf43a5..45313356 100644 --- a/source/NerdPack/usr/local/emhttp/plugins/NerdPack/js/jquery.NerdPack.js +++ b/source/NerdPack/usr/local/emhttp/plugins/NerdPack/js/jquery.NerdPack.js @@ -4,8 +4,9 @@ $(function(){ sortList: [[0,0]], widgets: ['saveSort', 'filter', 'stickyHeaders', 'zebra'], widgetOptions: { - stickyHeaders_filteredToTop: false, - //stickyHeaders_yScroll: $('.page_nerdpack'), + stickyHeaders_filteredToTop: true, + stickyHeaders_attachTo: null, + stickyHeaders_offset: ($('#header').css("position") === "fixed") ? '90' : '0', filter_hideEmpty: true, filter_liveSearch: true, filter_saveFilters: true, @@ -19,7 +20,7 @@ $(function(){ }); // "uninstall package" switch and cookie - $('#uninstallpkg') + $('.uninstallpkg') .switchButton({ labels_placement: 'right', on_label: 'unInstall On', @@ -31,7 +32,7 @@ $(function(){ }); // select all packages switch - $('#checkall') + $('.checkall') .switchButton({ labels_placement: 'right', on_label: 'Select All', @@ -62,11 +63,16 @@ function packageQuery(force) { var Downloaded = data.packages[i].downloaded; var DownloadEQ = data.packages[i].downloadeq; var Installed = data.packages[i].installed; - if (DownloadEQ == Downloaded && data.packages[i].installeq == Installed){ - if (Installed == "yes") - Update = " up-to-date "; - else + var InstallEQ = data.packages[i].installeq; + if (DownloadEQ == Downloaded && InstallEQ == Installed){ + if (Installed == "yes"){ + if (Downloaded == "no") + Update = " installed"; + else + Update = " up-to-date "; + }else{ Update = " uninstalled "; + } }else{ Update = " update ready "; Ready = true; @@ -79,7 +85,7 @@ function packageQuery(force) { if (data.packages[i].config == "yes"){ Checked = "checked"; Count++; - } + } $('#tblPackages tbody').append(""+ ""+data.packages[i].name+""+ // package name @@ -155,6 +161,10 @@ function checkDepends() { $('#utempter').switchButton({checked: true}); $('#utempter', '.pkgvalue').val('yes'); } + if ($('#expect')[0].checked) { + $('#tcl').switchButton({checked: true}); + $('#tcl', '.pkgvalue').val('yes'); + } if ($('#iotop')[0].checked) { $('#python').switchButton({checked: true}); $('#python', '.pkgvalue').val('yes');