New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Comments
I see now. I was confused since BuyVM disallows you to order anything starting when the invoice is created.
I see, well that is mad
Settle your invoice then? If you need some extra time, etc, Aldryic is usually pretty reasonable and lends a hand.
The system is in place and was developed in full by Aldryic.
LOOK AT MY HORSE, MY HORSE IS AMAZING.
Francisco
I don't think this would be too hard, let me throw my hands at it.
I don't know. I think he's been offered more in the past and turned it down.
Francisco
GIVE IT A LICK, IT TASTES JUST LIKE RAISI...oh damn you
@sshVM @AnthonySmith @Jack
This plugin won't let the client order if the invoice is OVERDUE say you send out invoices 2 weeks early that is fine it won't have an issue with that since they are not overdue
I got it done for you guys! You can download it here: http://pytohost.com/overdue.zip
Just upload overdue.php to /includes/hooks/
Edit the file and where it says $adminuser = 'AdminName';
Change AdminName to an actual admin name.
Make me giddy and donate to me
What if the system has more than a single administror account? Any will do?
Yup it just has to be one of them. Its part of the WHMCS internal API.
Congrats, Spencer! Well-written, too!
@Spencer, nice one, can you include a link to the invoices section in the message?
woot! ;o
Just edit overdue.php and replace line 12:
$errormessage = "<li>You have overdue invoices, you need to pay them before you can create a new order</li>";
with:
$errormessage = "<li>You have overdue invoices, you need to pay them before you can create a new order. <a href='clientarea.php?action=masspay&all=true'>Pay Now »</a></li>";
@Spencer good work but this doesn't help our first issue
1. To prevent multiple unpaid orders.
Is it possible to make this script like avoid new order if invoice is Unpaid
Has anyone implemented this?
If so, have you had any new orders since? I tried it out - turns out it stopped people from ordering!
lol'd
The student fails, more like, @Damian.
LOL
Im running it fine, no issues at all.
I has the same issue - though it seemed for me to only happen when a new customer was trying to sign up.
Let me take a look, odd.
I tried this and had the same issue. Gave the warning on new orders for unregistered customers. This would be a great tool if it got working correctly.
Yea I know the issue, it is an easy fix. Ive just been sooooo busy. Tomorrow ill have a fix.
We considered doing this in the past however there is one small problem.... if someone wants to avoid this then why don't they just create a new account?
Well, this plugin is only good if you implement harsh screening on new client accounts. Some take it to the next level and even check paypal accounts - as that is a unique identifier of a client. Unless they also have several paypals hhh
Regards
@Spencer said: Yea I know the issue, it is an easy fix. Ive just been sooooo busy. Tomorrow ill have a fix.:
I look forward to the fix
I've been fiddling with this a little bit and worked out that when this is called, if it's a new customer there is no "uid" so the API searches for all overdue invoices. This means any new customers have issues signing up if you have overdue invoices in your WHMCS.
A quick bit of extra code seems to fix this so that only customers with a uid in session are checked:
Old code:
if ($anyoverdue['totalresults'] >= 1) {
New code:
if ($_SESSION['uid'] != "" && $anyoverdue['totalresults'] >= 1) {
Probably a better idea to use if(!isset($_SESSION['uid'])), or if(array_key_exists...), because you'll be generating undefined index errors every time that code is run when that session key isn't set.
Yeah my bad, I had changed it to isset but didn't update my copy/paste code for here
Cool, just figured it needed to be pointed out