Class: ODDB::View::Drugs::PatinfoInnerComposite

Inherits:
HtmlGrid::Composite show all
Defined in:
src/view/drugs/patinfo.rb

Direct Known Subclasses

Patinfo2001InnerComposite

Constant Summary

CHAPTERS =
[
  :galenic_form,
  :effects,
  :pupose,
  :amendments,
  :contra_indications,
  :precautions,
  :pregnancy,
  :usage,
  :unwanted_effects,
  :general_advice,
  :other_advice,
  :composition,
  :packages,
  :distribution,
  :fabrication,
  :date
]
COMPONENTS =
{}
DEFAULT_CLASS =
View::Chapter

Instance Method Summary (collapse)

Methods inherited from HtmlGrid::Composite

event_link, #hash_insert_col, #hash_insert_row

Instance Method Details

- (Object) init



34
35
36
37
38
39
40
41
42
43
44
# File 'src/view/drugs/patinfo.rb', line 34

def init
  yy = 0
  self::class::CHAPTERS.each { |name|
    if(@model.respond_to?(name) && \
      (chapter = @model.send(name)) && !chapter.empty?)
      components.store([0,yy], name)
      yy += 1
    end
  }
  super
end