Class: RockBooks::ReceiptsReport
- Inherits:
-
Object
- Object
- RockBooks::ReceiptsReport
- Includes:
- TextReportHelper
- Defined in:
- lib/rock_books/reports/receipts_report.rb
Constant Summary
Constants included from TextReportHelper
TextReportHelper::SHORT_NAME_FORMAT_STRING, TextReportHelper::SHORT_NAME_MAX_LENGTH
Instance Attribute Summary collapse
-
#context ⇒ Object
readonly
Returns the value of attribute context.
-
#data ⇒ Object
readonly
Returns the value of attribute data.
Instance Method Summary collapse
- #generate ⇒ Object
-
#initialize(report_context, data) ⇒ ReceiptsReport
constructor
A new instance of ReceiptsReport.
Methods included from TextReportHelper
#account_code_format, #account_code_name_type_string, #account_code_name_type_string_for_code, #acct_name, #banner_line, #center, #end_date, #format_acct_amount, #format_multidoc_entry, #generation_info_display_string, #line_item_format_string, #max_account_code_length, #page_width, #section_heading, #start_date, #template_presentation_context, #total_with_ok_or_discrepancy
Constructor Details
#initialize(report_context, data) ⇒ ReceiptsReport
Returns a new instance of ReceiptsReport.
11 12 13 14 |
# File 'lib/rock_books/reports/receipts_report.rb', line 11 def initialize(report_context, data) @context = report_context @data = data end |
Instance Attribute Details
#context ⇒ Object (readonly)
Returns the value of attribute context.
9 10 11 |
# File 'lib/rock_books/reports/receipts_report.rb', line 9 def context @context end |
#data ⇒ Object (readonly)
Returns the value of attribute data.
9 10 11 |
# File 'lib/rock_books/reports/receipts_report.rb', line 9 def data @data end |
Instance Method Details
#generate ⇒ Object
17 18 19 |
# File 'lib/rock_books/reports/receipts_report.rb', line 17 def generate ErbHelper.render_hashes('text/receipts_report.txt.erb', data, template_presentation_context) end |