@saritasa/crm-delmar-core-sdk 0.1.68 → 0.1.69

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.
package/README.md CHANGED
@@ -1,5 +1,5 @@
1
- # @@saritasa/crm-delmar-core-sdk@0.1.68
1
+ # @@saritasa/crm-delmar-core-sdk@0.1.69
2
2
 
3
3
  ```bash
4
- npm install @saritasa/crm-delmar-core-sdk@0.1.68 --save
4
+ npm install @saritasa/crm-delmar-core-sdk@0.1.69 --save
5
5
  ```
@@ -4,10 +4,11 @@ import { PaginatedUserListDto } from "../model/paginated-user-list.dto";
4
4
  import { SimpleUserDto } from "../model/simple-user.dto";
5
5
  import { UserDailyTabularReportDto } from "../model/user-daily-tabular-report.dto";
6
6
  import { UserDto } from "../model/user.dto";
7
+ import { UserUtilizationReportDto } from "../model/user-utilization-report.dto";
7
8
  import { UtilizationChartPointDto } from "../model/utilization-chart-point.dto";
8
9
  import { Configuration } from "../configuration";
9
10
  import { BaseService } from "../api.base.service";
10
- import { UsersApiServiceInterface, UsersCreateRequestParams, UsersDailyTabularReportListRequestParams, UsersExpectedPeriodsApproversListRequestParams, UsersListRequestParams, UsersPartialUpdateRequestParams, UsersRetrieveRequestParams, UsersUpdateRequestParams, UsersUtilizationChartListRequestParams } from "./users-api.serviceInterface";
11
+ import { UsersApiServiceInterface, UsersCreateRequestParams, UsersDailyTabularReportListRequestParams, UsersExpectedPeriodsApproversListRequestParams, UsersListRequestParams, UsersPartialUpdateRequestParams, UsersRetrieveRequestParams, UsersUpdateRequestParams, UsersUtilizationChartListRequestParams, UsersUtilizationReportListRequestParams } from "./users-api.serviceInterface";
11
12
  import * as i0 from "@angular/core";
12
13
  export declare class UsersApiService extends BaseService implements UsersApiServiceInterface {
13
14
  protected httpClient: HttpClient;
@@ -180,6 +181,27 @@ export declare class UsersApiService extends BaseService implements UsersApiServ
180
181
  context?: HttpContext;
181
182
  transferCache?: boolean;
182
183
  }): Observable<HttpEvent<Array<UtilizationChartPointDto>>>;
184
+ /**
185
+ * Get utilization report for users.
186
+ * @param requestParameters
187
+ * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
188
+ * @param reportProgress flag to report request and response progress.
189
+ */
190
+ usersUtilizationReportList(requestParameters: UsersUtilizationReportListRequestParams, observe?: "body", reportProgress?: boolean, options?: {
191
+ httpHeaderAccept?: "application/json";
192
+ context?: HttpContext;
193
+ transferCache?: boolean;
194
+ }): Observable<Array<UserUtilizationReportDto>>;
195
+ usersUtilizationReportList(requestParameters: UsersUtilizationReportListRequestParams, observe?: "response", reportProgress?: boolean, options?: {
196
+ httpHeaderAccept?: "application/json";
197
+ context?: HttpContext;
198
+ transferCache?: boolean;
199
+ }): Observable<HttpResponse<Array<UserUtilizationReportDto>>>;
200
+ usersUtilizationReportList(requestParameters: UsersUtilizationReportListRequestParams, observe?: "events", reportProgress?: boolean, options?: {
201
+ httpHeaderAccept?: "application/json";
202
+ context?: HttpContext;
203
+ transferCache?: boolean;
204
+ }): Observable<HttpEvent<Array<UserUtilizationReportDto>>>;
183
205
  static ɵfac: i0.ɵɵFactoryDeclaration<UsersApiService, [null, { optional: true; }, { optional: true; }]>;
184
206
  static ɵprov: i0.ɵɵInjectableDeclaration<UsersApiService>;
185
207
  }
@@ -15,6 +15,7 @@ import { SimpleUserDto } from "../model/models";
15
15
  import { UserDailyTabularReportDto } from "../model/models";
16
16
  import { UserDto } from "../model/models";
17
17
  import { UserRequestDto } from "../model/models";
18
+ import { UserUtilizationReportDto } from "../model/models";
18
19
  import { UtilizationChartPointDto } from "../model/models";
19
20
  import { Configuration } from "../configuration";
