coolOrangeLabs / powerGateTemplate

powerGate full functional sample ERP integration
MIT License
3 stars 3 forks source link

Check for virtual components in GetVaultBomRows not reliable #238

Closed ThomasRossmeisl closed 1 year ago

ThomasRossmeisl commented 1 year ago

Description

According to the product documentation it is not reliable to check for the Bom_XrefTyp property to determine whether an entity is a virtual component or not. A reliable way to check is to check if _EntityTypeID is set.

https://doc.coolorange.com/projects/powergate/en/stable/code_reference/commandlets/show-bomwindow/required-functions/get-bomrows/?highlight=_EntityTypeID#examples

Changes

Check for virtual components in GetVaultBomRows now uses _EntityTypeID instead of Bom_XrefTyp Added "BomType" = "Virtual" Property to virtual bom rows