Give staff an easy way to remove spam connection requests from their requests queue, as well as give Rock Admins an easy way to complete the requests and merge the person records.


Workflow 1 - Mark Connection Request as Spam:
This workflow updates the connection opportunity to "Spam" and assigns to our Rock admin.
This workflow creates an entity set (required for the person merge), redirects the Rock admin to the person merge page, and marks the connection request as inactive.
The Code Behind:
{% connectionrequest where:'ConnectionOpportunityId == 1031 && ConnectionState == 0' securityenabled:'false' %}
{% assign spamPersonId = Workflow | Attribute:'SpamPerson','Id' %}
{% assign entitySet = connectionrequestItems | Select:'PersonAlias' | Select:'Person' | Select:'Id' %}
{% assign entitySet = entitySet | AddToArray:spamPersonId | CreateEntitySet:15 %}
{{ 'Global' | Attribute:'InternalApplicationRoot' }}PersonMerge/{{ entitySet.Id }}
{% endconnectionrequest %}
{% for request in connectionrequestItems %}
{% modifyconnectionrequest id:'{{ request.Id }}' securityenabled:'false' %}
[[ property name:'ConnectionState' ]]1[[ endproperty ]]
{% endmodifyconnectionrequest %}
{% endfor %}