Skip to content

Commit

Permalink
Merge pull request spree#7435 from spark-solutions/remove-truncate-ht…
Browse files Browse the repository at this point in the history
…ml-gem

Removing truncate_html dependency
  • Loading branch information
priyank-gupta authored Jun 22, 2016
2 parents 4497ecc + 230f6d8 commit 62f97b8
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 23 deletions.
1 change: 0 additions & 1 deletion core/spree_core.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ Gem::Specification.new do |s|
s.add_dependency 'responders'
s.add_dependency 'state_machines-activerecord', '~> 0.2'
s.add_dependency 'stringex'
s.add_dependency 'truncate_html', '~> 0.9.3'
s.add_dependency 'twitter_cldr', '~> 3.0'
s.add_dependency 'sprockets-rails'

Expand Down
9 changes: 0 additions & 9 deletions frontend/app/helpers/spree/orders_helper.rb
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
require 'truncate_html'
require 'app/helpers/truncate_html_helper'

module Spree
module OrdersHelper
include TruncateHtmlHelper

def truncated_product_description(product)
truncate_html(raw(product.description))
end

def order_just_completed?(order)
flash[:order_completed] && order.present?
end
Expand Down
2 changes: 1 addition & 1 deletion frontend/app/views/spree/shared/_order_details.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
</td>
<td data-hook="order_item_description">
<h4><%= item.variant.product.name %></h4>
<%= truncated_product_description(item.variant.product) %>
<%= truncate(item.variant.product.description, length: 100) %>
<%= "(" + item.variant.options_text + ")" unless item.variant.option_values.empty? %>
</td>
<td data-hook="order_item_price" class="lead text-primary price"><span><%= item.single_money.to_html %></span></td>
Expand Down
12 changes: 0 additions & 12 deletions frontend/spec/helpers/order_helper_spec.rb

This file was deleted.

0 comments on commit 62f97b8

Please sign in to comment.