Permalink
Browse files

Need to kick-in GoodsNomenclature inheritance.

  • Loading branch information...
1 parent e81b108 commit ae1866ed2d8e10275eca25b0589b6babd55f4b85 @saulius saulius committed Dec 4, 2012
Showing with 6 additions and 2 deletions.
  1. +3 −0 app/models/goods_nomenclature.rb
  2. +3 −2 lib/tasks/tariff.rake
@@ -160,3 +160,6 @@ def bti_url
end
end
+require 'heading'
+require 'chapter'
+require 'commodity'
View
@@ -22,8 +22,9 @@ namespace :tariff do
# Remove hidden goods nomenclatures
# TODO: is there a better solution?
- GoodsNomenclature.where(goods_nomenclature_item_id: HiddenGoodsNomenclature.codes).each do |gono|
- gono.class.tire.index.remove gono.goods_nomenclature_sid
+
+ GoodsNomenclature.where(goods_nomenclature_item_id: HiddenGoodsNomenclature.codes).all.each do |gono|
+ gono.class.tire.index.remove gono
end
end

0 comments on commit ae1866e

Please sign in to comment.