Make Project ID Field to be Mandatory on Purchase Order Screen

Any leads please on how to achieve this, I would like it to throw an error when a user leaves the field blank.

The screen you need is Extended Property Maintenance

Tickbox: Required when adding.

3 Likes

I have done this but it does not give any prompt when the field is blank, I am still able to save. I have gone ahead and regenerated data model as well

This works for the second release onwards but for the first release the system does not prompt that project ID is required.

1 Like

The first release on a PO line is created “automagically” by the system with no user interaction so there is no way to simply “not allow” the first release.

What you might do is create a UD field on the PODetail table/screen where the user can enter the Project ID and then a Data Directive BPM to copy that value into the Release. I’ve done something like this on Sales Orders (which has a very similar functionality for release 1), but don’t think I’ve tried it on Purchase Orders.

2 Likes

Unfortunately, PO.Update → Pre-Processing does not carry the PORel table after adding a new line.

@Ernie suggestion would solve your problem. PODetail.ProjectID_c and copy this to the rel in post processing BPM on PO.Update. You can then make this custom project field required before save.

@Ernie , could you put an in-process data directive to stop it and pop up a message?

Yes… I would try both but I don’t think a Method Directive on .Update is going to work in this scenario.

I believe what we’ve done was check for it when the PO is released. When released goes from false to true, to a query for all of the releases and if any don’t have a project, then throw an exception so that the PO can’t be released. On create can get you stuck in weird loops you can’t get out of.

We also have BPM’s and customizations for auto-populating the projects, but that’s a lot more involved.

1 Like