I have a request to set a custom date field to default from the OrderHed to the Order Line and Release.
I set this custom fields in all the tables, now that I’m trying to set the date as a default from the OrderHed but is turning quite difficult.
Any insights how to set this as a default value (just like the need by date)??
Here is what I have so far
Sorry forgot to mention I came to this point of using today function just to validate my condition, but I want to replace that expression with the MyDate_C field
I tend to prefer using Method directives for this sort of thing. I’d probably put something in the Preprocessing for SalesOrder.Update that checks to see if that OrderHed date field was changed, then set a flag in CallContextBPMData which says the details need to be updated.
Then in Postprocessing I’d see if that flag was set, then update the details accordingly. Similar to how we update the shipto for our details if the header was changed and the user wanted us to change the details.
foreach (var OH in ttOrderHed)
foreach (var OD in (from tOD in Db.OrderRel where
tOD.Company == OH.Company &&
tOD.OrderNum == OH.OrderNum
OD.ShipToCustNum = OH.ShipToCustNum;
OD.ShipToNum = OH.ShipToNum;
} // for each Order Detail
} // foreach Order
Thank you Marjorie I will try your recommendation using Method directives