webERP Forum
MRP: add WO scheduling + fix - Printable Version

+- webERP Forum (
+-- Forum: webERP Discussion (
+--- Forum: Feature Requests (
+--- Thread: MRP: add WO scheduling + fix (/showthread.php?tid=234)

MRP: add WO scheduling + fix - opto - 05-19-2012

at the moment, MRP schedules all PO's and suggested WO's to be required for the end date of a WO (maybe minus vendor leadtime).

In many cases, this is not desirable.
If my BOM works on a component part, I need this part before the end date of the WO. So MRP must be able to suggest a correct purchasing date for this component.

The following fix allows to do this in a more detailed scheduling:

in BOM table, add a new field DaysRequiredBeforeEnd. Default=0, so no changes in behaviour if user does not set this.
One needs to be able to maintain this DaysRequiredBeforeEnd in the script adding/updating the BOM items.

In MRP, replace duedate=MRPDate= RequiredDate-leadtime with:

duedate=MRPDate= RequiredDate-leadtime - DaysRequiredBeforeEnd.

Now, MRP will schedule the planned purchase date or a proposed WO end date such that the items are available at the requested number of days before the primary WO end.

I just did a proof of concept, which works fine:

add new field to db BOM table, default = 0.
Manually set this field in the db for a few components to 5 or 10 days
Change CreateLowerLevelRequirements to take account of this field.

All purchase dates of lower level items are now adjusted accordingly.

Additional changes necessary:
add the same code for top level items
add code to set DaysRequiredBeforeEnd from the BOM maintenance scripts.

I am also willing to adapt the wiki doku on this and hope it can go into the core code.


RE: MRP: add WO scheduling + fix - Exsonqu_Qu - 05-19-2012


It sounds a good idea.

If there is no misunderstanding, I think daysrequiredbeforeend is a cycle time for the process, or processing period. Is it up to processes or components? It seems components related according to your suggestion. But are the days required variable with different processes or different routines?

Currently, if you have lots of low level parts manufactured, you must issue a work order accordingly. Does this solve your problem?

Best regards!