asana 3.0.2 → 3.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/.github/workflows/publish.yaml +78 -38
  2. package/.swagger-codegen/VERSION +1 -1
  3. package/README.md +140 -29
  4. package/codegen/templates/README.mustache +129 -26
  5. package/codegen/templates/api.mustache +17 -15
  6. package/dist/ApiClient.js +6 -7
  7. package/dist/api/AllocationsApi.js +307 -0
  8. package/dist/api/AttachmentsApi.js +22 -95
  9. package/dist/api/AuditLogAPIApi.js +10 -14
  10. package/dist/api/BatchAPIApi.js +10 -14
  11. package/dist/api/CustomFieldSettingsApi.js +16 -23
  12. package/dist/api/CustomFieldsApi.js +38 -203
  13. package/dist/api/EventsApi.js +12 -16
  14. package/dist/api/GoalRelationshipsApi.js +26 -122
  15. package/dist/api/GoalsApi.js +48 -239
  16. package/dist/api/JobsApi.js +8 -32
  17. package/dist/api/MembershipsApi.js +73 -99
  18. package/dist/api/OrganizationExportsApi.js +12 -59
  19. package/dist/api/PortfolioMembershipsApi.js +20 -50
  20. package/dist/api/PortfoliosApi.js +56 -293
  21. package/dist/api/ProjectBriefsApi.js +20 -113
  22. package/dist/api/ProjectMembershipsApi.js +14 -41
  23. package/dist/api/ProjectStatusesApi.js +22 -95
  24. package/dist/api/ProjectTemplatesApi.js +28 -104
  25. package/dist/api/ProjectsApi.js +88 -446
  26. package/dist/api/RulesApi.js +8 -32
  27. package/dist/api/SectionsApi.js +34 -176
  28. package/dist/api/StatusUpdatesApi.js +22 -95
  29. package/dist/api/StoriesApi.js +26 -122
  30. package/dist/api/TagsApi.js +42 -167
  31. package/dist/api/TaskTemplatesApi.js +63 -72
  32. package/dist/api/TasksApi.js +173 -544
  33. package/dist/api/TeamMembershipsApi.js +26 -59
  34. package/dist/api/TeamsApi.js +36 -158
  35. package/dist/api/TimePeriodsApi.js +14 -41
  36. package/dist/api/TimeTrackingEntriesApi.js +26 -122
  37. package/dist/api/TypeaheadApi.js +12 -16
  38. package/dist/api/UserTaskListsApi.js +12 -59
  39. package/dist/api/UsersApi.js +32 -68
  40. package/dist/api/WebhooksApi.js +26 -122
  41. package/dist/api/WorkspaceMembershipsApi.js +20 -50
  42. package/dist/api/WorkspacesApi.js +26 -122
  43. package/dist/index.js +7 -0
  44. package/package.json +1 -1
  45. package/src/ApiClient.js +4 -4
  46. package/src/api/AllocationsApi.js +365 -0
  47. package/src/api/AttachmentsApi.js +42 -134
  48. package/src/api/AuditLogAPIApi.js +15 -17
  49. package/src/api/BatchAPIApi.js +15 -17
  50. package/src/api/CustomFieldSettingsApi.js +28 -32
  51. package/src/api/CustomFieldsApi.js +78 -290
  52. package/src/api/EventsApi.js +17 -19
  53. package/src/api/GoalRelationshipsApi.js +51 -173
  54. package/src/api/GoalsApi.js +100 -344
  55. package/src/api/JobsApi.js +11 -41
  56. package/src/api/MembershipsApi.js +105 -138
  57. package/src/api/OrganizationExportsApi.js +20 -80
  58. package/src/api/PortfolioMembershipsApi.js +37 -71
  59. package/src/api/PortfoliosApi.js +118 -422
  60. package/src/api/ProjectBriefsApi.js +38 -158
  61. package/src/api/ProjectMembershipsApi.js +24 -56
  62. package/src/api/ProjectStatusesApi.js +42 -134
  63. package/src/api/ProjectTemplatesApi.js +55 -149
  64. package/src/api/ProjectsApi.js +189 -647
  65. package/src/api/RulesApi.js +11 -41
  66. package/src/api/SectionsApi.js +69 -251
  67. package/src/api/StatusUpdatesApi.js +42 -134
  68. package/src/api/StoriesApi.js +51 -173
  69. package/src/api/TagsApi.js +86 -242
  70. package/src/api/TaskTemplatesApi.js +86 -95
  71. package/src/api/TasksApi.js +330 -799
  72. package/src/api/TeamMembershipsApi.js +50 -86
  73. package/src/api/TeamsApi.js +73 -227
  74. package/src/api/TimePeriodsApi.js +24 -56
  75. package/src/api/TimeTrackingEntriesApi.js +51 -173
  76. package/src/api/TypeaheadApi.js +17 -19
  77. package/src/api/UserTaskListsApi.js +20 -80
  78. package/src/api/UsersApi.js +63 -101
  79. package/src/api/WebhooksApi.js +51 -173
  80. package/src/api/WorkspaceMembershipsApi.js +37 -71
  81. package/src/api/WorkspacesApi.js +51 -173
  82. package/src/index.js +9 -2
