garybarr Posted January 28, 2019 Share Posted January 28, 2019 We WANT to be able to search all clients active/inactive, all the time. However, while you can click "OFF" when the search window comes up, it doesn't hold that setting. It will keep defaulting back to ON, which we NEVER want. Is there a way to turn off this new feature for good? 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 28, 2019 Author Share Posted January 28, 2019 OMG, this is driving me crazy... The staff has made all kinds of duplicate accounts, because they couldn't see the Inactive accounts, so they started a new one. ARGH! 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted January 28, 2019 Share Posted January 28, 2019 1 hour ago, garybarr said: We WANT to be able to search all clients active/inactive, all the time. this got raised during the beta testing... 1 hour ago, garybarr said: However, while you can click "OFF" when the search window comes up, it doesn't hold that setting. It will keep defaulting back to ON, which we NEVER want. Is there a way to turn off this new feature for good? having just spent 20 minutes trying to do this in jQuery - I can almost see what needs doing, but couldn't quite get it to work - there is a simpler way that should work for you if/until WHMCS decide to make this permanently optional... clients.php?show_hidden=1 you might need to edit menu.tpl in your admin template (tested on Blend) and change the two links currently linking to clients.php to the above instead. 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 28, 2019 Author Share Posted January 28, 2019 I tried that, but it didn't work... This is what I now have for my Blend menu.tpl (yes, we only use Blend Template) <div class="navigation"> <ul id="menu"> <li><a id="Menu-Clients" {if in_array("List Clients",$admin_perms)}href="clients.php?show_hidden=1"{/if} title="Clients"><span class="hidden-xs">{$_ADMINLANG.clients.title}</span><span class="visible-xs"><i class="fas fa-user"></i></span></a> <ul> {if in_array("List Clients",$admin_perms)}<li><a id="Menu-Clients-View_Search_Clients" href="clients.php?show_hidden=1">{$_ADMINLANG.clients.viewsearch}</a></li>{/if} 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted January 28, 2019 Share Posted January 28, 2019 try the following instead... clients.php?filter=1&show_hidden=1 that's definitely working for me. 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 28, 2019 Author Share Posted January 28, 2019 I've tried that also, but no luck. I triple checked that it's the latest BLEND Template version, no other modifiers... But it opens up with "Hide Active Clients" ON... I've even tried to turn is off, hoping it would stick now... but nope, when I close the window and then reopen, it went back to ON. 😞 Here is what I have now: (admin/templates/blend/menu.tpl) <div class="navigation"> <ul id="menu"> <li><a id="Menu-Clients" {if in_array("List Clients",$admin_perms)}href="clients.php?filter=1&show_hidden=1"{/if} title="Clients"><span class="hidden-xs">{$_ADMINLANG.clients.title}</span><span class="visible-xs"><i class="fas fa-user"></i></span></a> <ul> {if in_array("List Clients",$admin_perms)}<li><a id="Menu-Clients-View_Search_Clients" href="clients.php?filter=1&show_hidden=1">{$_ADMINLANG.clients.viewsearch}</a></li>{/if} {if in_array("Add New Client",$admin_perms)}<li><a id="Menu-Clients-Add_New_Client" href="clientsadd.php">{$_ADMINLANG.clients.addnew}</a></li>{/if} 0 Quote Link to comment Share on other sites More sharing options...
WHMCS Support Manager WHMCS John Posted January 28, 2019 WHMCS Support Manager Share Posted January 28, 2019 Hi all, I appreciate you'r talking about the main client list. But I have a related handy hint to chip in. In 7.7 the default state of the "Hide inactive clients" option in the Intelligent Search can be changed via the template. It is ON by default. It can be switched OFF by default by way of a customisation to /admin/*your template*/footer.tpl Change line 90 FROM: <span class="hide-inactive"><input type="checkbox" id="intelliSearchHideInactiveSwitch" data-size="mini" data-label-text="{lang key="global.hideInactive"}" checked="checked"></span> TO: <span class="hide-inactive"><input type="checkbox" id="intelliSearchHideInactiveSwitch" data-size="mini" data-label-text="{lang key="global.hideInactive"}"></span> Hope that helps! 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 28, 2019 Author Share Posted January 28, 2019 Well, I was excited for a moment, because it LOOKED like it worked, but it doesn't. It does indeed say that it is turned off, however, it is still functioning like it is on. I am able to turn it back on, then off again manually and it begins working properly. However, whenever you first load the page, it says OFF, but when I do the search, only active people come up. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted January 29, 2019 Share Posted January 29, 2019 19 hours ago, garybarr said: I've tried that also, but no luck. I triple checked that it's the latest BLEND Template version, no other modifiers... But it opens up with "Hide Active Clients" ON... I've even tried to turn is off, hoping it would stick now... but nope, when I close the window and then reopen, it went back to ON. this for me is working in both Blend and v4 - even in Lara too... 🙂 ... still works after I logout, close browser, open browser and login - if I were to click on a link to clients.php (e.g from the sidebar), then obviously it would hide the inactive clients... but with a modified menu (mine is exactly the same as yours), clicking on those links shows the inactive clients (and changes that button to "OFF" too). two thoughts... my v7.7 dev is a clean install, so there are no v7.6.1 or earlier files lurking there... so whether your installation is incomplete/corrupt and there's a .js file somewhere that hasn't been updated or missing, I don't know.... you could try reuploading the 'assets' folder again to see if that helps. you could probably write an AdminAreaPage hook that redirects on the clients.php page, though redirection is trickier now in the admin area... I think it would work, but it would be more than a few lines as it might require multiple checks... would be of more use if you had some users that you wanted to hide inactive clients to, and some that you didn't... also, I imagine that there's only going to be 2 or 3 v7.7 releases, so it's not like you will have to update the menu.tpl template every week! 🙂 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 29, 2019 Author Share Posted January 29, 2019 I have made the change in V4 and it DOES work just fine... But Blend doesn't work still. So, I moved my Blend to Blendbackup, then copied a fresh copy of Blend template from the WHMCS77 ZIP, then made the changes to this fresh version of Blend.... ...but still same problem. Hide Inactive Client still is ON. I've checked in multiple browsers and multiple PC's just to make sure I wasn't fighting a strange caching issue. It's weird that V4 Template works fine, but Blend doesn't. But we can't use V4, because it's straight out of 1998 and looks no where near a modern look. 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted January 29, 2019 Author Share Posted January 29, 2019 Oh and I did try replacing the assets directory also. No changes. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted January 30, 2019 Share Posted January 30, 2019 15 hours ago, garybarr said: I have made the change in V4 and it DOES work just fine... But Blend doesn't work still. So, I moved my Blend to Blendbackup, then copied a fresh copy of Blend template from the WHMCS77 ZIP, then made the changes to this fresh version of Blend.... the problem here is that everything that Blend uses will not necessarily be in the blend folder... 15 hours ago, garybarr said: ...but still same problem. Hide Inactive Client still is ON. I've checked in multiple browsers and multiple PC's just to make sure I wasn't fighting a strange caching issue. then the issue lies with your site. 15 hours ago, garybarr said: It's weird that V4 Template works fine, but Blend doesn't. But we can't use V4, because it's straight out of 1998 and looks no where near a modern look. lol - it looked dated back in 2013 when I got my first WHMCS license and it's not ageing well... i've never used v4 as i've always used Blend in the devs, and recently Lara on the productions... 15 hours ago, garybarr said: Oh and I did try replacing the assets directory also. No changes. then go nuclear and start uploading other folders - 'vendor' would be first choice, with possibly 'includes' after that - the problem with recent WHMCS releases is that there are now 10,000+ files - so plenty of opportunity to go wrong... especially when installed as an update where previous files might still be present and not updated... now maybe a WHMCS internal developer could identify which file(s) are missing, but frankly it's just easier to keep uploading folders until you hit the right one(s) by accident. I wish the Softaculous whmcs demo was still online as then you could test on a clean install... best I can do is link you to the Lara online demo (click on demo link and login), currently i'm seeing two active clients - just edit one of their profiles and make them inactive... then you should be able to see all clients using the above ?filter=1&show_hidden-=1 in the link... this is nothing special to Lara - as you know as you've seen it working in v4 locally, and (except on you site apparently!) it works in Blend too. other than uploading every folder again, i'm not sure what to suggest - if disabling the feature is important to you, then perhaps opening a ticket with Support might be an option. 0 Quote Link to comment Share on other sites More sharing options...
WH user Posted February 11, 2019 Share Posted February 11, 2019 We identified this as a serious issue for us during the 7.7 beta. We're planning staying on 7.6 until there's a proper solution to this. 0 Quote Link to comment Share on other sites More sharing options...
garybarr Posted February 11, 2019 Author Share Posted February 11, 2019 Yeah, it's a serious problem for us, enough it's got them looking for other platforms to move to and move away from WHMCS. I'm hoping I can get everyone to calm down, but the things above, while I can get them to work on a test system, for some reason, will not work on our production system (and the only one that matters to us that it does work). 0 Quote Link to comment Share on other sites More sharing options...
WHMCS Chance Posted February 11, 2019 Share Posted February 11, 2019 Hi all, We have an internal case to visit this issue where the toggle switch for `Hide Inactive Clients` is not being honored: `CORE-13099` I do not have an ETA on when this will be resolved but you can check the changelog when we release new updates and search for the case provided above to see if this was included @ http://changelog.whmcs.com/ Thanks! 0 Quote Link to comment Share on other sites More sharing options...
WH user Posted February 12, 2019 Share Posted February 12, 2019 6 hours ago, WHMCS Chance said: Hi all, We have an internal case to visit this issue where the toggle switch for `Hide Inactive Clients` is not being honored: `CORE-13099` I do not have an ETA on when this will be resolved but you can check the changelog when we release new updates and search for the case provided above to see if this was included @ http://changelog.whmcs.com/ Thanks! Hi Chance. It's great to hear this is being worked on. Can you clarify if you will make it possible for the setting to be persistent across login sessions? It's simply too error prone & time consuming for us to constantly have to hit that toggle. 0 Quote Link to comment Share on other sites More sharing options...
WHMCS Chance Posted February 12, 2019 Share Posted February 12, 2019 Hey @WH user, I can confirm that we are looking into adjusting the behavior to be persistent across logins however were still reviewing the best path forward on this. Thanks! 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted February 12, 2019 Share Posted February 12, 2019 can someone test the hook below for me ? it checks whether the URL value of show_hidden is not equal to 1 (e.g the default value or show hidden clients is disabled), and if so redirects to a link that add the filter/hidden options on and so should always show inactive clients... <?php # Admin Show Inactive Clients Hook # Written by brian! function admin_show_inactive_clients_hook($vars){ $filename = $vars['filename']; $hiddenstatus = $_GET['show_hidden']; if ($filename == "clients" && $hiddenstatus != '1') { $url = 'clients.php?filter=1&show_hidden=1'; header( 'Location: '.$url ); } } add_hook('AdminAreaPage', 1, "admin_show_inactive_clients_hook"); worst case, you might get a redirect error - but i'm not seeing that issue locally... I wouldn't see this as a long-term solution, but if it works for others, it should be enough until WHMCS decide on their next step... 1 Quote Link to comment Share on other sites More sharing options...
papo2414 Posted February 13, 2019 Share Posted February 13, 2019 On 12/2/2019 at 10:40, brian! said: ¿Puede alguien probar el gancho de abajo para mí? comprueba si el valor de URL de show_hidden no es igual a 1 (por ejemplo, el valor predeterminado o mostrar clientes ocultos está deshabilitado) y, si es así, redirige a un enlace que agrega el filtro / opciones ocultas y, por lo tanto, siempre debería mostrar clientes inactivos. . En el peor de los casos, es posible que obtengas un error de redireccionamiento, pero no veo ese problema localmente No vería esto como una solución a largo plazo, pero si funciona para otros, debería ser suficiente hasta que WHMCS decida cuál será su próximo paso ... Did someone else try this? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted February 14, 2019 Share Posted February 14, 2019 15 hours ago, papo2414 said: Did someone else try this? i'd be interested to hear too! though editing the menu.tpl template would work as well and removes any potential redirection issues (not that I think there are any with the hook). 0 Quote Link to comment Share on other sites More sharing options...
JDC Posted February 19, 2019 Share Posted February 19, 2019 Hi, On 1/29/2019 at 4:46 AM, WHMCS John said: Hi all, I appreciate you'r talking about the main client list. But I have a related handy hint to chip in. In 7.7 the default state of the "Hide inactive clients" option in the Intelligent Search can be changed via the template. It is ON by default. It can be switched OFF by default by way of a customisation to /admin/*your template*/footer.tpl Change line 90 FROM: <span class="hide-inactive"><input type="checkbox" id="intelliSearchHideInactiveSwitch" data-size="mini" data-label-text="{lang key="global.hideInactive"}" checked="checked"></span> TO: <span class="hide-inactive"><input type="checkbox" id="intelliSearchHideInactiveSwitch" data-size="mini" data-label-text="{lang key="global.hideInactive"}"></span> Hope that helps! I tried this with a different approach, I modified line 25 and line 90. From line 25 I changed the value from "1" to "0", then on line 90 I changed checked="checked" to unchecked="checked", and it works. It shows the active and inactive clients when i search on the whmcs search box. The hide-inactive client button is now default to off. 1 Quote Link to comment Share on other sites More sharing options...
garybarr Posted February 19, 2019 Author Share Posted February 19, 2019 YIPEE! That method worked for me! My appreciate to everyone who's worked on this problem! While I know Brian!'s method works, and I'm sure that it didn't for me due to a 3rd party plugin issue... This final method did work for me, even with my crazy plugin issue. Now... If only WHMCS fixes this problem without us having to alter the code. 1 Quote Link to comment Share on other sites More sharing options...
ABI Posted February 20, 2019 Share Posted February 20, 2019 This also works for me. Great appreciation for JDC 1 Quote Link to comment Share on other sites More sharing options...
brian! Posted February 20, 2019 Share Posted February 20, 2019 ironically, it doesn't work for me - but never mind, there are plenty of ways to skin a cat and as long as we all find something that works... 🐈 let us hope that one day WHMCS will decide to stop imposing these silly decisions upon us and start discussing what they want to do *long before* any beta hits the download shelf. 1 Quote Link to comment Share on other sites More sharing options...
markc Posted March 25, 2019 Share Posted March 25, 2019 (edited) Hey brian! I just tried your admin_show_inactive_clients_hook above and some debugging shows the file is opened but some debugging in the method itself shows it's not being called (for me). I added the hook as includes/hooks/admin_show_inactive_clients.php so is that the right place for it to go? Edited March 25, 2019 by markc 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.