- Crie um registro de Rule onde vc pode escolher se está ativo, o objeto da regra e o nome
- Na aba de relacionados, crie um Rule Entry, informe a ordem, o critério, se é usuário e se tem email.
- Crie um flow de execução de registro para a Rule que você criou, chamando o apex action para executar o processo de filtro
https://developer.salesforce.com/docs/component-library/bundle/lightning:recordEditForm/documentation
https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_methods_system_schema.htm#apex_System_Schema_getGlobalDescribe
https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/controllers_server_actions_call.htm
https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_comparable.htm#apex_comparable
https://trailhead.salesforce.com/pt-BR/trailblazer-community/feed/0D54V00007T4PJ3SAN
https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_classes_email_outbound_single.htm#apex_Messaging_SingleEmailMessage_setToAddresses
https://daily.dev/blog/add-to-list-javascript-array-manipulation-basics#:~:text=push()%20is%20your%20go,without%20messing%20up%20the%20originals.
https://vijayasankarn.wordpress.com/2018/07/05/salesforce-apex-evaluate-boolean-string-expression/