We're updating the issue view to help you get more done. 

Replace entity relationship between products and product types with an entity link

Description

The product archetypes product.medication, product.service, and product.merchandise may each have an entityRelationship.productTypeProduct relationship to an entity.productType.
This is a bidirectional relationship, so an entity.productType may have many products associated with it.
This affects performance on databases with thousands of products.

A better approach would be to replace the entityRelationship.productTypeProduct with an EntityLink relationship. This would be from the product to the product type.

This would require:

  • a new entityLink.productType archetype, that links a product.medication, product.merchandise, or product.service with an entity.productType

  • changes to the product.medication, product.merchandise, product.service, and entity.productType archetypes

  • report changes:

    • reports/Reporting/Reports/Product/A4/Product List Report.jrxml

    • reports/Reporting/Reports/Product/A4/Stock Valuation Report.jrxml

    • reports/Reporting/Reports/Product/A4/Stocktake List.jrxml

  • database migration

Users would need to manually install the reports, and update any of their customised reports.

Environment

None

Status

Assignee

Tim Anderson

Reporter

Tim Anderson

Labels

None

Fix versions

Priority

Minor