only two tests need a fix. Starting to clear deprecation warnings.

This commit is contained in:
2013-05-24 15:48:54 +01:00
parent f3c13a7175
commit 868fddd7bc
6 changed files with 25 additions and 24 deletions
@@ -4,7 +4,7 @@ require_dependency 'spree/calculator'
module Spree
class Calculator::DigitalDelivery < Calculator::FlatRate
def self.description
I18n.t(:digital_delivery)
Spree.t(:digital_delivery)
end
def compute(object=nil)
@@ -1,5 +1,5 @@
<% if digital.attachment_file_name.present? %>
<%= digital.attachment_file_name %> (<%= number_to_human_size(digital.attachment_file_size) %>)
<% else %>
<%=t 'broken_file' %>
<%=Spree.t 'broken_file' %>
<% end %>
@@ -5,30 +5,30 @@
<legend><%= Spree::Variant.model_name.human %> "<%= variant.options_text %>"</legend>
<%= f.field_container :current_file do %>
<strong><%=t 'files' %>:</strong>
<strong><%=Spree.t 'files' %>:</strong>
<% if variant.digital? %>
<ul>
<% variant.digitals.each do |digital| %>
<li>
<%= render digital %>&nbsp;&nbsp;
<%= link_to t("delete_file"), admin_product_digital_url(@product, digital), :confirm => t('delete_file_cofirmation', :filename => digital.attachment_file_name), :method => :delete %>
<%= link_to Spree.t("delete_file"), admin_product_digital_url(@product, digital), :confirm => Spree.t('delete_file_cofirmation', :filename => digital.attachment_file_name), :method => :delete %>
</li>
<% end %>
</ul>
<% else %>
<%=t 'none' %>
<%=Spree.t 'none' %>
<% end %>
<% end %>
<p class="form-buttons">
<%= f.field_container :file do %>
<%= f.label :file, t("new_file") %> <span class="required">*</span><br/>
<%= f.label :file, Spree.t("new_file") %> <span class="required">*</span><br/>
<%= f.file_field :attachment %>
<% end %>
<%= hidden_field_tag 'digital[variant_id]', variant.id %>
<%= button t('spree_digital.upload') %>
<%= button Spree.t('spree_digital.upload') %>
</p>
</fieldset>
+1 -1
View File
@@ -1,5 +1,5 @@
<% if digital.attachment_file_name.present? %>
<%= digital.attachment_file_name %> (<%= number_to_human_size(digital.attachment_file_size) %>)
<% else %>
<%=t 'broken_file' %>
<%=Spree.t 'broken_file' %>
<% end %>