handlers.assign_modelling_cluster_by_acl

class AssignModellingClusterByACLHandler(handlers.eventhandler.EventHandler):

Whenever somebody creates an Application, remove all write access ACLs that do not match a Group Cluster, and assign the correct Modelling Cluster based on the ACL.
Customer-specific automation, requires a special data model. Should not be used for testing.

name = 'Set Initial Values, ACL and Modelling Cluster'
description = 'Whenever somebody creates an Application, remove all write access ACLs that do not match a Group Cluster, and assign the correct Modelling Cluster based on the ACL.'
conditions = {'event_types': ['FactSheetCreatedEvent'], 'fs_types': ['Application']}
config_template = {'auto_subscribe': {'type': 'RESPONSIBLE', 'role': 'Steward'}, 'editorial_status_field': 'editorialStatus', 'editorial_status_initial': 'Draft', 'editorial_status_prefix_field': 'editorialStatusPostfix', 'deletion_days_field': 'editorialDraftExpiryDate', 'deletion_days': 30, 'relation': 'relApplicationToModellingCluster'}
def handle(self, event, fs, **kwargs):

Called automatically whenever a FactSheetUpdated event comes in via webhook.