diff --git a/archive/community.applications-2022.06.17-x86_64-1.txz b/archive/community.applications-2022.06.17-x86_64-1.txz new file mode 100644 index 00000000..f2d5bab5 Binary files /dev/null and b/archive/community.applications-2022.06.17-x86_64-1.txz differ diff --git a/source/community.applications/usr/local/emhttp/plugins/community.applications/Apps.page b/source/community.applications/usr/local/emhttp/plugins/community.applications/Apps.page index e74dc9ae..3d758f1e 100644 --- a/source/community.applications/usr/local/emhttp/plugins/community.applications/Apps.page +++ b/source/community.applications/usr/local/emhttp/plugins/community.applications/Apps.page @@ -943,6 +943,7 @@ function doSearch(button,newSearch) { } var filter = $('#searchBox').val(); filter = $.trim(filter); + filter = stripTags(filter); if ( ! filter ) { $("#searchBox").val(filter); data.searchInProgress = false; @@ -1330,7 +1331,7 @@ function getPrevApps(installed,filter,dontClear) { $("#Category").html(msg); changeSortOrder(null,null,"true"); enableMultiInstall(); - saveState(); +// saveState(); }); } @@ -1393,18 +1394,6 @@ function postUninstallPlugin() { enableSearch(); $(".selectedMenu").trigger("click"); setupActionCentre(); -/* if ( $(".selectedMenu").data("category") == "action_centre" ) { - actionCentre(); - } else { - if ( $(".selectedMenu").data("category") !== "inst_docker" && $(".selectedMenu").data("category") !== "inst_plugin") { - $(".caMenuItem").removeClass("selectedMenu"); - var menuItem = $.find(".caMenuItem[data-category='installed_apps']"); - $(menuItem).addClass("selectedMenu"); - $(menuItem).next().show("slow"); - } - previousApps(true,false,data.previousAppsSection); - enableSearch(); - } */ } String.prototype.basename = function() { @@ -1959,7 +1948,7 @@ function updateDisplay(content) { } else { removeBannerWarning(data.translationBanner); } - saveState(); +// saveState(); if ( ! $(".startupButton").hasClass("selectedMenu") && ! data.docker) { $(".maxPerPage").show(); @@ -1987,7 +1976,7 @@ function saveState() { $(".caMenuEnabled").each(function(){ categoriesEnabled.push($(this).data("category")); }); - $.cookie("ca_categories_enabled",JSON.stringify(categoriesEnabled),{path:"/;SameSite=Lax"}); +// $.cookie("ca_categories_enabled",JSON.stringify(categoriesEnabled),{path:"/;SameSite=Lax"}); $.cookie("ca_selectedMenu",selectedMenu,{path:"/;SameSite=Lax"}); $.cookie("ca_filter",$("#searchBox").val(),{path:"/;SameSite=Lax"}); $.cookie("ca_categoryName",$(".categoryMenuName").html(),{path:"/;SameSite=Lax"}); @@ -2007,7 +1996,10 @@ function restoreState() { } else { $(".multi_installDiv").hide(); } + $.removeCookie("ca_categoryText"); + data = JSON.parse($.cookie("ca_data")); + $.removeCookie("ca_data"); data.searchActive = evaluateBoolean($.cookie("ca_searchActive")); restoreStateMenu = $.cookie("ca_selectedMenu"); $(".categoryMenuName").html($.cookie("ca_categoryName")); @@ -2930,15 +2922,19 @@ function setupActionCentre() { // set up action centre - run in background without tying anything up var acBanner = false; var bannerTimeout = setTimeout(function(){ - acBanner = addBannerWarning(""); + acBanner = addBannerWarning("",false,true); },1000); $.post("/plugins//include/exec.php",{action:'enableActionCentre'},function(data) { clearTimeout(bannerTimeout); removeBannerWarning(acBanner); var ret = JSON.parse(data); - if ( ret.status == "action" ) + if ( ret.status == "action" ) { + acBanner = addBannerWarning("",false,true); + setTimeout(function() { + removeBannerWarning(acBanner); + },10000); $(".actionCentre").show(); - else + } else $(".actionCentre").hide(); }); } diff --git a/source/community.applications/usr/local/emhttp/plugins/community.applications/ca.md5 b/source/community.applications/usr/local/emhttp/plugins/community.applications/ca.md5 index a067c92d..7b7dae78 100644 --- a/source/community.applications/usr/local/emhttp/plugins/community.applications/ca.md5 +++ b/source/community.applications/usr/local/emhttp/plugins/community.applications/ca.md5 @@ -1,4 +1,4 @@ -4f5b81b0c0029e43df4eb8e01092bdd7 ./Apps.page +ddc87e24d33f112e6023230f9f105251 ./Apps.page 4e55f7483b661af21a25b677179baffe ./CA_notices.page 42a1658a916a3a3eed2a9f2af80603c4 ./ca_settings.page e718d7825dbdc96a17a915079222b098 ./default.cfg @@ -22,4 +22,4 @@ da3b4f9b73c5c3bf65be6c42d68b51f9 ./scripts/showStatistics.php 34554a56611dfe625889c82afd5138de ./scripts/updatePluginSupport.php 25bdaed6f62ac73f9ef7c3ce0c125ef7 ./skins/Narrow/css.php 3e76bb2f7ac6db500d1d91072deb68aa ./skins/Narrow/skin.html -40d7e4e4b35b4ecce7918567ac080589 ./skins/Narrow/skin.php +518650aa7b5322bd697242934999b01a ./skins/Narrow/skin.php diff --git a/source/community.applications/usr/local/emhttp/plugins/community.applications/skins/Narrow/skin.php b/source/community.applications/usr/local/emhttp/plugins/community.applications/skins/Narrow/skin.php index 3ea860f4..11a60982 100644 --- a/source/community.applications/usr/local/emhttp/plugins/community.applications/skins/Narrow/skin.php +++ b/source/community.applications/usr/local/emhttp/plugins/community.applications/skins/Narrow/skin.php @@ -238,11 +238,19 @@ function my_display_apps($file,$pageNumber=1,$selectedApps=false,$startup=false) $installComment = tr("This application has additional requirements")."
".markdown($template['Requires']); } } - if ( ! $template['RequiresFile'] || ($template['RequiresFile'] && is_file($template['RequiresFile'])) ) { - $installComment = $template['RequiresFile'] ? "" : $installComment; + // if ( ! $template['RequiresFile'] || ($template['RequiresFile'] && is_file($template['RequiresFile'])) ) { + // $installComment = ! is_file($template['RequiresFile']) ? "Requirements Not Met" : $installComment; + // $installComment = $template['RequiresFile'] ? "" : $installComment; + $isDeprecated = $template['Deprecated'] ? "&deprecated" : ""; - $actionsContext[] = array("icon"=>"ca_fa-install","text"=>$buttonTitle,"action"=>"installPlugin('{$template['PluginURL']}$isDeprecated','','".str_replace([" ","\n"],[" ",""],htmlspecialchars($installComment))."');"); - } + if ( $template['RequiresFile'] && ! is_file($template['RequiresFile']) ) { + $installComment = tr("Cannot Install. Requirements Not Met"); + $installAction = "alert"; + } else { + $installAction = "installPlugin"; + } + $actionsContext[] = array("icon"=>"ca_fa-install","text"=>$buttonTitle,"action"=>"$installAction('{$template['PluginURL']}$isDeprecated','','".str_replace([" ","\n"],[" ",""],htmlspecialchars($installComment))."');"); + // } if ( $template['InstallPath'] ) { if ( ! empty($actionsContext) ) $actionsContext[] = array("divider"=>true); @@ -662,11 +670,11 @@ function getPopupDescriptionSkin($appNumber) { } elseif ( ! $template['Blacklist'] ) { if ( $template['Compatible'] || $caSettings['hideIncompatible'] !== "true") { // if ( !$template['Deprecated'] || $caSettings['hideDeprecated'] !== "true" ) { - if ( ($template['RequiresFile'] && is_file($template['RequiresFile']) ) || ! $template['RequiresFile'] ) { +// if ( ($template['RequiresFile'] && is_file($template['RequiresFile']) ) || ! $template['RequiresFile'] ) { $buttonTitle = $template['InstallPath'] ? tr("Reinstall") : tr("Install"); $isDeprecated = $template['Deprecated'] ? "&deprecated" : ""; $actionsContext[] = array("icon"=>"ca_fa-install","text"=>$buttonTitle,"action"=>"installPlugin('{$template['PluginURL']}$isDeprecated');"); - } +// } // } } if ( $template['InstallPath'] ) {