This document summarizes the events that should be used on a class or a representation to solve an issue. It is a compilation of other documents.
WHEN AN INSTANCE (OR A COLLECTION LINE) IS CREATED |
---|
Need to cover | Event to be used | Script level |
---|
Assign a default value that depends on the circumstances (current user, date, global parameter values) rather than on another property. | INIT event for the property | Class of the property |
Assign a default value (that can be changed during the input) with the result of a computation based on other properties (with a re-computation if the original properties change). | PROPAGATE event on every property whose update triggers a re-computation | Class of the properties |
Assign a default value that will only be set if no value was entered for creation of an instance. | AINSERT_CONTROL_BEFORE event (if the property is not filled) | Class of the property |
Perform a control that does only depend on the value of the field to be controlled. | CONTROL event on the property | Class of the property |
Perform a global control based on a combination of properties, assuming that all the controls done on the individual properties (individual controls, mandatory fields controls), type based controls are already done. | AINSERT_CONTROL_AFTER event | Class of the property that has the highest level |
Update additional tables not described in the class when an instance has been successfully created in database. | AINSERT_AFTER event (if you generate an error, the database transaction will be aborted) | Class |
WHEN AN INSTANCE (OR A COLLECTION LINE) IS MODIFIED |
---|
Need to cover | Event to be used | Script level |
---|
Perform a control that depends on the value of the field to be controlled. | CONTROL event on the property | Class of the property |
Prevent the modification of a property if some conditions that don't depend on other properties are met. | CONTROL on property: compare snapshot value and current value | Class of the property |
Perform a global control based on a combination of properties, assuming that all the controls done on the individual properties (individual controls, mandatory fields controls), type based controls are already done. | AUPDATE_CONTROL_BEFORE event | Class of the property that has the highest level |
Prevent the insertion of a line in a collection if some conditions are met. | ADDLINE_BEFORE on the collection COLL: perform the check (this is the header, ALINE is the position to be inserted) | Class that includes the collection |
Prevent the deletion of a line in a collection if some conditions are met. | ADELLINE_BEFORE on the collection COLL: perform the check (this is the header, ALINE is the position of the line to be deleted) | Class that includes the collection |
Reassign a default value (that can be changed during the input) with the result of a computation based on other properties (with a re-computation if the original properties change). | PROPAGATE event on every property whose update triggers a re-computation | Class of the properties |
Update additional tables not described in the class when an instance has been successfully updated in database. | AUPDATE_AFTER event (if you generate an error, the database transaction will be aborted) | Class |