Class: ODDB::View::Drugs::SLPriceNews

Inherits:
RssPreview show all
Defined in:
src/view/drugs/centeredsearchform.rb

Constant Summary

COMPONENTS =
{
  [0,0] => :rss_image,
  [1,0] => :title,
}

Constants inherited from RssPreview

CSS_MAP

Instance Method Summary (collapse)

Methods inherited from RssPreview

#rss_image

Instance Method Details

- (Object) title(model)



258
259
260
261
262
263
264
265
266
267
268
269
270
# File 'src/view/drugs/centeredsearchform.rb', line 258

def title(model)
  title = "#{model}_feed_title"
  channel = "#{model}.rss"
  month, number = @session.rss_updates[channel]
  month ||= @@today
  link = HtmlGrid::Link.new(title, model, @session, self)
  link.href = @lookandfeel._event_url(:rss, :channel => channel)
  link.value = [ number.to_i, @lookandfeel.lookup(title), '<br>',
                 @lookandfeel.lookup("month_#{month.month}"),
                 month.year ].compact.join(' ')
  link.css_class = 'list bold'
  link
end