New PO Suggestion BPM

Our purchasing manager would like to be informed by email whenever a line where Buyer ID = “Machine Buyer” is generated in the New PO Suggestion module. Is it something that can automated using a BPM ?

Should not be too hard on a standard data directive on the SugPoDtl table.

1 Like

You would just set a condition similar to this one ?

Yes, something like that. I originally was going to suggest the Added row, but in a standard directive it is after the update. It is possible you may have to put the condition in transaction for an added row and the email in a standard bpm that is triggered by the other bpm.

1 Like

Greg, I have a beginner question. What do you mean by this: "the email in a standard bpm that is triggered by the other bpm’

Not Greg, but there are timing aspects of each flavor of directive that determine when they fire.

Like this.

3 Likes

I meant How do you trigger a BPM by another BPM in a workflow ?

Within a Method Directive you can have a Post Processing Directive that only fires if it was enabled by a Pre Processing Directive. The same relationship can exist in Data Directives between In Transactions and Standard Directives.

For example, in an In Transaction Data Directive you could check you criteria to then determine if you will fire the Standard Data Directive or not.

Here is an example. In this case I needed some data in the standard, so after the true condition I set a few fields and then added the enable Standard widget.

then in the standard directive the condition is this is enabled from the directive name.

3 Likes

It’s 2024. You should not be firing off emails from a BPM and (potentially) flooding users’ inboxes. Create a scheduled function that summarizes multiple items (if any) and emails the list in a single item.

4 Likes

While I tend to agree with you, some people still prefer it.

I think they just haven’t been exposed to better ways, but I try not to judge.

Possibly, but if it is timely that would just tell you as it does now for them that it had already happened.

I am still pretty mediocre at using/building BPMs and I just started to dip my toes into functions.

This approach could miss a lot of data with po suggestions. If the suggestion was made and the PO generated then the suggestion is gone and not found by a timed process.

Personally, I find functions easier. Especially if you’re just grabbing data like this. You don’t have to worry about which exact method or field change to attach to make sure your BPM fires consistently (or even at all).

I can write up a quick walkthrough on Monday (work permitting).

Easy to fix that. Just schedule the function to run right after the suggestions as part of a process set. You still get summarized results and nothing should fall through the cracks.

4 Likes

Definitely interested in seeing a walkthrough for this if you have time

Yes please @jtownsend, would love a starter walkthrough if you have the time.

And this is the crux of my notification rants. John and Kevin are both right. It’s 2024, give notification control back to the recipients. Let them choose the frequency, method, and the format of notifications.

4 Likes

That will only catch the scheduled runs though. If it’s run on demand, that won’t catch it.

There’s also new BPM’s on processes, but they have a problem in that they don’t wait for the process to finish before they fire, so you have to get creative on making sure the process is done before you fire off your function.

1 Like

Attached in the .zip file is a BAQ and Epicor Function (11.2.400.14) that can be scheduled to let Buyers know that they have PO Suggestions to process.

To use it you will need to setup a User Code as follows:

POSuggestionsToProcess.zip (43.1 KB)

The function calls the BAQ and then uses the data from that and the User Code to format and send an HTML email with a table containing the New PO Suggestions:

You could also include a hyperlink in the Email to allow them to open PO Suggestions in a browser!

2 Likes