StatCan / StatCan.OrchardCore

Houses StatCan OrchardCore Modules
https://statcan.github.io/StatCan.OrchardCore/
MIT License
57 stars 12 forks source link

Allow access to a team's email adresses #161

Closed jptissot closed 3 years ago

jptissot commented 3 years ago

Add a button to the SummaryAdmin list for the team that copies the team's emails in the outlook format.

You will need to add a driver to add the button on the team's summary admin page.

This is the code used in the view with the old platform

<div {% if teamMembers != null %}onclick="select_all_and_copy(document.getElementById('{{Model.ContentItem.ContentItemId}}_emails'))"{%endif%} class="btn btn-primary btn-sm {% if teamMembers == null %}disabled{% endif %}"><i class="fas fa-envelope"></i> {{ "Team" | t }}</div>
<div class="sr-only" id="{{Model.ContentItem.ContentItemId}}_emails">{% for member in teamMembers %}{{ member.Content.ParticipantPart.Email.Text }}{% if forloop.last == false %};{% endif%}{% endfor %}</div>
{% script src:'~/OrchardCore.Workflows/Scripts/crossbrowserclipboardcopy.min.js', debug_src:'~/OrchardCore.Workflows/Scripts/crossbrowserclipboardcopy.js', at:"Foot" %}