@@ -7,7 +7,7 @@
7
7
  * NOTE: This class is auto generated by the swagger code generator program.
8
8
  * https://github.com/swagger-api/swagger-codegen.git
9
9
  *
10
- * Swagger Codegen version: 3.0.52
10
+ * Swagger Codegen version: 3.0.54
11
11
  *
12
12
  * Do not edit the class manually.
13
13
  *
@@ -18,7 +18,7 @@ var Collection = require('../utils/collection');
18
18
  /**
19
19
  * ProjectBriefs service.
20
20
  * @module api/ProjectBriefsApi
21
- * @version 3.0.2
21
+ * @version 3.0.4
22
22
  */
23
23
  export class ProjectBriefsApi {
24
24
 
@@ -76,36 +76,11 @@ export class ProjectBriefsApi {
76
76
  let accepts = ['application/json; charset=UTF-8'];
77
77
  let returnType = 'Blob';
78
78
 
79
- // Check if RETURN_COLLECTION is set and return a collection object if it is
80
- if (this.apiClient.RETURN_COLLECTION && false) {
81
- return Collection.fromApiClient(
82
- this.apiClient.callApi(
83
- '/projects/{project_gid}/project_briefs', 'POST',
84
- pathParams, queryParams, headerParams, formParams, postBody,
85
- authNames, contentTypes, accepts, returnType
86
- ),
87
- this.apiClient,
88
- {
89
- 'path': '/projects/{project_gid}/project_briefs',
90
- 'httpMethod': 'POST',
91
- 'pathParams': pathParams,
92
- 'queryParams': queryParams,
93
- 'headerParams': headerParams,
94
- 'formParams': formParams,
95
- 'bodyParam': postBody,
96
- 'authNames': authNames,
97
- 'contentTypes': contentTypes,
98
- 'accepts': accepts,
99
- 'returnType': returnType
100
- }
101
- )
102
- } else {
103
- return this.apiClient.callApi(
104
- '/projects/{project_gid}/project_briefs', 'POST',
105
- pathParams, queryParams, headerParams, formParams, postBody,
106
- authNames, contentTypes, accepts, returnType
107
- );
108
- }
79
+ return this.apiClient.callApi(
80
+ '/projects/{project_gid}/project_briefs', 'POST',
81
+ pathParams, queryParams, headerParams, formParams, postBody,
82
+ authNames, contentTypes, accepts, returnType
83
+ );
109
84
  }
110
85
 
111
86
  /**
@@ -119,15 +94,10 @@ export class ProjectBriefsApi {
119
94
  */
120
95
  createProjectBrief(body, project_gid, opts) {
121
96
 
122
- // Check if RETURN_COLLECTION is set and return a collection object if it is
123
- if (this.apiClient.RETURN_COLLECTION && false) {
124
- return this.createProjectBriefWithHttpInfo(body, project_gid, opts)
125
- } else {
126
- return this.createProjectBriefWithHttpInfo(body, project_gid, opts)
127
- .then(function(response_and_data) {
128
- return response_and_data.data;
129
- });
130
- }
97
+ return this.createProjectBriefWithHttpInfo(body, project_gid, opts)
98
+ .then(function(response_and_data) {
99
+ return response_and_data.data;
100
+ });
131
101
  }
132
102
 
133
103
 
@@ -162,36 +132,11 @@ export class ProjectBriefsApi {
162
132
  let accepts = ['application/json; charset=UTF-8'];
163
133
  let returnType = 'Blob';
164
134
 
165
- // Check if RETURN_COLLECTION is set and return a collection object if it is
166
- if (this.apiClient.RETURN_COLLECTION && false) {
167
- return Collection.fromApiClient(
168
- this.apiClient.callApi(
169
- '/project_briefs/{project_brief_gid}', 'DELETE',
170
- pathParams, queryParams, headerParams, formParams, postBody,
171
- authNames, contentTypes, accepts, returnType
172
- ),
173
- this.apiClient,
174
- {
175
- 'path': '/project_briefs/{project_brief_gid}',
176
- 'httpMethod': 'DELETE',
177
- 'pathParams': pathParams,
178
- 'queryParams': queryParams,
179
- 'headerParams': headerParams,
180
- 'formParams': formParams,
181
- 'bodyParam': postBody,
182
- 'authNames': authNames,
183
- 'contentTypes': contentTypes,
184
- 'accepts': accepts,
185
- 'returnType': returnType
186
- }
187
- )
188
- } else {
189
- return this.apiClient.callApi(
190
- '/project_briefs/{project_brief_gid}', 'DELETE',
191
- pathParams, queryParams, headerParams, formParams, postBody,
192
- authNames, contentTypes, accepts, returnType
193
- );
194
- }
135
+ return this.apiClient.callApi(
136
+ '/project_briefs/{project_brief_gid}', 'DELETE',
137
+ pathParams, queryParams, headerParams, formParams, postBody,
138
+ authNames, contentTypes, accepts, returnType
139
+ );
195
140
  }
196
141
 
197
142
  /**
@@ -202,15 +147,10 @@ export class ProjectBriefsApi {
202
147
  */
203
148
  deleteProjectBrief(project_brief_gid) {
204
149
 
205
- // Check if RETURN_COLLECTION is set and return a collection object if it is
206
- if (this.apiClient.RETURN_COLLECTION && false) {
207
- return this.deleteProjectBriefWithHttpInfo(project_brief_gid)
208
- } else {
209
- return this.deleteProjectBriefWithHttpInfo(project_brief_gid)
210
- .then(function(response_and_data) {
211
- return response_and_data.data;
212
- });
213
- }
150
+ return this.deleteProjectBriefWithHttpInfo(project_brief_gid)
151
+ .then(function(response_and_data) {
152
+ return response_and_data.data;
153
+ });
214
154
  }
215
155
 
216
156
 
@@ -249,36 +189,11 @@ export class ProjectBriefsApi {
249
189
  let accepts = ['application/json; charset=UTF-8'];
250
190
  let returnType = 'Blob';
251
191
 
252
- // Check if RETURN_COLLECTION is set and return a collection object if it is
253
- if (this.apiClient.RETURN_COLLECTION && false) {
254
- return Collection.fromApiClient(
255
- this.apiClient.callApi(
256
- '/project_briefs/{project_brief_gid}', 'GET',
257
- pathParams, queryParams, headerParams, formParams, postBody,
258
- authNames, contentTypes, accepts, returnType
259
- ),
260
- this.apiClient,
261
- {
262
- 'path': '/project_briefs/{project_brief_gid}',
263
- 'httpMethod': 'GET',
264
- 'pathParams': pathParams,
265
- 'queryParams': queryParams,
266
- 'headerParams': headerParams,
267
- 'formParams': formParams,
268
- 'bodyParam': postBody,
269
- 'authNames': authNames,
270
- 'contentTypes': contentTypes,
271
- 'accepts': accepts,
272
- 'returnType': returnType
273
- }
274
- )
275
- } else {
276
- return this.apiClient.callApi(
277
- '/project_briefs/{project_brief_gid}', 'GET',
278
- pathParams, queryParams, headerParams, formParams, postBody,
279
- authNames, contentTypes, accepts, returnType
280
- );
281
- }
192
+ return this.apiClient.callApi(
193
+ '/project_briefs/{project_brief_gid}', 'GET',
194
+ pathParams, queryParams, headerParams, formParams, postBody,
195
+ authNames, contentTypes, accepts, returnType
196
+ );
282
197
  }
283
198
 
284
199
  /**
@@ -291,15 +206,10 @@ export class ProjectBriefsApi {
291
206
  */
292
207
  getProjectBrief(project_brief_gid, opts) {
293
208
 
294
- // Check if RETURN_COLLECTION is set and return a collection object if it is
295
- if (this.apiClient.RETURN_COLLECTION && false) {
296
- return this.getProjectBriefWithHttpInfo(project_brief_gid, opts)
297
- } else {
298
- return this.getProjectBriefWithHttpInfo(project_brief_gid, opts)
299
- .then(function(response_and_data) {
300
- return response_and_data.data;
301
- });
302
- }
209
+ return this.getProjectBriefWithHttpInfo(project_brief_gid, opts)
210
+ .then(function(response_and_data) {
211
+ return response_and_data.data;
212
+ });
303
213
  }
304
214
 
305
215
 
@@ -343,36 +253,11 @@ export class ProjectBriefsApi {
343
253
  let accepts = ['application/json; charset=UTF-8'];
344
254
  let returnType = 'Blob';
345
255
 
346
- // Check if RETURN_COLLECTION is set and return a collection object if it is
347
- if (this.apiClient.RETURN_COLLECTION && false) {
348
- return Collection.fromApiClient(
349
- this.apiClient.callApi(
350
- '/project_briefs/{project_brief_gid}', 'PUT',
351
- pathParams, queryParams, headerParams, formParams, postBody,
352
- authNames, contentTypes, accepts, returnType
353
- ),
354
- this.apiClient,
355
- {
356
- 'path': '/project_briefs/{project_brief_gid}',
357
- 'httpMethod': 'PUT',
358
- 'pathParams': pathParams,
359
- 'queryParams': queryParams,
360
- 'headerParams': headerParams,
361
- 'formParams': formParams,
362
- 'bodyParam': postBody,
363
- 'authNames': authNames,
364
- 'contentTypes': contentTypes,
365
- 'accepts': accepts,
366
- 'returnType': returnType
367
- }
368
- )
369
- } else {
370
- return this.apiClient.callApi(
371
- '/project_briefs/{project_brief_gid}', 'PUT',
372
- pathParams, queryParams, headerParams, formParams, postBody,
373
- authNames, contentTypes, accepts, returnType
374
- );
375
- }
256
+ return this.apiClient.callApi(
257
+ '/project_briefs/{project_brief_gid}', 'PUT',
258
+ pathParams, queryParams, headerParams, formParams, postBody,
259
+ authNames, contentTypes, accepts, returnType
260
+ );
376
261
  }
377
262
 
378
263
  /**
@@ -386,15 +271,10 @@ export class ProjectBriefsApi {
386
271
  */
387
272
  updateProjectBrief(body, project_brief_gid, opts) {
388
273
 
389
- // Check if RETURN_COLLECTION is set and return a collection object if it is
390
- if (this.apiClient.RETURN_COLLECTION && false) {
391
- return this.updateProjectBriefWithHttpInfo(body, project_brief_gid, opts)
392
- } else {
393
- return this.updateProjectBriefWithHttpInfo(body, project_brief_gid, opts)
394
- .then(function(response_and_data) {
395
- return response_and_data.data;
396
- });
397
- }
274
+ return this.updateProjectBriefWithHttpInfo(body, project_brief_gid, opts)
275
+ .then(function(response_and_data) {
276
+ return response_and_data.data;
277
+ });
398
278
  }
399
279
 
400
280
  }
