class PayrolleeCz::HoursWorkingConcept
Constants
- TAG_TIMESHEET_WORK
Attributes
hours[R]
Public Class Methods
new(tag_code, values)
click to toggle source
Calls superclass method
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 9 def initialize(tag_code, values) super(PayConceptGateway::REFCON_HOURS_WORKING, tag_code) init_values(values) end
Public Instance Methods
calc_category()
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 31 def calc_category PayrollConcept::CALC_CATEGORY_TIMES end
compute_result_value(timesheet_hours)
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 35 def compute_result_value(timesheet_hours) timesheet_hours + hours end
dup_with_value(code, values)
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 18 def dup_with_value(code, values) new_concept = self.dup new_concept.init_code(code) new_concept.init_values(values) return new_concept end
evaluate(period, tag_config, results)
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 39 def evaluate(period, tag_config, results) work_timesheet_hours = timesheet_hours_result(results, TAG_TIMESHEET_WORK) result_hours = compute_result_value(work_timesheet_hours) result_values = {hours: result_hours} TermHoursResult.new(@tag_code, @code, self, result_values) end
export_value_result()
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 59 def export_value_result "#{hours} hours" end
export_xml(xml_builder)
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 49 def export_xml(xml_builder) attributes = {} attributes[:hours] = @hours xml_builder.spec_value(xml_value, attributes) end
init_values(values)
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 14 def init_values(values) @hours = values[:hours] || 0 end
pending_codes()
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 25 def pending_codes [ TimesheetWorkTag.new ] end
xml_value()
click to toggle source
# File lib/payrollee_cz/concepts/hours_working_concept.rb, line 55 def xml_value "#{hours} hours" end