20
21
  export interface UsersCreateRequestParams {
@@ -91,6 +92,16 @@ export interface UsersUtilizationChartListRequestParams {
91
92
  workType?: number;
92
93
  workTypeIn?: Array<number>;
93
94
  }
95
+ export interface UsersUtilizationReportListRequestParams {
96
+ period: string;
97
+ branch?: number;
98
+ branchIn?: Array<number>;
99
+ id?: number;
100
+ idIn?: Array<number>;
101
+ ordering?: string;
102
+ workType?: number;
103
+ workTypeIn?: Array<number>;
104
+ }
94
105
  export interface UsersApiServiceInterface {
95
106
  defaultHeaders: HttpHeaders;
96
107
  configuration: Configuration;
@@ -142,4 +153,10 @@ export interface UsersApiServiceInterface {
142
153
  * @param requestParameters
143
154
  */
144
155
  usersUtilizationChartList(requestParameters: UsersUtilizationChartListRequestParams, extraHttpRequestParams?: any): Observable<Array<UtilizationChartPointDto>>;
156
+ /**
157
+ *
158
+ * Get utilization report for users.
159
+ * @param requestParameters
160
+ */
161
+ usersUtilizationReportList(requestParameters: UsersUtilizationReportListRequestParams, extraHttpRequestParams?: any): Observable<Array<UserUtilizationReportDto>>;
145
162
  }
@@ -17277,6 +17277,69 @@ class UsersApiService extends BaseService {
17277
17277
  reportProgress: reportProgress,
17278
17278
  });
17279
17279
  }
17280
+ usersUtilizationReportList(requestParameters, observe = "body", reportProgress = false, options) {
17281
+ const period = requestParameters?.period;
17282
+ if (period === null || period === undefined) {
17283
+ throw new Error("Required parameter period was null or undefined when calling usersUtilizationReportList.");
17284
+ }
17285
+ const branch = requestParameters?.branch;
17286
+ const branchIn = requestParameters?.branchIn;
17287
+ const id = requestParameters?.id;
17288
+ const idIn = requestParameters?.idIn;
17289
+ const ordering = requestParameters?.ordering;
17290
+ const workType = requestParameters?.workType;
17291
+ const workTypeIn = requestParameters?.workTypeIn;
17292
+ let localVarQueryParameters = new HttpParams({ encoder: this.encoder });
17293
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, branch, "branch");
17294
+ if (branchIn) {
17295
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, [...branchIn].join(COLLECTION_FORMATS["csv"]), "branch__in");
17296
+ }
17297
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, id, "id");
17298
+ if (idIn) {
17299
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, [...idIn].join(COLLECTION_FORMATS["csv"]), "id__in");
17300
+ }
17301
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, ordering, "ordering");
17302
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, period, "period");
17303
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, workType, "work_type");
17304
+ if (workTypeIn) {
17305
+ localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, [...workTypeIn].join(COLLECTION_FORMATS["csv"]), "work_type__in");
17306
+ }
17307
+ let localVarHeaders = this.defaultHeaders;
17308
+ // authentication (cookieAuth) required
17309
+ // authentication (jwtAuth) required
17310
+ localVarHeaders = this.configuration.addCredentialToHeaders("jwtAuth", "Authorization", localVarHeaders, "Bearer ");
17311
+ const localVarHttpHeaderAcceptSelected = options?.httpHeaderAccept ??
17312
+ this.configuration.selectHeaderAccept(["application/json"]);
17313
+ if (localVarHttpHeaderAcceptSelected !== undefined) {
17314
+ localVarHeaders = localVarHeaders.set("Accept", localVarHttpHeaderAcceptSelected);
17315
+ }
17316
+ const localVarHttpContext = options?.context ?? new HttpContext();
17317
+ const localVarTransferCache = options?.transferCache ?? true;
17318
+ let responseType_ = "json";
17319
+ if (localVarHttpHeaderAcceptSelected) {
17320
+ if (localVarHttpHeaderAcceptSelected.startsWith("text")) {
17321
+ responseType_ = "text";
17322
+ }
17323
+ else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
17324
+ responseType_ = "json";
17325
+ }
17326
+ else {
17327
+ responseType_ = "blob";
17328
+ }
17329
+ }
17330
+ let localVarPath = `/api/v1/users/utilization-report/`;
17331
+ const { basePath, withCredentials } = this.configuration;
17332
+ return this.httpClient.request("get", `${basePath}${localVarPath}`, {
17333
+ context: localVarHttpContext,
17334
+ params: localVarQueryParameters,
17335
+ responseType: responseType_,
17336
+ ...(withCredentials ? { withCredentials } : {}),
17337
+ headers: localVarHeaders,
17338
+ observe: observe,
17339
+ transferCache: localVarTransferCache,
17340
+ reportProgress: reportProgress,
17341
+ });
17342
+ }
17280
17343
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: UsersApiService, deps: [{ token: i1.HttpClient }, { token: BASE_PATH, optional: true }, { token: Configuration, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
17281
17344
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: UsersApiService, providedIn: "root" });
17282
17345
  }