@@ -7,7 +7,7 @@
7
7
  * NOTE: This class is auto generated by the swagger code generator program.
8
8
  * https://github.com/swagger-api/swagger-codegen.git
9
9
  *
10
- * Swagger Codegen version: 3.0.52
10
+ * Swagger Codegen version: 3.0.54
11
11
  *
12
12
  * Do not edit the class manually.
13
13
  *
@@ -18,7 +18,7 @@ var Collection = require('../utils/collection');
18
18
  /**
19
19
  * ProjectMemberships service.
20
20
  * @module api/ProjectMembershipsApi
21
- * @version 3.0.2
21
+ * @version 3.0.4
22
22
  */
23
23
  export class ProjectMembershipsApi {
24
24
 
@@ -71,36 +71,11 @@ export class ProjectMembershipsApi {
71
71
  let accepts = ['application/json; charset=UTF-8'];
72
72
  let returnType = 'Blob';
73
73
 
74
- // Check if RETURN_COLLECTION is set and return a collection object if it is
75
- if (this.apiClient.RETURN_COLLECTION && false) {
76
- return Collection.fromApiClient(
77
- this.apiClient.callApi(
78
- '/project_memberships/{project_membership_gid}', 'GET',
79
- pathParams, queryParams, headerParams, formParams, postBody,
80
- authNames, contentTypes, accepts, returnType
81
- ),
82
- this.apiClient,
83
- {
84
- 'path': '/project_memberships/{project_membership_gid}',
85
- 'httpMethod': 'GET',
86
- 'pathParams': pathParams,
87
- 'queryParams': queryParams,
88
- 'headerParams': headerParams,
89
- 'formParams': formParams,
90
- 'bodyParam': postBody,
91
- 'authNames': authNames,
92
- 'contentTypes': contentTypes,
93
- 'accepts': accepts,
94
- 'returnType': returnType
95
- }
96
- )
97
- } else {
98
- return this.apiClient.callApi(
99
- '/project_memberships/{project_membership_gid}', 'GET',
100
- pathParams, queryParams, headerParams, formParams, postBody,
101
- authNames, contentTypes, accepts, returnType
102
- );
103
- }
74
+ return this.apiClient.callApi(
75
+ '/project_memberships/{project_membership_gid}', 'GET',
76
+ pathParams, queryParams, headerParams, formParams, postBody,
77
+ authNames, contentTypes, accepts, returnType
78
+ );
104
79
  }
105
80
 
106
81
  /**
@@ -113,15 +88,10 @@ export class ProjectMembershipsApi {
113
88
  */
114
89
  getProjectMembership(project_membership_gid, opts) {
115
90
 
116
- // Check if RETURN_COLLECTION is set and return a collection object if it is
117
- if (this.apiClient.RETURN_COLLECTION && false) {
118
- return this.getProjectMembershipWithHttpInfo(project_membership_gid, opts)
119
- } else {
120
- return this.getProjectMembershipWithHttpInfo(project_membership_gid, opts)
121
- .then(function(response_and_data) {
122
- return response_and_data.data;
123
- });
124
- }
91
+ return this.getProjectMembershipWithHttpInfo(project_membership_gid, opts)
92
+ .then(function(response_and_data) {
93
+ return response_and_data.data;
94
+ });
125
95
  }
126
96
 
127
97
 
@@ -162,9 +132,8 @@ export class ProjectMembershipsApi {
162
132
  let contentTypes = [];
163
133
  let accepts = ['application/json; charset=UTF-8'];
164
134
  let returnType = 'Blob';
165
-
166
135
  // Check if RETURN_COLLECTION is set and return a collection object if it is
167
- if (this.apiClient.RETURN_COLLECTION && true) {
136
+ if (this.apiClient.RETURN_COLLECTION) {
168
137
  return Collection.fromApiClient(
169
138
  this.apiClient.callApi(
170
139
  '/projects/{project_gid}/project_memberships', 'GET',
@@ -186,13 +155,13 @@ export class ProjectMembershipsApi {
186
155
  'returnType': returnType
187
156
  }
188
157
  )
189
- } else {
190
- return this.apiClient.callApi(
191
- '/projects/{project_gid}/project_memberships', 'GET',
192
- pathParams, queryParams, headerParams, formParams, postBody,
193
- authNames, contentTypes, accepts, returnType
194
- );
195
158
  }
159
+
160
+ return this.apiClient.callApi(
161
+ '/projects/{project_gid}/project_memberships', 'GET',
162
+ pathParams, queryParams, headerParams, formParams, postBody,
163
+ authNames, contentTypes, accepts, returnType
164
+ );
196
165
  }
197
166
 
198
167
  /**
@@ -207,16 +176,15 @@ export class ProjectMembershipsApi {
207
176
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ProjectMembershipCompactArray}
208
177
  */
209
178
  getProjectMembershipsForProject(project_gid, opts) {
210
-
211
179
  // Check if RETURN_COLLECTION is set and return a collection object if it is
212
- if (this.apiClient.RETURN_COLLECTION && true) {
213
- return this.getProjectMembershipsForProjectWithHttpInfo(project_gid, opts)
214
- } else {
180
+ if (this.apiClient.RETURN_COLLECTION) {
215
181
  return this.getProjectMembershipsForProjectWithHttpInfo(project_gid, opts)
216
- .then(function(response_and_data) {
217
- return response_and_data.data;
218
- });
219
182
  }
183
+
184
+ return this.getProjectMembershipsForProjectWithHttpInfo(project_gid, opts)
185
+ .then(function(response_and_data) {
186
+ return response_and_data.data;
187
+ });
220
188
  }
221
189
 
222
190
  }
@@ -7,7 +7,7 @@
7
7
  * NOTE: This class is auto generated by the swagger code generator program.
8
8
  * https://github.com/swagger-api/swagger-codegen.git
9
9
  *
10
- * Swagger Codegen version: 3.0.52
10
+ * Swagger Codegen version: 3.0.54
11
11
  *
12
12
  * Do not edit the class manually.
13
13
  *
@@ -18,7 +18,7 @@ var Collection = require('../utils/collection');
18
18
  /**
19
19
  * ProjectStatuses service.
20
20
  * @module api/ProjectStatusesApi
21
- * @version 3.0.2
21
+ * @version 3.0.4
22
22
  */
23
23
  export class ProjectStatusesApi {
24
24
 
@@ -76,36 +76,11 @@ export class ProjectStatusesApi {
76
76
  let accepts = ['application/json; charset=UTF-8'];
77
77
  let returnType = 'Blob';
78
78
 
79
- // Check if RETURN_COLLECTION is set and return a collection object if it is
80
- if (this.apiClient.RETURN_COLLECTION && false) {
81
- return Collection.fromApiClient(
82
- this.apiClient.callApi(
83
- '/projects/{project_gid}/project_statuses', 'POST',
84
- pathParams, queryParams, headerParams, formParams, postBody,
85
- authNames, contentTypes, accepts, returnType
86
- ),
87
- this.apiClient,
88
- {
89
- 'path': '/projects/{project_gid}/project_statuses',
90
- 'httpMethod': 'POST',
91
- 'pathParams': pathParams,
92
- 'queryParams': queryParams,
93
- 'headerParams': headerParams,
94
- 'formParams': formParams,
95
- 'bodyParam': postBody,
96
- 'authNames': authNames,
97
- 'contentTypes': contentTypes,
98
- 'accepts': accepts,
99
- 'returnType': returnType
100
- }
101
- )
102
- } else {
103
- return this.apiClient.callApi(
104
- '/projects/{project_gid}/project_statuses', 'POST',
105
- pathParams, queryParams, headerParams, formParams, postBody,
106
- authNames, contentTypes, accepts, returnType
107
- );
108
- }
79
+ return this.apiClient.callApi(
80
+ '/projects/{project_gid}/project_statuses', 'POST',
81
+ pathParams, queryParams, headerParams, formParams, postBody,
82
+ authNames, contentTypes, accepts, returnType
83
+ );
109
84
  }
110
85
 
111
86
  /**
@@ -119,15 +94,10 @@ export class ProjectStatusesApi {
119
94
  */
120
95
  createProjectStatusForProject(body, project_gid, opts) {
121
96
 
122
- // Check if RETURN_COLLECTION is set and return a collection object if it is
123
- if (this.apiClient.RETURN_COLLECTION && false) {
124
- return this.createProjectStatusForProjectWithHttpInfo(body, project_gid, opts)
125
- } else {
126
- return this.createProjectStatusForProjectWithHttpInfo(body, project_gid, opts)
127
- .then(function(response_and_data) {
128
- return response_and_data.data;
129
- });
130
- }
97
+ return this.createProjectStatusForProjectWithHttpInfo(body, project_gid, opts)
98
+ .then(function(response_and_data) {
99
+ return response_and_data.data;
100
+ });
131
101
  }
132
102
 
133
103
 
@@ -162,36 +132,11 @@ export class ProjectStatusesApi {
162
132
  let accepts = ['application/json; charset=UTF-8'];
163
133
  let returnType = 'Blob';
164
134
 
165
- // Check if RETURN_COLLECTION is set and return a collection object if it is
166
- if (this.apiClient.RETURN_COLLECTION && false) {
167
- return Collection.fromApiClient(
168
- this.apiClient.callApi(
169
- '/project_statuses/{project_status_gid}', 'DELETE',
170
- pathParams, queryParams, headerParams, formParams, postBody,
171
- authNames, contentTypes, accepts, returnType
172
- ),
173
- this.apiClient,
174
- {
175
- 'path': '/project_statuses/{project_status_gid}',
176
- 'httpMethod': 'DELETE',
177
- 'pathParams': pathParams,
178
- 'queryParams': queryParams,
179
- 'headerParams': headerParams,
180
- 'formParams': formParams,
181
- 'bodyParam': postBody,
182
- 'authNames': authNames,
183
- 'contentTypes': contentTypes,
184
- 'accepts': accepts,
185
- 'returnType': returnType
186
- }
187
- )
188
- } else {
189
- return this.apiClient.callApi(
190
- '/project_statuses/{project_status_gid}', 'DELETE',
191
- pathParams, queryParams, headerParams, formParams, postBody,
192
- authNames, contentTypes, accepts, returnType
193
- );
194
- }
135
+ return this.apiClient.callApi(
136
+ '/project_statuses/{project_status_gid}', 'DELETE',
137
+ pathParams, queryParams, headerParams, formParams, postBody,
138
+ authNames, contentTypes, accepts, returnType
139
+ );
195
140
  }
196
141
 
197
142
  /**
@@ -202,15 +147,10 @@ export class ProjectStatusesApi {
202
147
  */
203
148
  deleteProjectStatus(project_status_gid) {
204
149
 
205
- // Check if RETURN_COLLECTION is set and return a collection object if it is
206
- if (this.apiClient.RETURN_COLLECTION && false) {
207
- return this.deleteProjectStatusWithHttpInfo(project_status_gid)
208
- } else {
209
- return this.deleteProjectStatusWithHttpInfo(project_status_gid)
210
- .then(function(response_and_data) {
211
- return response_and_data.data;
212
- });
213
- }
150
+ return this.deleteProjectStatusWithHttpInfo(project_status_gid)
151
+ .then(function(response_and_data) {
152
+ return response_and_data.data;
153
+ });
214
154
  }
215
155
 
216
156
 
@@ -249,36 +189,11 @@ export class ProjectStatusesApi {
249
189
  let accepts = ['application/json; charset=UTF-8'];
250
190
  let returnType = 'Blob';
251
191
 
252
- // Check if RETURN_COLLECTION is set and return a collection object if it is
253
- if (this.apiClient.RETURN_COLLECTION && false) {
254
- return Collection.fromApiClient(
255
- this.apiClient.callApi(
256
- '/project_statuses/{project_status_gid}', 'GET',
257
- pathParams, queryParams, headerParams, formParams, postBody,
258
- authNames, contentTypes, accepts, returnType
259
- ),
260
- this.apiClient,
261
- {
262
- 'path': '/project_statuses/{project_status_gid}',
263
- 'httpMethod': 'GET',
264
- 'pathParams': pathParams,
265
- 'queryParams': queryParams,
266
- 'headerParams': headerParams,
267
- 'formParams': formParams,
268
- 'bodyParam': postBody,
269
- 'authNames': authNames,
270
- 'contentTypes': contentTypes,
271
- 'accepts': accepts,
272
- 'returnType': returnType
273
- }
274
- )
275
- } else {
276
- return this.apiClient.callApi(
277
- '/project_statuses/{project_status_gid}', 'GET',
278
- pathParams, queryParams, headerParams, formParams, postBody,
279
- authNames, contentTypes, accepts, returnType
280
- );
281
- }
192
+ return this.apiClient.callApi(
193
+ '/project_statuses/{project_status_gid}', 'GET',
194
+ pathParams, queryParams, headerParams, formParams, postBody,
195
+ authNames, contentTypes, accepts, returnType
196
+ );
282
197
  }
283
198
 
284
199
  /**
@@ -291,15 +206,10 @@ export class ProjectStatusesApi {
291
206
  */
292
207
  getProjectStatus(project_status_gid, opts) {
293
208
 
294
- // Check if RETURN_COLLECTION is set and return a collection object if it is
295
- if (this.apiClient.RETURN_COLLECTION && false) {
296
- return this.getProjectStatusWithHttpInfo(project_status_gid, opts)
297
- } else {
298
- return this.getProjectStatusWithHttpInfo(project_status_gid, opts)
299
- .then(function(response_and_data) {
300
- return response_and_data.data;
301
- });
302
- }
209
+ return this.getProjectStatusWithHttpInfo(project_status_gid, opts)
210
+ .then(function(response_and_data) {
211
+ return response_and_data.data;
212
+ });
303
213
  }
304
214
 
305
215
 
@@ -339,9 +249,8 @@ export class ProjectStatusesApi {
339
249
  let contentTypes = [];
340
250
  let accepts = ['application/json; charset=UTF-8'];
341
251
  let returnType = 'Blob';
342
-
343
252
  // Check if RETURN_COLLECTION is set and return a collection object if it is
344
- if (this.apiClient.RETURN_COLLECTION && true) {
253
+ if (this.apiClient.RETURN_COLLECTION) {
345
254
  return Collection.fromApiClient(
346
255
  this.apiClient.callApi(
347
256
  '/projects/{project_gid}/project_statuses', 'GET',
@@ -363,13 +272,13 @@ export class ProjectStatusesApi {
363
272
  'returnType': returnType
364
273
  }
365
274
  )
366
- } else {
367
- return this.apiClient.callApi(
368
- '/projects/{project_gid}/project_statuses', 'GET',
369
- pathParams, queryParams, headerParams, formParams, postBody,
370
- authNames, contentTypes, accepts, returnType
371
- );
372
275
  }
276
+
277
+ return this.apiClient.callApi(
278
+ '/projects/{project_gid}/project_statuses', 'GET',
279
+ pathParams, queryParams, headerParams, formParams, postBody,
280
+ authNames, contentTypes, accepts, returnType
281
+ );
373
282
  }
374
283
 
375
284
  /**
@@ -383,16 +292,15 @@ export class ProjectStatusesApi {
383
292
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ProjectStatusResponseArray}
384
293
  */
385
294
  getProjectStatusesForProject(project_gid, opts) {
386
-
387
295
  // Check if RETURN_COLLECTION is set and return a collection object if it is
388
- if (this.apiClient.RETURN_COLLECTION && true) {
296
+ if (this.apiClient.RETURN_COLLECTION) {
389
297
  return this.getProjectStatusesForProjectWithHttpInfo(project_gid, opts)
390
- } else {
391
- return this.getProjectStatusesForProjectWithHttpInfo(project_gid, opts)
392
- .then(function(response_and_data) {
393
- return response_and_data.data;
394
- });
395
298
  }
299
+
300
+ return this.getProjectStatusesForProjectWithHttpInfo(project_gid, opts)
301
+ .then(function(response_and_data) {
302
+ return response_and_data.data;
303
+ });
396
304
  }
397
305
 
398
306
  }