Class: TripletexRubyClient::TimesheetweekApi
- Inherits:
-
Object
- Object
- TripletexRubyClient::TimesheetweekApi
- Defined in:
- lib/tripletex_ruby_client/api/timesheetweek_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#approve(opts = {}) ⇒ ResponseWrapperWeek
Approve week.
-
#approve_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Approve week.
-
#complete(opts = {}) ⇒ ResponseWrapperWeek
Complete week.
-
#complete_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Complete week.
-
#initialize(api_client = ApiClient.default) ⇒ TimesheetweekApi
constructor
A new instance of TimesheetweekApi.
-
#reopen(opts = {}) ⇒ ResponseWrapperWeek
Reopen week.
-
#reopen_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Reopen week.
-
#search(opts = {}) ⇒ ListResponseWeek
Find weekly status By ID, week/year combination, employeeId.
-
#search_with_http_info(opts = {}) ⇒ Array<(ListResponseWeek, Fixnum, Hash)>
Find weekly status By ID, week/year combination, employeeId.
-
#unapprove(opts = {}) ⇒ ResponseWrapperWeek
Unapprove week.
-
#unapprove_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Unapprove week.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ TimesheetweekApi
Returns a new instance of TimesheetweekApi.
19 20 21 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#approve(opts = {}) ⇒ ResponseWrapperWeek
Approve week. By ID or (ISO-8601 week and employeeId combination).
29 30 31 32 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 29 def approve(opts = {}) data, _status_code, _headers = approve_with_http_info(opts) data end |
#approve_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Approve week. By ID or (ISO-8601 week and employeeId combination).
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 41 def approve_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TimesheetweekApi.approve ...' end # resource path local_var_path = '/timesheet/week/:approve' # query parameters query_params = {} query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil? query_params[:'employeeId'] = opts[:'employee_id'] if !opts[:'employee_id'].nil? query_params[:'weekYear'] = opts[:'week_year'] if !opts[:'week_year'].nil? # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['tokenAuthScheme'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ResponseWrapperWeek') if @api_client.config.debugging @api_client.config.logger.debug "API called: TimesheetweekApi#approve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#complete(opts = {}) ⇒ ResponseWrapperWeek
Complete week. By ID or (ISO-8601 week and employeeId combination).
82 83 84 85 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 82 def complete(opts = {}) data, _status_code, _headers = complete_with_http_info(opts) data end |
#complete_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Complete week. By ID or (ISO-8601 week and employeeId combination).
94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 94 def complete_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TimesheetweekApi.complete ...' end # resource path local_var_path = '/timesheet/week/:complete' # query parameters query_params = {} query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil? query_params[:'employeeId'] = opts[:'employee_id'] if !opts[:'employee_id'].nil? query_params[:'weekYear'] = opts[:'week_year'] if !opts[:'week_year'].nil? # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['tokenAuthScheme'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ResponseWrapperWeek') if @api_client.config.debugging @api_client.config.logger.debug "API called: TimesheetweekApi#complete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#reopen(opts = {}) ⇒ ResponseWrapperWeek
Reopen week. By ID or (ISO-8601 week and employeeId combination).
135 136 137 138 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 135 def reopen(opts = {}) data, _status_code, _headers = reopen_with_http_info(opts) data end |
#reopen_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Reopen week. By ID or (ISO-8601 week and employeeId combination).
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 147 def reopen_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TimesheetweekApi.reopen ...' end # resource path local_var_path = '/timesheet/week/:reopen' # query parameters query_params = {} query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil? query_params[:'employeeId'] = opts[:'employee_id'] if !opts[:'employee_id'].nil? query_params[:'weekYear'] = opts[:'week_year'] if !opts[:'week_year'].nil? # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['tokenAuthScheme'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ResponseWrapperWeek') if @api_client.config.debugging @api_client.config.logger.debug "API called: TimesheetweekApi#reopen\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search(opts = {}) ⇒ ListResponseWeek
Find weekly status By ID, week/year combination, employeeId. or an approver
193 194 195 196 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 193 def search(opts = {}) data, _status_code, _headers = search_with_http_info(opts) data end |
#search_with_http_info(opts = {}) ⇒ Array<(ListResponseWeek, Fixnum, Hash)>
Find weekly status By ID, week/year combination, employeeId. or an approver
210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 210 def search_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TimesheetweekApi.search ...' end # resource path local_var_path = '/timesheet/week' # query parameters query_params = {} query_params[:'ids'] = opts[:'ids'] if !opts[:'ids'].nil? query_params[:'employeeIds'] = opts[:'employee_ids'] if !opts[:'employee_ids'].nil? query_params[:'weekYear'] = opts[:'week_year'] if !opts[:'week_year'].nil? query_params[:'approvedBy'] = opts[:'approved_by'] if !opts[:'approved_by'].nil? query_params[:'from'] = opts[:'from'] if !opts[:'from'].nil? query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil? query_params[:'sorting'] = opts[:'sorting'] if !opts[:'sorting'].nil? query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil? # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['tokenAuthScheme'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ListResponseWeek') if @api_client.config.debugging @api_client.config.logger.debug "API called: TimesheetweekApi#search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#unapprove(opts = {}) ⇒ ResponseWrapperWeek
Unapprove week. By ID or (ISO-8601 week and employeeId combination).
256 257 258 259 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 256 def unapprove(opts = {}) data, _status_code, _headers = unapprove_with_http_info(opts) data end |
#unapprove_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperWeek, Fixnum, Hash)>
Unapprove week. By ID or (ISO-8601 week and employeeId combination).
268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 |
# File 'lib/tripletex_ruby_client/api/timesheetweek_api.rb', line 268 def unapprove_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: TimesheetweekApi.unapprove ...' end # resource path local_var_path = '/timesheet/week/:unapprove' # query parameters query_params = {} query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil? query_params[:'employeeId'] = opts[:'employee_id'] if !opts[:'employee_id'].nil? query_params[:'weekYear'] = opts[:'week_year'] if !opts[:'week_year'].nil? # header parameters header_params = {} # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['tokenAuthScheme'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'ResponseWrapperWeek') if @api_client.config.debugging @api_client.config.logger.debug "API called: TimesheetweekApi#unapprove\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |