Guide - Calculate Sales Unit Price from SPL with BPM's

Our company is trying to find ways to keep up to date with pricing. Unless we missed something, Epicor seems be missing some easy tools to maintain both Supplier Pricing and Sales Pricing.
I was really hoping the system had better tools to take care of this, please let me know if there is.

Two ways we have for BATCH entering Supplier Pricing.

  1. DMT
  2. UBAQ

With both of these tools, it can still be very time consuming.
We would also like to synchronize our buying price with our sales price, rather than try to maintain that as well.

Step 1. Creating UD fields
– UD Column Maintenance

** Regenerate Database after columns are added or you will see this & potentially some random errors **
image

Part_UD
PrSupPrice_c
Latest Changed BaseUnitPrice for Part Record in SPL

SalesPriceOvr_c
Override Checkbox for manual Sales Price

SalesPricePer_c
Price Markup Percentage for calculation. Specified on Part Form.
(Initial Value 60 %)
Since this is a new field all new and existing records will have this default value

VendPart_UD
FutureEffective_c
Check Box for Future Effective Dates to Trigger BPM and update Sales Unit Pricing

– Extended Properties
Set PrSupPrice_c to read only since its a copy of the SPL price and should not need manual edit
image

– Customization on Part Form
Added these items to match the Part_UD Columns that were added.
image

– Method Directive BPM’s - VendPart.Update

  • Pre Processing

New Row Effective Today
When a new part record is created in the SPL it will run the calculation. I had to create this since my next BPM did not fire on new records only changed ones.

  • Post Processing
    Copy SPL to Part Table (PrSupPrice_c)
    This one is a bit sloppy but does the majority of the work doing condition checks and setting fields.

Conditions:
VendPart.BaseUnitPrice Changed
VendPart.PrimaryVendor False to True
VendPart.FutureEffective_c True to False
Effective Date greater than or equal than Today()
SalesPriceOvr_c Checked or Not Checked

Operations:
Fill Table by Query based on True or False from SalesPriceOvr_c
Invoke BO method Part.UpdateExt to save Part Table with calculated values.

Calc used in mapping
queryRow.ttVendPart_BaseUnitPrice * ((queryRow.Part_SalesPricePer_c / 100) + 1)


image

image

– Data Directives

  • In-Transaction

VendPart
Future Effective Date
This monitors for the VendPart.EffectiveDate when it is greater than todays date. Sets field VendPart.FutureEffective_c to True

Part
Calculate from PrSupPrice
This will recalculate from the Part.PrSupPrice_c when conditions are met on Part form changes.

Set Field Code
ttPartRow.PrSupPrice_c * ((ttPartRow.SalesPricePer_c / 100) + 1)

1 Like

UBAQ and Scheduling Price changes on Future Effective Dates

We need to schedule future SPL effective dates to calculate our Sales Prices but not until that day arrives. Recently I learned you can create a UBAQ and inside of that create a BPM to set your fields. You can also schedule the UBAQ from another BPM in the SysAgent table.

The way I chose to do it is to use BAQ Export Process, which will run the BAQ and export me a “Log” of what parts were updated.

–UBAQ
image

image

This can be saved to a process set and then scheduled.
image

From the BPM on the first post, once the VendPart.FutureEffective_c is changed from True to False it will fire the other BPM to calculate Sales Price on those parts.

I hope its not too much of a Rube Goldberg machine. I’ve been learning as I go. Let me know if you have any questions. Thanks to everyone on the forum that has helped!

image

2 Likes

Demo Videos

Link to UBAQ Scheduling

1 Like

Nicely done!! Thanks for posting it!