EntityLog deson't log related entity arguments on modify operation


When creating or deleting an entity, I can see related entity parameters (name, id, whatever).
Buy when modifying the entity, the entity log shows only changed parameters of the modified entity.
How can I change the behavior of modify operation so it shows the same related entity parameters?
Or how to set it up, so those related entity parameters show up in the entity log screen?
Should I create a separate view for that purpose?


The logs contain information about the time of modification, the user who has modified the entity, and the new values of the changed attributes. Log entries are stored in the SEC_ENTITY_LOG table corresponding to the EntityLogItem entity. Changed attribute values are stored in the CHANGES column and are converted to instances of EntityLogAttr entity when they are loaded by the Middleware.

I assume, that you may use Entity Snapshots for your purpose.


Hi @firstova

Thank you for the Entity Snapshot suggestion.
Apart from that, is there any way to extend the EntityLogApi to override the registerModify() methods, or edit the entity log view to include custom columns?

You can extend the com.haulmont.cuba.security.app.EntityLog bean in your project and customize its behavior.

See how to register an extended bean in a project here: Extending Business Logic - CUBA Platform. Developer’s Manual

One example of customizing can be found here: Is there a way configure "Entity log by default?" - #9 от пользователя peterson.br

1 Like