Jump to content

Modifying Mass Mail Recipients List


websavers

Recommended Posts

We use a provisioning/server module that sends API requests to another panel to manage VPSs. This means that the node and VPSs on each node are controlled external to WHMCS. 

When it comes time to send maintenance notifications, if we want to limit those notifications to only those clients with VPSs on a particular node, there currently appears to be no way to do this with WHMCS. Is anyone aware of a way to add a custom filter to the mass mail page, or a way to modify the recipients list?

I'm afraid I haven't spotted any hooks that would help with this. And unfortunately the multiselect box with recipients in it that appears after you click "Compose Message" (when constructing a mass mail), does not show the complete list of emails here (only the first 50), so we can't modify that with Javascript to get what we want (and given that it only displays 50, I doubt it even uses that list as the *actual* recipient list -- it's just there for demo purposes).

It sure would be nice if there was a hook that allowed modifying the recipients list, or better yet a hook that allowed any module to add their own filters/criteria boxes to the mass mail page. I've already +1'd a feature request that asks for config options to be added here, but that's not getting a lot of support (shocker) in the requests system.

Link to comment
Share on other sites

18 hours ago, websavers said:

When it comes time to send maintenance notifications, if we want to limit those notifications to only those clients with VPSs on a particular node, there currently appears to be no way to do this with WHMCS. Is anyone aware of a way to add a custom filter to the mass mail page, or a way to modify the recipients list?

how much use of Client Groups do you make on your site ? if none, then it would be an option to write a hook that assigns these clients to a client group and then you use that group in Mass Mail.

the complicating factor would be if you're already using groups as clients can currently only be in one group at a time (there's a FR to change that, but they get nowhere).

if you're not using groups, then the hook is either a capsule update to tblclients, or you could use the UpdateClient API if you prefer (assuming you've already created the client group previously)...

if you're already using groups, then you could keep a secondary table of existing values before updating, and then return these values after mailing... that could be a pain though!

18 hours ago, websavers said:

I've already +1'd a feature request that asks for config options to be added here, but that's not getting a lot of support (shocker) in the requests system. 

it would do no harm to post a link to that request- it's highly possibly nobody else would find it unless you do.

Link to comment
Share on other sites

18 hours ago, websavers said:

I was thinking about using Client Groups; but we do already have groups configured, making using that more complicated for sure.

same idea, but how about using an admin-only Client Custom Field instead... so get the hook to assign a certain value to this field for those affected clients and then use that CCF value as a filter in Mass Mail ??

18 hours ago, websavers said:

thanks - another 6-year feature request... at least it's still tagged as "under consideration"! 🙂

Link to comment
Share on other sites

Hey Brian,

I like the idea of the Client Custom Field; pretty decent workaround, especially since we should be able to modify the VPS management extension to update it.

4 hours ago, brian! said:

thanks - another 6-year feature request... at least it's still tagged as "under consideration"!

Haha, yep!

I feel like it would be beneficial for WHMCS to actively encourage developers to post development-specific feature requests in the community instead of the requests system as there's clearly way less WHMCS devs than users, so the popularity thing isn't really going to work for those types of requests. It would have to be limited to requests to modify the API and/or Hooks or something like that.

Link to comment
Share on other sites

18 hours ago, websavers said:

I like the idea of the Client Custom Field; pretty decent workaround, especially since we should be able to modify the VPS management extension to update it.

my thought was you could update the field with a date when run, that way you can just reference the appropriate date in MM and should remove the need to empty the fields after use.

18 hours ago, websavers said:

I feel like it would be beneficial for WHMCS to actively encourage developers to post development-specific feature requests in the community instead of the requests system as there's clearly way less WHMCS devs than users, so the popularity thing isn't really going to work for those types of requests.

oh gawd - a two-tier feature request system! 😲

another avenue for hook/API issues might be to raise it on the WHMCS GitHub site... my suspicions is that would be a faster path than than a "normal" FR, but probably not a suitable one for the above FR... but if you thought there was an issue with an existing hook/API, then the GH site could be a better option.

the tragedy of the FR system is that if many of those suggestions had been asked here first instead, there would have been simple solutions posted... instead their suggestions are gathering dust in the shed at the bottom of the garden that is the FR site.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated