ADz83 Posted July 13, 2012 Share Posted July 13, 2012 I seem to be having an issue with some new users status staying inactive even after they have a product active. 0 Quote Link to comment Share on other sites More sharing options...
vdswin.com Posted July 15, 2012 Share Posted July 15, 2012 Could you please describe more detailed how to reproduce this "bug"? 0 Quote Link to comment Share on other sites More sharing options...
sol2010 Posted July 16, 2012 Share Posted July 16, 2012 I installed the update (5.12) and many of my existing clients status was set to inactive !! Had to manually re-activate them! 0 Quote Link to comment Share on other sites More sharing options...
vdswin.com Posted July 16, 2012 Share Posted July 16, 2012 I noticed that status "inactive" was set only for clients who has not active services. All who has active services remain "active"... Did you mean that yours clients with active services was marked as "inactive"? 0 Quote Link to comment Share on other sites More sharing options...
ADz83 Posted July 16, 2012 Author Share Posted July 16, 2012 Well in my case its when a customer purchases a product, I process order, send email with logins and then go into pending orders and manually accept the order at which point the client should be set as active by system because he has active service. However they are not automatically been set as active I have to manually edit them. Or is it set by cron? 0 Quote Link to comment Share on other sites More sharing options...
sol2010 Posted July 16, 2012 Share Posted July 16, 2012 For me, it was clients with outstanding orders / invoices (no actual active services as yet) marked as inactive 0 Quote Link to comment Share on other sites More sharing options...
vdswin.com Posted July 20, 2012 Share Posted July 20, 2012 (edited) As I can seen, Cron set accounts without active services to "inactive", seems that is correct. BUT, when such user place a new order and paid it, his account remain inactive regardless he have active order! And only on next Daily Cron runs this account will be set to "Active". So I do not think this is a bug, but this should be enhanced, that account set to "active" just after accepted order. Edited July 20, 2012 by vdswin.com 0 Quote Link to comment Share on other sites More sharing options...
WHMCS CEO Matt Posted July 21, 2012 WHMCS CEO Share Posted July 21, 2012 I can confirm this but it's no mistake. The client status will now be automatically switched from Active to Inactive based on active products/services. So if there are none they will show as inactive. If they've placed a new order but not paid, then as soon as the cron runs again following payment their status would change back to active. This helps give you a much truer reflection of active clients via the system overview widget on the admin homepage. Matt 0 Quote Link to comment Share on other sites More sharing options...
jclarke Posted July 21, 2012 Share Posted July 21, 2012 Matt, Is there a way to disable this? I manage a custom system built on top of WHMCS for a client and this will cause some issues because we don't use the product/services feature that is built into WHMCS so every client is going to get marked as inactive. We haven't upgraded yet but I can see this causing some major issues for us. Thanks, 0 Quote Link to comment Share on other sites More sharing options...
Bartucxp Posted July 21, 2012 Share Posted July 21, 2012 I need that to be disabled too. I don't know which clients was inactive before. You should give heads up on these things before updating. I had my own system to set clients inactive, I've set clients inactive that doesn't want to get any promotion emails from us but now I don't know who was active or inactive. Why change something like that after years of habits? Really, 5.1.2 update was a disaster. Too many things are broken(including cronjobs). This update simply messed everything up. I think that update was released somehow in a rush or maybe you've changed your coder team? You have too many web hosting companies as your clients and releasing an update without testing it properly is nonsense. Can't get reply to tickets for many days etc.. we are not playing games here, please remember that. 0 Quote Link to comment Share on other sites More sharing options...
dexus Posted July 23, 2012 Share Posted July 23, 2012 That is a nice feature, but I have to agree, that should be an optional feature, and should probably be disabled by default. I also think that WHMCS should never introduce such new behavior that is by default enabled without properly informing us of new behavior. Also default behavior for this should be to also treat clients with Pending services as Active, or we should have options to choose how this should behave. 0 Quote Link to comment Share on other sites More sharing options...
imaticon Posted July 25, 2012 Share Posted July 25, 2012 I installed the update (5.12) and many of my existing clients status was set to inactive !! Had to manually re-activate them! And you have to do this each day when the daily cron job runs. Bad thing.... 0 Quote Link to comment Share on other sites More sharing options...
imaticon Posted July 25, 2012 Share Posted July 25, 2012 That is a nice feature, but I have to agree, that should be an optional feature, and should probably be disabled by default. I completely agree with you. Please Matt, this is important. We need something which allows us to disable this feature. Regards, Marco 0 Quote Link to comment Share on other sites More sharing options...
succeed.net Posted July 26, 2012 Share Posted July 26, 2012 I would also have to agree. We have customers that have domain registration and renewal only with no other product that are being marked as inactive. Now I see the justification and importance if they have no products or domains at all but I consider domains to be an active service. So the system should be checking for domains not just products. 0 Quote Link to comment Share on other sites More sharing options...
Revolution Posted August 3, 2012 Share Posted August 3, 2012 I agree. All our custom design clients are being marked inactive every day 0 Quote Link to comment Share on other sites More sharing options...
WebzPro Posted August 4, 2012 Share Posted August 4, 2012 Honestly I can't see upgrading to 5.1 if this type of thing continues. This really needs to be set back. This is exactly the small types of issues with other billing systems that brought us to WHMCS. 0 Quote Link to comment Share on other sites More sharing options...
atlasnetworks Posted August 4, 2012 Share Posted August 4, 2012 We're finding the system is marking clients "inactive" that have "Pending" products in the account. We use the "Pending" status for clients routinely as a Fiber to the Premise provider as the fiber builds can take time to complete. I agree that this needs to have an on/off function but I'd like to see it further definable. Also, this type of significant change should be pre-set to disabled during upgrades. I'd like to see if refined based on a ranked list: - IF 'no active' products set to "Inactive" - IF 'no pending' products set to "Inactive" (overrides 'no active') - IF 'no activity' for 'x' days set to "Inactive" (by activity I mean no client log ins or tickets) I'm sure others may have some thoughts on variables here. Cheers, Ryan 0 Quote Link to comment Share on other sites More sharing options...
atlasnetworks Posted August 4, 2012 Share Posted August 4, 2012 I also noted on this topic that there is no log entry written in the clients account indicating that the cron job (or system) marked the account inactive. If the system is making changes, these should be logged the same as if an admin or client makes a change. Cheers, Ryan 0 Quote Link to comment Share on other sites More sharing options...
cenourinha Posted August 4, 2012 Share Posted August 4, 2012 We need this situation reversed and as an opt-in option. Now we don't know what were the real "inactive" accounts that we have set before the upgrade. 0 Quote Link to comment Share on other sites More sharing options...
dexus Posted August 6, 2012 Share Posted August 6, 2012 We're finding the system is marking clients "inactive" that have "Pending" products in the account. We use the "Pending" status for clients routinely as a Fiber to the Premise provider as the fiber builds can take time to complete. I agree that this needs to have an on/off function but I'd like to see it further definable. Also, this type of significant change should be pre-set to disabled during upgrades. I'd like to see if refined based on a ranked list: - IF 'no active' products set to "Inactive" - IF 'no pending' products set to "Inactive" (overrides 'no active') - IF 'no activity' for 'x' days set to "Inactive" (by activity I mean no client log ins or tickets) I'm sure others may have some thoughts on variables here. Cheers, Ryan That is exactly what we need... There should be one main switch to enable disable that behavior (disabled by default).... ... and there should be a checkbox for each domain and each product status. For example... Don't swith to inactive clients that have products with one of the following status... x Active x Pending x Suspended - Terminated ... Don't swith to inactive clients that have domains with one of the following status... x Active x Pending x Pending Transfer - Expired - Cancelled ... We can't upgrade to new version because of this. This should really be resolved asap. Thank you. 0 Quote Link to comment Share on other sites More sharing options...
SeanP Posted February 25, 2013 Share Posted February 25, 2013 (edited) I upgraded to WHMCS 5.1.3, and had the situation where a ton of my clients were set to inactive, yet they have active reoccurring billable items. I bill many of my clients, using billable items, for custom services. So, I created the following script to run, after the admin cron job runs each day. It will set clients to active, that have active billable items (not set to "Don't Invoice for Now"). I named the following script statusupdate.php: <?php ##### CONFIG BEGIN (Only change this section) ##### include '/home/username/public_html/whmcs/configuration.php'; # path to WHMCS configuration file $url = 'http://www.yourdomain.com/whmcs/includes/api.php'; # URL to WHMCS API file $whmcsadmin = 'admin'; # WHMCS admin account for API ##### CONFIG END ##### # Open database connection $conn = mysql_connect($db_host, $db_username, $db_password); if (! $conn ){ die('Could not connect: ' . mysql_error()); } # Select the WHMCS database mysql_select_db($db_name, $conn); # Query the database for the WHMCS admin password $mysqlquery1 = mysql_query("SELECT username, password FROM tbladmins WHERE username = '" . $whmcsadmin . "'"); # Set variables from database query results while($row = mysql_fetch_array($mysqlquery1)) { $username = $row['username']; $password = $row['password']; } # Query database for active billable items (NOT marked as Don't Invoice for Now) $mysqlquery2 = mysql_query("SELECT tblclients.id, tblclients.status FROM tblclients INNER JOIN tblbillableitems ON tblclients.id = tblbillableitems.userid WHERE tblbillableitems.invoiceaction <> '0'"); while($row = mysql_fetch_array($mysqlquery2)) { # Set variables from database query results $clientid = $row['id']; $status = $row['status']; if ($status = "Inactive"){ # If client has an active billable item and is Inactive, set to Active via API $postfields["username"] = $username; $postfields["password"] = $password; $postfields["action"] = "updateclient"; $postfields["clientid"] = $clientid; $postfields["status"] = "Active"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_TIMEOUT, 100); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields); $data = curl_exec($ch); curl_close($ch); $data = explode(";",$data); foreach ($data AS $temp) { $temp = explode("=",$temp); if (isset($temp[1])){ $results[$temp[0]] = $temp[1]; } } if ($results["result"]=="success") { # Result was OK! } else { # An error occured echo "The following error occured: ".$results["message"]; } } } # Close database connection mysql_close($conn); ?> I wrap my admin cron script and the statusupdate.php script in a single shell script, so that statusupdate.php will run right after the admin cron job runs. I named the shell script runcrons.sh: #!/bin/bash /usr/local/bin/php -q /home/username/public_html/whmcs/admin/cron.php /usr/local/bin/php -q /home/username/public_html/whmcs/crons/statusupdate.php I placed both statusupdate.php, and runcrons.sh in my admin/crons folder. I then replaced my admin cron line, in crontab, to run the runcrons.sh script instead. So, it will run the admin cron job first, then immediately run my statusupdate.php job. You can modify the statusupdate.php script to meet your specific needs. You will need to make sure the paths are correct in both scripts (including the path to php in runcrons.sh). You will probably have to set the perms on scripts to 755. I HIGHLY suggest testing this on a test copy of your database, before running it in production. I offer this script as a free contribution, and take no responsibility for any data issues. I run these scripts, daily, on my main production WHMCS implementation. I hope this helps anyone who needs it... Sean Edited February 25, 2013 by SeanP 0 Quote Link to comment Share on other sites More sharing options...
SeanP Posted March 4, 2013 Share Posted March 4, 2013 Also, make sure the IP of you server is in Setup > General Settings > Security under "API IP Access Restriction". This is required for the API call used to set the accounts to Active. Sean 0 Quote Link to comment Share on other sites More sharing options...
dahamsta Posted March 12, 2013 Share Posted March 12, 2013 I can't understand why this has been moved to customisation, it's clearly a bug. Here's an example of it impacting upon something else in WHMCS. http://forum.whmcs.com/showthread.php?69399-Quote-for-existing-client 0 Quote Link to comment Share on other sites More sharing options...
dahamsta Posted March 20, 2013 Share Posted March 20, 2013 Thanks for correcting this. For those who didn't go hunting, this can be configured now Under Settings > Automation > Client Status Update, at the foot of the page. 0 Quote Link to comment Share on other sites More sharing options...
SeanP Posted March 20, 2013 Share Posted March 20, 2013 Are you talking about version 5.2? You can't configure it in 5.1. Sean 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.