@@ -23,9 +23,9 @@ export default class {{{resourceClassName}}} extends BaseResource {
23
23
{{ /if }}
24
24
*/
25
25
{{{ name }}} (
26
- {{ #if urlPlaceholder }}
27
- {{{ urlPlaceholder. variableName}}} : string | SimpleSchemaTypes.{{{ urlPlaceholder. relType}}} ,
28
- {{ /if }}
26
+ {{ #each urlPlaceholders }}
27
+ {{{ variableName }}} : string | SimpleSchemaTypes.{{{ relType }}} ,
28
+ {{ /each }}
29
29
{{ #if requestBodyType }}
30
30
body{{ #if optionalRequestBody }} ?{{ /if }} : SimpleSchemaTypes.{{{ requestBodyType }}} ,
31
31
{{ /if }}
@@ -34,16 +34,16 @@ export default class {{{resourceClassName}}} extends BaseResource {
34
34
{{ /if }}
35
35
) {
36
36
return this.{{{ rawName }}} (
37
- {{ #if urlPlaceholder }}
38
- Utils.toId({{{ urlPlaceholder. variableName}}} ),
39
- {{ /if }}
37
+ {{ #each urlPlaceholders }}
38
+ Utils.toId({{{ variableName }}} ),
39
+ {{ /each }}
40
40
{{ #if requestBodyType }}
41
41
{{ #if optionalRequestBody }} body ? {{ /if }} Utils.serializeRequestBody<SchemaTypes .{{{ requestBodyType }}} >(
42
42
body,
43
43
{
44
- {{ #if urlPlaceholder.isEntityId }}
44
+ {{ #if entityIdPlaceholder }}
45
45
{{ #if requestStructure.idRequired }}
46
- id: Utils.toId({{{ urlPlaceholder .variableName}}} ),
46
+ id: Utils.toId({{{ entityIdPlaceholder .variableName}}} ),
47
47
{{ /if }}
48
48
{{ /if }}
49
49
type: {{{ stringify requestStructure.type }}} ,
@@ -79,9 +79,9 @@ export default class {{{resourceClassName}}} extends BaseResource {
79
79
{{ /if }}
80
80
*/
81
81
{{{ rawName }}} (
82
- {{ #if urlPlaceholder }}
83
- {{{ urlPlaceholder. variableName}}} : string,
84
- {{ /if }}
82
+ {{ #each urlPlaceholders }}
83
+ {{{ variableName }}} : string,
84
+ {{ /each }}
85
85
{{ #if requestBodyType }}
86
86
body{{ #if optionalRequestBody }} ?{{ /if }} : SchemaTypes.{{{ requestBodyType }}} ,
87
87
{{ /if }}
@@ -127,16 +127,16 @@ export default class {{{resourceClassName}}} extends BaseResource {
127
127
* @throws {TimeoutError}
128
128
*/
129
129
async *{{{ name }}} PagedIterator(
130
- {{ #if urlPlaceholder }}
131
- {{{ urlPlaceholder. variableName}}} : string | SimpleSchemaTypes.{{{ urlPlaceholder. relType}}} ,
132
- {{ /if }}
130
+ {{ #each urlPlaceholders }}
131
+ {{{ variableName }}} : string | SimpleSchemaTypes.{{{ relType }}} ,
132
+ {{ /each }}
133
133
queryParams{{ #unless queryParamsRequired }} ?{{ /unless }} : Utils.OmitFromKnownKeys<SimpleSchemaTypes .{{{ queryParamsType }}} , ' page' >,
134
134
iteratorOptions?: Utils.IteratorOptions,
135
135
) {
136
136
for await (const element of this.{{{ rawName }}} PagedIterator(
137
- {{ #if urlPlaceholder }}
138
- Utils.toId({{{ urlPlaceholder. variableName}}} ),
139
- {{ /if }}
137
+ {{ #each urlPlaceholders }}
138
+ Utils.toId({{{ variableName }}} ),
139
+ {{ /each }}
140
140
queryParams,
141
141
iteratorOptions,
142
142
)) {
@@ -158,9 +158,9 @@ export default class {{{resourceClassName}}} extends BaseResource {
158
158
* @throws {TimeoutError}
159
159
*/
160
160
{{{ rawName }}} PagedIterator(
161
- {{ #if urlPlaceholder }}
162
- {{{ urlPlaceholder. variableName}}} : string,
163
- {{ /if }}
161
+ {{ #each urlPlaceholders }}
162
+ {{{ variableName }}} : string,
163
+ {{ /each }}
164
164
queryParams{{ #unless queryParamsRequired }} ?{{ /unless }} : Utils.OmitFromKnownKeys<SchemaTypes .{{{ queryParamsType }}} , ' page' >,
165
165
iteratorOptions?: Utils.IteratorOptions,
166
166
) {
@@ -174,9 +174,9 @@ export default class {{{resourceClassName}}} extends BaseResource {
174
174
maxLimit: {{{ paginatedResponse.maxLimit }}} ,
175
175
},
176
176
(page: SchemaTypes.{{{ queryParamsType }}} ['page']) => this.{{{ rawName }}} (
177
- {{ #if urlPlaceholder }}
178
- {{{ urlPlaceholder. variableName}}} ,
179
- {{ /if }}
177
+ {{ #each urlPlaceholders }}
178
+ {{{ variableName }}} ,
179
+ {{ /each }}
180
180
{ ...queryParams, page },
181
181
),
182
182
iteratorOptions,
0 commit comments