Sha256: 64ca983d8503ab13857f0ab40040e7586b04f8456ebc8ff170c66ea4411b18b1

Contents?: true

Size: 1.33 KB

Versions: 8

Compression:

Stored size: 1.33 KB

Contents

<%= form_for @photo, :url => (@photo.new_record? ? spud_admin_photos_path : spud_admin_photo_path(@photo)), :html => {:id => 'spud_admin_photo_form', :target => 'spud_admin_photo_form_target', :class => 'form-horizontal'} do |f| %> 
  
  <%=error_messages_for(f.object)%>
  
  <fieldset>
    <legend>Photo Info</legend>  
      <div class="control-group">
        <%= f.label :title, :class => "control-label" %>
        <div class="controls">
          <%= f.text_field :title %>
        </div>
      </div>
      <div class="control-group">
        <%= f.label :caption, :class => "control-label" %>
        <div class="controls">
          <%= f.text_field :caption %>
        </div>
      </div>
  </fieldset>

  <fieldset>
    <legend>File Upload</legend>
      <div class="control-group">
        <%= f.label :photo, :class => "control-label" %>
        <div class="controls">
          <%= f.file_field :photo %>
        </div>
      </div>
      <% unless @photo.new_record? %>
        <div class="control-group">
          <label class="control-label">Current Photo</label>
          <div class="controls">
            <%= image_tag @photo.photo.url(:spud_admin_medium) %>
          </div>
        </div>
      <% end %>
  </fieldset>

  <iframe id="spud_admin_photo_form_target" name="spud_admin_photo_form_target" style="display:none;"></iframe>

<% end %>

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
spud_photos-0.9.4 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.3 app/views/spud/admin/photos/_form.html.erb
tb_photos-1.0 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.2 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.1 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.0.2 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.0.1 app/views/spud/admin/photos/_form.html.erb
spud_photos-0.9.0 app/views/spud/admin/photos/_form.html.erb