Class: Pike13::API::V3::Desk::Pays
- Defined in:
- lib/pike13/api/v3/desk/pays.rb
Overview
Pays resource Details of staff member pay, pay rates, services, and hours
Constant Summary collapse
- DETAIL_FIELDS =
Available detail fields (when not grouping)
%w[ base_pay_amount business_id business_name business_subdomain currency_code final_pay_amount franchise_id key pay_description pay_id pay_period pay_period_end_date pay_period_start_date pay_recorded_at pay_reviewed_at pay_reviewed_by_id pay_reviewed_by_name pay_reviewed_date pay_state pay_type per_head_pay_amount revenue_category service_category service_date service_hours service_id service_location_name service_name service_type staff_home_location_name staff_id staff_name tiered_pay_amount ].freeze
- SUMMARY_FIELDS =
Available summary fields (when grouping)
%w[ business_id_summary business_subdomain_summary pay_count service_count total_base_pay_amount total_count total_final_pay_amount total_per_head_pay_amount total_service_hours total_tiered_pay_amount ].freeze
- GROUPINGS =
Available grouping fields
%w[ business_id business_name business_subdomain pay_period pay_reviewed_by_id pay_reviewed_by_name pay_reviewed_date pay_state pay_type revenue_category service_category service_date service_id service_location_name service_name service_type staff_home_location_name staff_id staff_name ].freeze
Class Method Summary collapse
-
.query(fields:, filter: nil, group: nil, sort: nil, page: nil, total_count: nil) ⇒ Hash
Execute a pays query.
Methods inherited from Base
Class Method Details
.query(fields:, filter: nil, group: nil, sort: nil, page: nil, total_count: nil) ⇒ Hash
Execute a pays query
39 40 41 42 43 44 45 46 47 48 |
# File 'lib/pike13/api/v3/desk/pays.rb', line 39 def query(fields:, filter: nil, group: nil, sort: nil, page: nil, total_count: nil) query_params = { fields: fields } query_params[:filter] = filter if filter query_params[:group] = group if group query_params[:sort] = sort if sort query_params[:page] = page if page query_params[:total_count] = total_count if total_count super("pays", query_params) end |