Skip Navigation

[Resolved] CRED Notification to user's manager

This support ticket is created 6 years, 9 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

Tagged: 

This topic contains 5 replies, has 2 voices.

Last updated by Shane 6 years, 9 months ago.

Assisted by: Shane.

Author
Posts
#550054

I have a site where sales representatives and sales managers interact. Sales representatives each have a single sales manager and representatives can submit requests to managers.

I have a separate custom post type called "employees". There is one record for each. Each employee also has a standard WordPress user account. Employee posts each have the same user set as the author. This is to work around restrictions related to storing custom fields for users. My custom information is stored with the Employee custom post type to avoid conflicts.

I have a CRED form that representatives fill out that creates new Requests. I want to send a notification to a user's manager whenever a request is added. I am able to look up a representative's manager user id, and from there I can retrieve the manager's email.

How can I configure the CRED notification to be sent to this manager's email address? The settings for Notifications seem numerous and complicated yet I am unable to figure out what should be a very simple task.

#550140

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Patrick,

Thank you for contacting our support forum.

Is there a page for each of the Managers? It will be much easier if you had a page with each of the managers and then add like a contact form to each of the managers page. Lets say a customer wants to contact a manager then they will go to there page and then fill out the form.

Another way is to have the form but have a list of managers that the user can select from to send their mails to.

Please let me know what you think of these suggestions.

Thanks,
Shane

#550169

It's a little more involved than that. Each representative has one or more territories. The company offers promotional items to representatives. Things like movei tickets, T-shirts, etc. Representatives can use these items to try to win new customers.

To obtain a promo item, representatives must create a prospect post. This is a business they want to sell to. Prospects have contact info & a potential sales amount that the representative must fill in. Then, they request a promotional item from a list and fill out a request. The request is just a form with a drop-down, for choosing which prospect they want the item for, and a place to add any other notes.

The managers receive requests from there own representatives. They can approve or deny these requests, sending a response to the involved reps. So, if 3 reps all want a set of baseball tickets, each request should trigger an email to the correct manager. If the manager chooses to approve one of those requests, I need to notify the successful representative that they have won the item, and also notify the unsuccessful representatives that they have not.

The problem with CRED notifications is that they provide no organized way to do these sorts of things. What I need is an effective way to send small groups of emails informing affected members of this site each time that an affecting event happens. If a representative submits a new request, the manager gets notified. If an item is awarded, winners and losers are all notified.

CRED makes it too hard to send messages. I should be able to send any number of emails, each formatted with database information, to any number of recipients, without having to litter my custom post types with redundant fields of data, just to get the email addresses & names to become available on the CRED editing page.

Is there any other approach to doing this that would make more sense? Hopefully you guys will see the light and change the notification tool to be an entirely separate module. WP-Types developers should be able to programmatically embed email communications dynamically, throughout their code for situations like this. CRED notifications just seems to be far too limited.

#550384

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Patrick,

Since the notifications are completely dependent on when a post is created, my advise is to make some use of multiple pages as this would be the best way to achieve this because you are able to secretly pass the email to the notification settings so that the mail gets sent out.

Once the customer or personnel is on the correct user page then the email should be sent normally. Unfortunately such advanced setup that you require is not something that can be achieved easily as our Notifications is strictly for post creations/edits and is limited to the fields that are on the current form to send notifications to.

However there are other contact form plugins out there that you can try in the event our CRED notifications is not capable or proves difficult to implement your query.

Thanks,
Shane

#550437

Thank you Shane.

I've learned about the persistence setting for generic fields & how it's necessary in order to get a notification selector to work on the CRED edit page.

Do these also have to exist in the fields of the custom post type the CRED form is editing?

Also - I need an elegant way to send multiple notifications. Imagine an auction site where someone wins the auction. What is the best way to build an automated message function that sends winning notification to the winner and also send lost notifications to all of the losers?

It would be tremendously useful if there were a more versatile way to do things with lists of emails. If a view could iterate over members of a CPT and send different messages to each depending on other field values for each post, it would have tremendous application.

#550549

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Patrick,

Yes the persistence is what you will use for a generic field so that it shows up in the notifications.

No these fields do not have to already exist but if you set it to persist then the field will automatically be created when the post is submitted.

This third question might be tricky but it seems that you may be able to achieve this by creating a winner/loser select field for your auction CPT and populate this information with the users.

When an auction is over you can edit it and change the custom field for the finish and then you can set the notifications on the backend to send an email to the winner and the loser.

Please let me know if you understand what i'm saying.

Thanks,
Shane

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.