From 9dc2a1f148beccc0cbe8536634643e6e1bf94780 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Feb 2019 12:51:52 +0100 Subject: [PATCH] Update productaccount.php --- htdocs/accountancy/admin/productaccount.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/accountancy/admin/productaccount.php b/htdocs/accountancy/admin/productaccount.php index f9687798b00..a81aa472ef7 100644 --- a/htdocs/accountancy/admin/productaccount.php +++ b/htdocs/accountancy/admin/productaccount.php @@ -468,12 +468,12 @@ if ($result) atleastoneselected=0; jQuery(".checkforselect").each(function( index ) { /* console.log( index + ": " + $( this ).text() ); */ - if ($(this).is(\':checked\')) at leastoneselected++; + if ($(this).is(\':checked\')) atleastoneselected++; }); - if (at leastoneselected) jQuery("#changeaccount").removeAttr(\'disabled\'); + if (atleastoneselected) jQuery("#changeaccount").removeAttr(\'disabled\'); else jQuery("#changeaccount").attr(\'disabled\',\'disabled\'); - if (at leastoneselected) jQuery("#changeaccount").attr(\'class\',\'butAction\'); + if (atleastoneselected) jQuery("#changeaccount").attr(\'class\',\'butAction\'); else jQuery("#changeaccount").attr(\'class\',\'butActionRefused\'); } jQuery(".checkforselect, #checkallactions").click(function() {