Sha256: a2d3af3524e670d93d4adbfe75b5113002466dc3891cedbf1910830135feeb29

Contents?: true

Size: 1.15 KB

Versions: 14

Compression:

Stored size: 1.15 KB

Contents

<% if params[:drag_name].blank? %>
  <% my_file_name = File.basename(@avatar.logo.queued_for_write[:original].path.to_s) %>
<% else %>
  <% my_file_name = params[:drag_name].to_s %>
<% end %>

<% if Avatar.check_image_tmp_valid(my_file_name) %>
  <div class = "block">
    <div id="precropPrev" >
      <div class="form_row">
        <%= t('avatar.preview') %>
      </div>
      <div id="precropPrevImg" class="logo">
        <%= image_tag Avatar.image_tmp_path(my_file_name) ,:id=>"preview" %>
      </div>  
    </div>
    
    <div class="form_row">
      <%= t('avatar.original') %>
    </div>
    
    <div id="precropDiv" class = "block title content">
    	<%= image_tag Avatar.image_tmp_path(my_file_name) ,:id=>"cropImage" %>
    </div>
  </div>
  
  <%= form_for @avatar, :html => { :multipart => true } do |f| %>
  <div class= "block">
    <% for attribute in [:crop_x, :crop_y, :crop_w, :crop_h] %>
      <%= f.hidden_field attribute, :id => attribute %>
    <% end %>
  	<%= f.hidden_field :name, :value => my_file_name %>
  	  <div class="form_row center">
    <%= f.submit t('avatar.crop_submit'), :class => "button" %>
    </div>
    </div>
  <% end %>
<% end %>

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
avatars_for_rails-0.2.9 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.8 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.7 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.6 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.5 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.4 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.3 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.2 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.1 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.2.0 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.1.6 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.1.5 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.1.4 app/views/avatars/_precrop.html.erb
avatars_for_rails-0.1.3 app/views/avatars/_precrop.html.erb