houdini/app/views/settings/_users.html.erb
Bradley M. Kuhn 22adb4d5fd Relicense all .erb files under new project license.
The primary license of the project is changing to:
  AGPL-3.0-or-later WITH Web-Template-Output-Additional-Permission-3.0-or-later

with some specific files to be licensed under the one of two licenses:
   CC0-1.0
   LGPL-3.0-or-later

This commit is one of the many steps to relicense the entire codebase.

Documentation granting permission for this relicensing (from all past
contributors who hold copyrights) is on file with Software Freedom
Conservancy, Inc.
2018-03-25 15:10:40 -04:00

82 lines
2.4 KiB
Text

<%- # License: AGPL-3.0-or-later WITH Web-Template-Output-Additional-Permission-3.0-or-later -%>
<header class='pane-header'>
<h3>Organization Users</h3>
</header>
<div class='pane-inner'>
<table class='usersTable table table-striped'>
<thead>
<th>Name</th>
<th>Email</th>
<th>Role</th>
<th></th>
</thead>
<tbody>
<% is_admin = current_role?(:nonprofit_admin) %>
<% @nonprofit.roles.includes(user: :profile).each do |role| %>
<tr>
<td><%= role.user.profile.name %></td>
<td class='u-ellipses'><%= role.user.email %></td>
<td><%= role.name.to_s.titleize.split(' ').last %></td>
<td>
<% if is_admin %>
<form autosubmit
action='<%= nonprofit_role_path(@nonprofit, role.id, format: :json) %>'
method='delete'
data-reload data-confirm>
<input type='hidden' name='required_input'>
<button
type='submit'
class='button--tiny red'
data-loading='Removing...'>
<i class='fa fa-times'></i> Remove
</button>
</form>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>
<% if current_role?([:nonprofit_admin,:super_admin]) %>
<a class='button u-marginTop--5' open-modal='newRole'><i class='fa fa-plus'></i> New User</a>
<% end %>
<hr>
<div>
<a open-modal='roleInfoModal'>
What's the difference between an Associate and an Admin?
</a>
</div>
</div>
<div class='modal' id='roleInfoModal'>
<%= render 'common/modal_header', title: "What's the difference between an Associate and an Admin?" %>
<div class='modal-body'>
<p class='strong'>Associates can:</p>
<ul class='hasBullets'>
<li>Change timezone, branding, receipts</li>
<li>View payouts, pricing plan, and other users/roles (but cannot change/create any of these)</li>
<li>Can view payment histories and supporter records</li>
<li>Can edit and create supporter records</li>
<li>Can edit donation designation/dedications</li>
<li>Can view payout reports (but cannot create new payouts)</li>
<li>Can create and edit campaigns</li>
<li>Can create and edit events</li>
<li>Can charge and create supporters on event attendee lists</li>
<li>Can create new donate buttons</li>
</ul>
<p class='strong'>Admins can do everything above, PLUS:</p>
<ul class='hasBullets'>
<li>Change pricing plan
<li>Add/remove users</li>
<li>Initiate payouts</li>
<li>Change bank accounts</li>
</div>
</div>