Personal Data Reporting Configuration in Backoffice Framework

Technical details about creating audit reports in Backoffice Framework.

Security

By default, reports are stored in a secure folder called auditreports, which is set as secure using the Secure Media Access mechanism. If you want to store them in a different folder, override the reportFolderName bean property of de.hybris.platform.auditreport.service.impl.DefaultAuditReportDataService, and follow the Secure Media Access documentation for making your folder secure.

Erasing Customer Data

Audit Reports are configured to be automatically removed in two situations:
  • if a specific period of time passes after the data creation
  • if the customer account is disabled and the grace period passes
By default, Audit Reports reports are removed:
  • after 30 days since the report creation:
    # RETENTION RULE
    insert_update AfterRetentionCleanupRule;code[unique=true];retirementItemType(code);itemFilterExpression;actionReference;retentionTimeSeconds;retirementDateAttribute(enclosingType(code),qualifier)
    ; AuditReportDataRule; AuditReportData; 1=1; basicRemoveCleanupAction; 2592000; AuditReportData:creationtime
  • after 2 days since a user disables his/her account, you can configure it by customersWithoutOrdersRetentionCronJob, and customersWithOrdersRetentionCronJob

To prevent the data from being automatically deleted, the Toggle Item Lock action can be used. By default, it is available for Customer Support Administrator in both Administration Area and Customer Support Cockpit.

Customization

Custom Report Converters

To customize reports generation, extend following spring bean definition with your strategies that implement the interface: de.hybris.platform.auditreport.service.ReportViewConverterStrategy.

<alias name="defaultReportViewConverterStrategies" alias="reportViewConverterStrategies"/>
<util:list id="defaultReportViewConverterStrategies">
    <ref bean="reportViewConverterStrategy"/>
</util:list>
The default implementation of de.hybris.platform.auditreport.service.impl.DefaultReportViewConverterStrategy allows you to use Apache Velocity template stored in the AuditReportTemplate object. The template operates on reports stored by:
  • always: an instance of java.util.List<de.hybris.platform.audit.view.impl.ReportView>; available under the reports key
  • when the template includeText attribute is set to true: you can operate on a text representation of the report; available under reportsText key

    Example: A standard implementation provides json representation of the data, whereas a custom implementation may provide any other textual representation of the data.

The default implementation uses the de.hybris.platform.auditreport.service.impl.JsonReportViewConverterStrategy to create a text representation of the report.

Customizing employees

To generate an audit report, the employees have to be members of one of the following groups:
  • Customer Support Agent Group
  • Customer Support Manager Group
  • Customer Support Administrator Group
  • Customer Support Backoffice users belonging to the Backoffice Audit Group

For more information on how this functionality is implemented in SAP Commerce Cloud see the following topics: