Class: GustoEmbedded::Models::Shared::PayrollCalculateAccruingTimeOffHoursRequest

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Includes:
Crystalline::MetadataFields
Defined in:
lib/gusto_embedded/models/shared/payroll_calculate_accruing_time_off_hours_request.rb

Overview

Request body for calculating accruing time off hours

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(regular_hours_worked: nil, overtime_hours_worked: nil, double_overtime_hours_worked: nil, pto_hours_used: nil, sick_hours_used: nil) ⇒ PayrollCalculateAccruingTimeOffHoursRequest

Returns a new instance of PayrollCalculateAccruingTimeOffHoursRequest.



27
28
29
30
31
32
33
# File 'lib/gusto_embedded/models/shared/payroll_calculate_accruing_time_off_hours_request.rb', line 27

def initialize(regular_hours_worked: nil, overtime_hours_worked: nil, double_overtime_hours_worked: nil, pto_hours_used: nil, sick_hours_used: nil)
  @regular_hours_worked = regular_hours_worked
  @overtime_hours_worked = overtime_hours_worked
  @double_overtime_hours_worked = double_overtime_hours_worked
  @pto_hours_used = pto_hours_used
  @sick_hours_used = sick_hours_used
end

Instance Method Details

#==(other) ⇒ Object



36
37
38
39
40
41
42
43
44
# File 'lib/gusto_embedded/models/shared/payroll_calculate_accruing_time_off_hours_request.rb', line 36

def ==(other)
  return false unless other.is_a? self.class
  return false unless @regular_hours_worked == other.regular_hours_worked
  return false unless @overtime_hours_worked == other.overtime_hours_worked
  return false unless @double_overtime_hours_worked == other.double_overtime_hours_worked
  return false unless @pto_hours_used == other.pto_hours_used
  return false unless @sick_hours_used == other.sick_hours_used
  true
end