<commit_before><%= render partial: "organization_modal", locals: { organization: Organization.new, path: organizations_path, method: :post } %>

<% if current_user.can_create_organization? %>
  <div class="row">
    <div class="col-xs-6">
      <h4>Organizations</h4>
    </div>

  </div>
<% end %>

<div class="well">
  <div class="row">
    <div class="col-xs-6">
      <div class="input-group">
        <input type="text" class="form-control" placeholder="Search" />
      </div>
    </div>
    <div class="col-xs-6">
      <div class="pull-right">
        <button  data-toggle="modal" data-target="#modal" class="btn btn-primary">Add Organization</button>
      </div>
    </div>
  </div>
  <table class="table table-striped">
    <thead>
      <tr>
        <th>Name</th>
        <th>Mailing Address</th>
        <th>County</th>
        <th>Phone Number</th>
        <th>Email</th>
        <th></th>
      </tr>
    </thead>
    <tbody>
      <% current_user.organizations_with_admin_access.each do |organization| %>
        <tr>
          <td><%= organization.name %></td>
          <td><%= organization.address %></td>
          <td><%= organization.county %></td>
          <td><%= organization.phone_number %></td>
          <td><%= organization.email %></td>
          <td>
            <a data-toggle="modal" name="singlebutton" href="<%= edit_organization_path(organization) %>" class="btn btn-default btn-xs glyphicon glyphicon-pencil pull-right"></a>
          </td>
        </tr>
      <% end %>
    </tbody>
  </table>
</div>

<% current_user.organizations_with_admin_access.each do |organization| %>
  <%= render partial: "organization_modal", locals: { organization: organization, path: organization_path(organization), method: :put } %>
<% end %><commit_msg>Make organzations editable by click on row<commit_after><%= render partial: "organization_modal", locals: { organization: Organization.new, path: organizations_path, method: :post } %>

<% if current_user.can_create_organization? %>
  <div class="row">
    <div class="col-xs-6">
      <h4>Organizations</h4>
    </div>

  </div>
<% end %>

<div class="well">
  <div class="row">
    <div class="col-xs-6">
      <div class="input-group">
        <input type="text" class="form-control" placeholder="Search" />
      </div>
    </div>
    <div class="col-xs-6">
      <div class="pull-right">
        <button  data-toggle="modal" data-target="#modal" class="btn btn-primary">Add Organization</button>
      </div>
    </div>
  </div>
  <table class="table table-striped">
    <thead>
      <tr>
        <th>Name</th>
        <th>Mailing Address</th>
        <th>County</th>
        <th>Phone Number</th>
        <th>Email</th>
      </tr>
    </thead>
    <tbody>
      <% current_user.organizations_with_admin_access.each do |organization| %>
        <tr data-href="<%= edit_organization_path(organization) %>">
          <td><%= organization.name %></td>
          <td><%= organization.address %></td>
          <td><%= organization.county %></td>
          <td><%= organization.phone_number %></td>
          <td><%= organization.email %></td>
        </tr>
      <% end %>
    </tbody>
  </table>
</div>

<% current_user.organizations_with_admin_access.each do |organization| %>
  <%= render partial: "organization_modal", locals: { organization: organization, path: organization_path(organization), method: :put } %>
<% end %>
{'fraction_non_alphanumeric': 0.18672930123311804, 'fraction_numerical': 0.002935995302407516, 'mean_word_length': 2.8540723981900453, 'pattern_counts': {'":': 0, '<': 139, '<?xml version=': 0, '>': 139, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5201412', 'n_tokens_mistral': 1153, 'n_tokens_neox': 1082, 'n_words': 224}