Skip to content

Commit

Permalink
Remove anthroposophy from category list
Browse files Browse the repository at this point in the history
  • Loading branch information
ngiger committed Sep 16, 2015
1 parent 921a20f commit 13b5ed2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 12 deletions.
10 changes: 0 additions & 10 deletions src/util/resultsort.rb
Expand Up @@ -51,16 +51,6 @@ def sort_result(packages, session)
package.comparable_size,
]
}
if false # only for debug purposes
id = 0
packages.each{
|package|
id += 1
classify_package(package, session)
gal_name = package.galenic_forms.collect { |gf| galform_str(gf, session) }
puts "id #{sprintf('%3d', id)}: #{package.barcode} expired? #{package.expired?.inspect[0..2]} out_of_trade #{package.out_of_trade.inspect[0..2]} priorize #{@priorize_desitin.to_s[0..3]} #{@priority} (#{package.generic_type.inspect[0..2]}/#{package.sl_generic_type.inspect[0..2]}) '#{package.name_base.to_s}' gal_name #{gal_name} name #{@name_to_use.inspect}"
}
end
packages
rescue StandardError => e
puts e.class
Expand Down
4 changes: 3 additions & 1 deletion src/view/additional_information.rb
Expand Up @@ -262,7 +262,9 @@ def ikscat(model, session=@session)
catstr = @lookandfeel.lookup(:lppv)
text_elements.push(catstr)
end
if(gt = model.sl_generic_type)
# keep it sync with src/view/ajax/swissmedic_cat.rb!
# possible values are [nil, :generic, :original, :phytotherapy, :anthroposophy, :vaccine]
if (gt = model.sl_generic_type) and [:generic, :original].index(gt)
text_elements.push(@lookandfeel.lookup("sl_#{gt}_short"))
end
txt.value = text_elements.join(' / ')
Expand Down
4 changes: 3 additions & 1 deletion src/view/ajax/swissmedic_cat.rb
Expand Up @@ -43,7 +43,9 @@ def reorganize_components
end
y += 1
end
if(gt = @model.sl_generic_type)
# keep it sync with src/view/additional_information.rb:!
# possible values are [nil, :generic, :original, :phytotherapy, :anthroposophy, :vaccine]
if(gt = @model.sl_generic_type and [:generic, :original].index(gt))
@components.store([0,y], "sl_#{gt}_short")
@components.store([1,y], "sl_#{gt}")
y += 1
Expand Down

0 comments on commit 13b5ed2

Please sign in to comment.