Sha256: 83d731eb4188d513aa47cb92fb965894168b21f2b85d1d8002156f8ef7b7d403

Contents?: true

Size: 1.9 KB

Versions: 58

Compression:

Stored size: 1.9 KB

Contents

<div class="alert alert-info">
  <%= render 'directions' %>
</div>

<h1>
    <%= t('hyrax.contact_form.header') %>
</h1>

<% if user_signed_in? %>
  <% nm = current_user.name %>
  <% em = current_user.email %>
<% else %>
  <% nm = '' %>
  <% em = '' %>
<% end %>

<%= form_for @contact_form, url: hyrax.contact_form_index_path,
                            html: { class: 'form-horizontal' } do |f| %>
  <%= f.text_field :contact_method, class: 'hide' %>
  <div class="form-group">
    <%= f.label :category, t('hyrax.contact_form.type_label'), class: "col-sm-2 control-label" %>
    <% issue_types = Hyrax::ContactForm.issue_types_for_locale.dup %>
    <% issue_types.unshift([t('hyrax.contact_form.select_type'), nil]) %>
    <div class="col-sm-10">
      <%= f.select 'category', options_for_select(issue_types), {}, {class: 'form-control', required: true } %>
    </div>
  </div>

  <div class="form-group">
    <%= f.label :name, t('hyrax.contact_form.name_label'), class: "col-sm-2 control-label" %>
    <div class="col-sm-10"><%= f.text_field :name, value: nm, class: 'form-control', required: true %></div>
  </div>

  <div class="form-group">
    <%= f.label :email, t('hyrax.contact_form.email_label'), class: "col-sm-2 control-label" %>
    <div class="col-sm-10"><%= f.text_field :email, value: em, class: 'form-control', required: true %></div>
  </div>

  <div class="form-group">
    <%= f.label :subject, t('hyrax.contact_form.subject_label'), class: "col-sm-2 control-label" %>
    <div class="col-sm-10"><%= f.text_field :subject, class: 'form-control', required: true %></div>
  </div>

  <div class="form-group">
    <%= f.label :message, t('hyrax.contact_form.message_label'), class: "col-sm-2 control-label" %>
    <div class="col-sm-10"><%= f.text_area :message, rows: 4, class: 'form-control', required: true %></div>
  </div>

  <%= f.submit value: t('hyrax.contact_form.button_label'), class: "btn btn-primary" %>
<% end %>

Version data entries

58 entries across 58 versions & 2 rubygems

Version Path
hyrax-2.9.6 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.5 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.4 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.3 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.2 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.1 app/views/hyrax/contact_form/new.html.erb
hyrax-2.9.0 app/views/hyrax/contact_form/new.html.erb
hyrax-2.8.0 app/views/hyrax/contact_form/new.html.erb
hyrax-2.7.2 app/views/hyrax/contact_form/new.html.erb
hyrax-2.7.1 app/views/hyrax/contact_form/new.html.erb
hyrax-2.7.0 app/views/hyrax/contact_form/new.html.erb
hyrax-2.6.0 app/views/hyrax/contact_form/new.html.erb
hyrax-3.0.0.pre.rc1 app/views/hyrax/contact_form/new.html.erb
hyrax-3.0.0.pre.beta3 app/views/hyrax/contact_form/new.html.erb
hyrax-2.5.1 app/views/hyrax/contact_form/new.html.erb
hyrax-2.5.0 app/views/hyrax/contact_form/new.html.erb
hyrax-3.0.0.pre.beta2 app/views/hyrax/contact_form/new.html.erb
hyrax-2.4.1 app/views/hyrax/contact_form/new.html.erb
hyrax-3.0.0.pre.beta1 app/views/hyrax/contact_form/new.html.erb
hyrax-2.4.0 app/views/hyrax/contact_form/new.html.erb