Initial commit

This commit is contained in:
Senad Uka
2020-05-31 22:38:19 +02:00
commit 858fafc3c5
1280 changed files with 65918 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
<tr>
<td style="width:3rem">
<%= image_or_text_avatar(account_manager) %>
</td>
<td><%= account_manager.email %></td>
<td><%= account_manager.full_name %></td>
<td><%= account_manager.role_for(Current.account).to_s.titleize %></td>
<td></td>
</tr>

View File

@@ -0,0 +1,3 @@
<%= bootstrap_form_with model: [project_membership.project, project_membership], html: { autocorrect: :off, autocapitalize: :none, autocomplete: :off, spellcheck: false } do |form| %>
<%= form.email_field :user_email, hide_label: true, append: form.button(fa_icon("paper-plane-o", text: t(".submit")), class: "btn btn-primary"), placeholder: true %>
<% end %>

View File

@@ -0,0 +1,13 @@
<tr>
<td style="width:3rem">
<%= image_or_text_avatar(project_membership.user) %>
</td>
<td><%= project_membership.user.email %></td>
<td><%= project_membership.user.full_name %></td>
<td><%= project_membership.user.role_for(Current.account).to_s.titleize %></td>
<td>
<% if policy(project_membership).destroy? && project_membership.user != Current.user %>
<%= link_to t(".actions.remove"), project_membership, method: :delete, data: { confirm: t(".confirm") }, class: "btn btn-light btn-sm border" %>
<% end %>
</td>
</tr>

View File

@@ -0,0 +1,33 @@
<div class="card shadow-sm">
<%= card_header text: t(".heading"), subtext: @project.client_name, close_action_path: [@project] %>
<div class="card-body p-3">
<% if policy(ProjectMembership).new? %>
<section class="py-2">
<h2 class="h6"><%= t(".invitation.heading") %></h2>
<%= render "form", project_membership: @project_membership %>
</section>
<% end %>
<section class="py-2">
<h2 class="h6"><%= t(".team_roster.heading", count: @project.members.size) %></h2>
<div class="pt-2 mx-n3">
<table class="table table-striped tr-px-4 align-all-middle">
<thead class="thead-light">
<tr>
<th></th>
<th>Email</th>
<th>Name</th>
<th>Role</th>
<th></th>
</tr>
</thead>
<tbody>
<%= render partial: "account_manager", collection: @account_managers %>
<%= render @project_memberships %>
</tbody>
</table>
</div>
</section>
</div>
</div>