[Recursive BOM] Verify if a BOM have recursive products
Description
Today we can create a BOM (e.g. teste1) inserted with another BOM (e.g. teste2), and this second BOM has the first BOM (like the attach). The recursion can be created with any quantity of products and this can cause some problems with user, like we had.
To validate this, i've used as base the class BOMVerify, but in the BeforeSave of the MProductBOM and this can verify any quantity of recurve products.
Environment
None
Attachments
2
Activity
Show:
Igor Martins November 20, 2018 at 5:46 PM
Edited
Patch added.
Igor Martins November 20, 2018 at 5:27 PM
Hi Carlos,
Sorry for taking so long.
Like the .jpg that i've send. The product "1" has product "2" as one of their materials. But you can add the product "1" as a material of product "2". So i've automatized the processes to verify the recursivity. Now you can't save the product if they are recursive.
I'm creating the patch and will send soon
Carlos Ruiz November 20, 2018 at 12:37 PM
Hi ,
I don't understand what's the improvement suggested.
As you explained the BOM Verify process is required when working with BOMs.
Today we can create a BOM (e.g. teste1) inserted with another BOM (e.g. teste2), and this second BOM has the first BOM (like the attach).
The recursion can be created with any quantity of products and this can cause some problems with user, like we had.
To validate this, i've used as base the class BOMVerify, but in the BeforeSave of the MProductBOM and this can verify any quantity of recurve products.