diff --git a/CHANGES.md b/CHANGES.md index 074e393..2fb5a16 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,12 @@ # Change Log +## Version 2.20190313.1 (2019-03-21) + +### Bug Fix: Connect v1 + +* Change `timecard_id` as path parameter for `ListTimecardEvents` endpoint +* Change `ended_at` to string type for `V1CashDrawerShift` type + ## Version 2.20190313.0 (2019-03-13) ## New API: Labor API diff --git a/docs/V1CashDrawerShift.md b/docs/V1CashDrawerShift.md index 7cefe00..102e20e 100644 --- a/docs/V1CashDrawerShift.md +++ b/docs/V1CashDrawerShift.md @@ -10,7 +10,7 @@ Name | Type | Description | Notes **id** | **String** | The shift's unique ID. | [optional] **event_type** | **String** | The shift's current state. See [V1CashDrawerShiftEventType](#type-v1cashdrawershifteventtype) for possible values | [optional] **opened_at** | **String** | The time when the shift began, in ISO 8601 format. | [optional] -**ended_at** | **Boolean** | The time when the shift ended, in ISO 8601 format. | [optional] +**ended_at** | **String** | The time when the shift ended, in ISO 8601 format. | [optional] **closed_at** | **String** | The time when the shift was closed, in ISO 8601 format. | [optional] **employee_ids** | **[String]** | The IDs of all employees that were logged into Square Register at some point during the cash drawer shift. | [optional] **opening_employee_id** | **String** | The ID of the employee that started the cash drawer shift. | [optional] diff --git a/docs/V1ListTimecardEventsRequest.md b/docs/V1ListTimecardEventsRequest.md index 8c575a2..e2a1e02 100644 --- a/docs/V1ListTimecardEventsRequest.md +++ b/docs/V1ListTimecardEventsRequest.md @@ -7,6 +7,5 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**timecard_id** | **String** | The ID of the timecard to list events for. | diff --git a/package.json b/package.json index 78ccc08..0323548 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "square-connect", - "version": "2.20190313.0", + "version": "2.20190313.1", "description": "JavaScript client library for the Square Connect v2 API", "keywords": [ "square", diff --git a/src/ApiClient.js b/src/ApiClient.js index 3a17884..419b157 100644 --- a/src/ApiClient.js +++ b/src/ApiClient.js @@ -16,7 +16,7 @@ var querystring = require('querystring'); /** * @module ApiClient - * @version 2.20190313.0 + * @version 2.20190313.1 */ /** @@ -48,7 +48,7 @@ var exports = function() { * @default {} */ this.defaultHeaders = { - 'User-Agent': 'Square-Connect-Javascript/2.20190313.0' + 'User-Agent': 'Square-Connect-Javascript/2.20190313.1' }; /** * The default HTTP timeout for all API calls. diff --git a/src/api/V1EmployeesApi.js b/src/api/V1EmployeesApi.js index eff2131..6b83166 100644 --- a/src/api/V1EmployeesApi.js +++ b/src/api/V1EmployeesApi.js @@ -457,9 +457,9 @@ module.exports = function(apiClient) { var pathParams = { + 'timecard_id': timecardId }; var queryParams = { - 'timecard_id': timecardId }; var headerParams = { }; diff --git a/src/index.js b/src/index.js index 067f6a1..14d27af 100644 --- a/src/index.js +++ b/src/index.js @@ -460,7 +460,7 @@ var V1TransactionsApi = require('./api/V1TransactionsApi'); * *

* @module index - * @version 2.20190313.0 + * @version 2.20190313.1 */ module.exports = { /** diff --git a/src/model/V1CashDrawerShift.js b/src/model/V1CashDrawerShift.js index c851f02..6e9b63e 100644 --- a/src/model/V1CashDrawerShift.js +++ b/src/model/V1CashDrawerShift.js @@ -75,7 +75,7 @@ exports.constructFromObject = function(data, obj) { obj['opened_at'] = ApiClient.convertToType(data['opened_at'], 'String'); } if (data.hasOwnProperty('ended_at')) { - obj['ended_at'] = ApiClient.convertToType(data['ended_at'], 'Boolean'); + obj['ended_at'] = ApiClient.convertToType(data['ended_at'], 'String'); } if (data.hasOwnProperty('closed_at')) { obj['closed_at'] = ApiClient.convertToType(data['closed_at'], 'String'); @@ -143,7 +143,7 @@ exports.prototype['event_type'] = undefined; exports.prototype['opened_at'] = undefined; /** * The time when the shift ended, in ISO 8601 format. - * @member {Boolean} ended_at + * @member {String} ended_at */ exports.prototype['ended_at'] = undefined; /** diff --git a/src/model/V1ListTimecardEventsRequest.js b/src/model/V1ListTimecardEventsRequest.js index 35cae49..c87ce52 100644 --- a/src/model/V1ListTimecardEventsRequest.js +++ b/src/model/V1ListTimecardEventsRequest.js @@ -26,12 +26,10 @@ var ApiClient = require('../ApiClient'); * * @alias module:model/V1ListTimecardEventsRequest * @class - * @param timecardId {String} The ID of the timecard to list events for. */ -var exports = function(timecardId) { +var exports = function() { var _this = this; - _this['timecard_id'] = timecardId; }; /** @@ -45,18 +43,10 @@ exports.constructFromObject = function(data, obj) { if (data) { obj = obj || new exports(); - if (data.hasOwnProperty('timecard_id')) { - obj['timecard_id'] = ApiClient.convertToType(data['timecard_id'], 'String'); - } } return obj; } -/** - * The ID of the timecard to list events for. - * @member {String} timecard_id - */ -exports.prototype['timecard_id'] = undefined;