Right now we can disable sending overdue notices on a per client basis. Using the "
Don't Send Overdue Emails" option in the client profile.
When this option is selected the payment reminder emails are still being sent. Only the overdue notices are blocked.
We need an extra option to disable the payment reminder emails too since some clients have a special payment agreement with us.
Merged Ideas
Disable Payment Reminder Notifications on a Per Account Basis
The automated 'Payment Reminder Notification' is useful in most situations, however, for clients that have setup automated payments on the day that the invoice is due - it's a redundant reminder, and we've received a few requests to disable it. Similar to how the "Don't Send Overdue Emails" option can be set on a per account basis, a similar "Don't Send Payment Reminders" checkbox in each client's profile would also be a huge help.
36 Comments
Login to post a comment.
https://gist.github.com/RWJMurphy/3ee801306f2cfca79d61b38041dcdaed
To not send when a specific payment method is chosen, see this GIST:
https://gist.github.com/eugenevdm/2ae416d35b6b5e4b34f88c625cbc5ae8
Why is this important? Clients that need those post reminders, ALSO need to receive the "INVOICE REMINDER EMAIL" pre-due date. Currently that pre-due date reminder cannot be used at all, as they go to my "good" customers regardless of that setting.
This could be done, I'm shure off it
There is some conditional language in the templates.
Now - I don't know how the "Credit Card Invoice" template is triggered, but our system seems to send out the "Invoice Created" template.
I use the following block as part of the template:
[co]
"Automatic Credit Card Withdrawal" is how we named our credit card gateway.
I created a client group named "Automatic Withdrawal" and assigned it to those specific Autopay clients. Then used similar conditional language in the invoice/reminder templates starting with {if $client_group_name eq "Automatic Withdrawal"}. Hope this helps others while we wait for couple more years to get this solution implemented. - All the best.
Of course, due to the limitation of only being able to assign (1) client group to client, this won't work if you already use a client group for your clients. (Here's the feature request for allowing a client to belong to multiple client groups = https://requests.whmcs.com/topic/add-client-to-multiple-client-groups ), make sure to head over there and give it a thumbs up too.
These two features alone would provide huge functionality and improve automation ability.
Back to the drawing board.
Still be much better if this could be built in option of course, preferably a tick box for each service (so hosting = subscription, all else (domains etc...) get normal billing).
1. Add a client group (in my case, Automatic Hosting Payments) and check the box saying to separate invoices.
2. Add the following to your configuration.php file:
[co]
$smarty_security_policy = array(
'mail' => array(
'php_functions' => array(
'strpos',
'isset',
'empty',
'count',
'sizeof',
'in_array',
'is_array',
'time',
'nl2br',
'var_dump',
),
),
);
3. The invoice items that you want this to apply to need some kind of common string. In my case, all my hosting plans have "Level" in the title.
4. Add the following to the top of your email template and adjust the first two variables - the first is the string that's used in the names of the invoice items, the second is the name of the client group:
[co]
{assign var = "group_name" value = "Automatic Hosting Payments"}
{assign var = "auto_pay_true" value = []}
{foreach key = k item = v from = $invoice_items}
{var_dump( strpos($v.description, $search_term) )}
{if strpos($v.description, $search_term) === false}
{$auto_pay_true[] = "false"}
{else}
{$auto_pay_true[] = "true"}
{/if}
{/foreach}
{if ( $client_group_name eq $group_name ) and ( in_array( 'true', $auto_pay_true ) )}
{assign var = "auto_pay" value = "true"}
{else}
{assign var = "auto_pay" value = "false"}
{/if}
5. After that you can use
[co]
Holy hell. Hope this helps someone. But I hope more that WHMCS adds some kind of core solution for this.
- Global checkbox for "Disable invoice emails for subscriptions," where both the "new invoice" email and the reminders would be disabled if the client sets up automatic payments.
- Would work for Stripe, PayPal, or any other gateway that allows auto payments.
- The first invoice, as well as manually-emailed invoices, would still be sent.
- Could be overridden on a per-client basis, in case there are people who do want to receive reminders.
- Some kind of conditional language in the email templates saying "your invoice will be automatically paid on..." so that clients who do want reminders and who've set up auto payments aren't confused.
I don't know how much of that is possible but if anyone knows how to accomplish at least the last one, please let me know. I keep getting people thinking they need to pay their invoice and it's a pain emailing everyone back to tell them that no, it'll be automatically paid...
WHMCS Team, Please consider this option.