Class: Renalware::Letters::Lists::Form::BatchPrintableLetters

Inherits:
AllLetters
  • Object
show all
Defined in:
app/models/renalware/letters/lists/form.rb

Instance Method Summary collapse

Methods inherited from AllLetters

#author_options, #letterhead_options, #page_count_options, #typist_options

Constructor Details

#initialize(params) ⇒ BatchPrintableLetters

Returns a new instance of BatchPrintableLetters.



72
73
74
75
76
77
# File 'app/models/renalware/letters/lists/form.rb', line 72

def initialize(params)
  super
  # These are the default values that must match the filters when the page is first
  # loaded, so the right results are displayed
  self.page_count_in_array ||= "[1,2]"
end

Instance Method Details

#allow_blank_inputsObject



87
88
89
# File 'app/models/renalware/letters/lists/form.rb', line 87

def allow_blank_inputs
  []
end

#disabled_inputsObject



83
84
85
# File 'app/models/renalware/letters/lists/form.rb', line 83

def disabled_inputs
  [:enclosures_present, :notes_present, :state_eq]
end

#enclosures_presentObject



91
92
93
# File 'app/models/renalware/letters/lists/form.rb', line 91

def enclosures_present
  false
end

#letter_state_optionsObject



79
80
81
# File 'app/models/renalware/letters/lists/form.rb', line 79

def letter_state_options
  super([:approved])
end

#notes_presentObject



95
96
97
# File 'app/models/renalware/letters/lists/form.rb', line 95

def notes_present
  false
end

#state_eqObject



99
100
101
# File 'app/models/renalware/letters/lists/form.rb', line 99

def state_eq
  @state_eq || :approved
end