Original Message:
Sent: 07-11-2023 09:35
From: Andrew Quick
Subject: Copy Fields from WPMATERIAL to PRLINE when PR is Auto-Created
Hi Shannon,
We had this need a few years ago and ended up using an automation script that triggered on PRLINE Save and only on Add. We chose to use After Commit due to the issues you mentioned. The script itself consisted of getting the WPITEM set based on the PRNUM and PRLINENUM and then getting the PRLINE set again from MXServer to make the updates and save.
I am not sure if this was the most efficient approach, but it worked for us at the time and we have not had any issues with it. If anything, I think it will give you another avenue to look down!
------------------------------
Andrew Quick
TimkenSteel
Original Message:
Sent: 07-05-2023 16:13
From: Shannon Stommel
Subject: Copy Fields from WPMATERIAL to PRLINE when PR is Auto-Created
We are trying to copy a field from the wpmaterial object to the prline object when a new PR is auto-created by the Reorder Cron Task. This is for when the user adds a Planned Material Item on a Work Order that needs to be ordered thus firing the Reorder Cron Task to create a Purchase Requisition.
I created a new Automation Script named PRLINE.NEW but there seems to be a timing issue with when the Reorder Cron Task runs. I tried PRLINE.SAVE and adding a new crossover domain which neither worked. With wpmaterial being a view I tried pulling in the data from wpitem which also did not work.
Do you know if there's a way to add a field to what the ReorderCronTask is copying from the Work Order Planned Material item to the PR Line row? There seems to be other fields that are being copied over to the PR Line from the wpmaterial, like Required Date. Wondering how we can add one more field to copy to the PR Line, either by script or other means.
Thank you, Shannon
#MaximoApplicationSuite
------------------------------
Shannon Stommel
Insteel Wire Products
------------------------------