R27481 ProductType - Manage Default Types
Code | R27481 |
Entity | General.Products.ProductTypes Entity |
Name | ManageDefaultTypes |
Attribute | IsDefault |
Layer | Back-End |
Events | Commit |
Modify | YES |
Action | If in the current record ('ProductType2') 'IsDefault = True' AND there is another "old" record/s ('ProductType1') in product types table with 'IsDefault = True', then modify 'ProductType1.IsDefault = False'. |
Description | When the field 'Is Default' in the Product Type's definition is checked, this specifies that
this type is set by default for new products unless another type is specified in the product
groups. To assure that the right Product Type is going to be automatically selected in new
products, there must be only one Product Type in which's definition 'Is Default' is checked.
In order to make sure that the field 'Is Default' is checked for only one of the product types, the current rule modifies it as follows: 'When saving, if the field 'Is Default' is checked for the particular record and there already is a product type in which definition the field 'Is Default' is also checked, then remove the check mark from 'Is Default' for all previous records for which it was set. |
Message | - |
Introduced In Version | 2017 |
Revocable | NO |
* For more information about the Business Rules Documentation Template and a short explanation of each column, see topic System Business Rules.