<div class="table--add-record-modal hide">
  <div class="modal--container">
    <div class="modal--content-container">
      <div class="modal--header">
        <div class="row">
          <div class="col-sm-10">
            <h3>Add record</h3>
          </div>
          <div class="col-sm-2">
            <div class="modal--close-btn">
              <img src="/assets/images/icons/close.png">
            </div>
          </div>
        </div>
      </div>
      <div class="modal--content">

        <%= form_tag("/table/create_record", method: "post", remote: true) do %>
          <div class="add--record-panel panel panel-default show">
            <div class="panel-body row">
              <% @inputs.each do |input| %>
                <div class="row">
                  <div class="col-sm-5 table--add-record--field-label">
                    <p>
                      <%= label_tag input[:name], input[:name].humanize %>
                      <% if input[:required] == true %>
                        <span>*</span>
                      <% end %>
                    </p>
                  </div>
                  <div class="col-sm-7 table--add-record--field-input">
                    <div class="">
                      <%= add_record_field_input(input) %>
                    </div>
                  </div>
                </div>
              <% end %>
            </div>
          </div>
          <div class="row">
            <div class="col-sm-12">
              <p>
                <%= t('record.mandatory_field_indication') %>
              </p>
            </div>
          </div>
          <div class="row">
            <div class="col-sm-12">
              <div class="record--save-btn">
                <%= hidden_field_tag(:table, @current_table) %>
                <%= hidden_field_tag(:database_id, @database.id) %>
                <%= submit_tag('Save', class: 'btn btn-primary btn--save-record') %>
              </div>
            </div>
          </div>
        <% end %>

      </div>
    </div>
  </div>
</div>