@experteam-mx/ngx-services 18.4.5 → 18.4.6

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.
@@ -1,9 +1,9 @@
1
1
  import { Environment } from '../ngx-services.models';
2
2
  import { HttpClient } from '@angular/common/http';
3
- import { AccountEntitiesActivesOut, CompanyCountriesOut, CompanyCountryOut, CompanyCountryTaxesOut, CountryReferenceCurrenciesOut, CountryReferenceOut, CountryReferencesOut, EmployeeOut, EmployeesOut, ExchangesOut, InstallationOut, InstallationsOut, LocationEmployeesOut, LocationOut, LocationsOut, ParametersIn, ParametersValuesOut, ParameterValueIn, ParameterValueOut, SupplyEntitiesActivesOut, WorkflowsOut } from './models/api-companies.types';
3
+ import { AccountEntitiesActivesOut, BoardingProcessIdIn, BoardingProcessIn, CompanyCountriesOut, CompanyCountryOut, CompanyCountryTaxesOut, CountryReferenceCurrenciesOut, CountryReferenceOut, CountryReferencesOut, EmployeeCustomersIn, EmployeeCustomersOut, EmployeeOut, EmployeesCustomersOut, EmployeesOut, ExchangesOut, InstallationOut, InstallationsOut, LocationEmployeesOut, LocationOut, LocationsOut, ParametersIn, ParametersValuesOut, ParameterValueIn, ParameterValueOut, SupplyEntitiesActivesOut, WorkflowsOut } from './models/api-companies.types';
4
4
  import { QueryParams } from './models/api.models';
5
5
  import { Observable } from 'rxjs';
6
- import { CountryCurrencyRate } from './models/api-companies.interfaces';
6
+ import { CountryCurrencyRate, EmployeeCustomerDhl } from './models/api-companies.interfaces';
7
7
  import * as i0 from "@angular/core";
8
8
  export declare class ApiCompaniesService {
9
9
  private environments;
@@ -165,6 +165,59 @@ export declare class ApiCompaniesService {
165
165
  * @return {Observable<WorkflowsOut>} An observable containing the workflow data.
166
166
  */
167
167
  getWorkflows(params: QueryParams): Observable<WorkflowsOut>;
168
+ /**
169
+ * Fetches the list of employee customer
170
+ *
171
+ * @param {QueryParams} params - The query parameters used to filter employee customers.
172
+ * @return {Observable<EmployeeCustomersOut>} An observable containing the employee customer data.
173
+ */
174
+ getEmployeesCustomers(params: QueryParams): Observable<EmployeesCustomersOut>;
175
+ /**
176
+ * Sends a POST request to create or update employee customer records and processes the server response.
177
+ *
178
+ * @param {EmployeeCustomersIn} body - The request payload containing employee customer data to be sent to the server.
179
+ * @return {Observable<EmployeeCustomersOut>} An observable that emits the updated employee customer data on successful response.
180
+ */
181
+ postEmployeeCustomers(body: EmployeeCustomersIn): Observable<EmployeeCustomersOut>;
182
+ /**
183
+ * Updates the employee-customer association record identified by the given ID with the provided data.
184
+ *
185
+ * @param {number} id - The identifier of the employee-customer record to update.
186
+ * @param {EmployeeCustomersIn} body - The data to update the employee-customer record with.
187
+ * @return {Observable<EmployeeCustomersOut>} An observable that emits the updated employee-customer data.
188
+ */
189
+ putEmployeeCustomers(id: number, body: EmployeeCustomersIn): Observable<EmployeeCustomersOut>;
190
+ /**
191
+ * Enables or disables an employee customer's active state.
192
+ *
193
+ * @param {EmployeeCustomerDhl} employee - The employee customer object to be updated.
194
+ * @param {boolean} [isActive] - Optional parameter to explicitly set the active state.
195
+ * If null or undefined, the active state will be toggled.
196
+ * @return {Observable<EmployeeCustomersOut>} An observable containing the updated employee customer output.
197
+ */
198
+ enableDisableEmployeeCustomers(employee: EmployeeCustomerDhl, isActive?: boolean): Observable<EmployeeCustomersOut>;
199
+ /**
200
+ * Submits a file containing employee customer data for a specific country to the server.
201
+ *
202
+ * @param {number} countryId - The identifier of the country for which the data is being uploaded.
203
+ * @param {File} file - The file containing employee customer data to be uploaded.
204
+ * @return {Observable<BoardingProcessIdIn>} Observable that emits the processed boarding process ID on success.
205
+ */
206
+ postEmployeeCustomersLoad(countryId: number, file: File): Observable<BoardingProcessIdIn>;
207
+ /**
208
+ * Downloads a file containing customer data for a specific employee based on the provided country ID.
209
+ *
210
+ * @param {number} id - The ID of the country used as a filter for fetching the employee's customers.
211
+ * @return {Observable<Blob>} An observable that emits the file blob containing the customer data.
212
+ */
213
+ getEmployeeCustomersDownload(id: number): Observable<Blob>;
214
+ /**
215
+ * Retrieves the boarding process details for a given ID.
216
+ *
217
+ * @param {number} id - The unique identifier of the boarding process to retrieve.
218
+ * @return {Observable<BoardingProcessIn>} An observable containing the boarding process details.
219
+ */
220
+ getBoardingProcess(id: number): Observable<BoardingProcessIn>;
168
221
  static ɵfac: i0.ɵɵFactoryDeclaration<ApiCompaniesService, never>;
169
222
  static ɵprov: i0.ɵɵInjectableDeclaration<ApiCompaniesService>;
170
223
  }
@@ -1,7 +1,7 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { Observable } from 'rxjs';
3
3
  import { Environment } from '../ngx-services.models';
4
- import { ManifestMultipleIn, ManifestMultipleOut, ShipmentCancellationIn, ShipmentCancellationOut, ValidateAccountIn, ValidateAccountOut } from './models/api-shipments.types';
4
+ import { ManifestMultipleIn, ManifestMultipleOut, ShipmentEmployeeCustomer, ShipmentCancellationIn, ShipmentCancellationOut, ValidateAccountIn, ValidateAccountOut } from './models/api-shipments.types';
5
5
  import * as i0 from "@angular/core";
6
6
  export declare class ApiShipmentsService {
7
7
  private environments;
@@ -28,6 +28,13 @@ export declare class ApiShipmentsService {
28
28
  * @returns An observable that emits the response data of type `ManifestMultipleOut`.
29
29
  */
30
30
  postManifestMultiple(body: ManifestMultipleIn): Observable<ManifestMultipleOut>;
31
+ /**
32
+ * Validates and obtains the number of shipments allowed by an employee customer
33
+ *
34
+ * @param {id} params - The id employee customer
35
+ * @return {Observable<ShipmentEmployeeCustomer>} An observable containing the shipments allowed by an employee
36
+ */
37
+ getEmployeeCustomer(id: number): Observable<ShipmentEmployeeCustomer>;
31
38
  /**
32
39
  * Cancels a specific shipment by providing its ID and a reason for cancellation.
33
40
  * Sends a PATCH request to update the shipment's cancellation status with the specified reason.
@@ -74,9 +74,18 @@ export interface IdentificationType extends SymfonyModel {
74
74
  countryId: number;
75
75
  identificationType: number | null;
76
76
  name: string;
77
+ viewSection?: {
78
+ [key: string]: boolean;
79
+ };
77
80
  }
78
81
  export interface OperationType extends SymfonyModel {
79
82
  code: string;
80
83
  name: string;
81
84
  translations?: Translations;
82
85
  }
86
+ export interface BoardingProcessStatus {
87
+ id: number;
88
+ code: string;
89
+ createdAt: string;
90
+ updatedAt: string;
91
+ }
@@ -1,5 +1,9 @@
1
- import { OperationType } from './api-catalog.interfaces';
1
+ import { IdentificationType, OperationType } from './api-catalog.interfaces';
2
2
  export interface OperationTypesOut {
3
3
  total: number;
4
4
  operationTypes: OperationType[];
5
5
  }
6
+ export interface IdentificationTypesOut {
7
+ total: number;
8
+ identificationTypes: IdentificationType[];
9
+ }
@@ -1,5 +1,5 @@
1
1
  import { LaravelModel } from './api.models';
2
- import { Currency, State } from './api-catalog.interfaces';
2
+ import { BoardingProcessStatus, Currency, IdentificationType, State } from './api-catalog.interfaces';
3
3
  export interface Account extends LaravelModel {
4
4
  number: string;
5
5
  description: string;
@@ -191,3 +191,37 @@ export interface Workflow {
191
191
  page: string;
192
192
  enabled: boolean;
193
193
  }
194
+ export interface EmployeeCustomerDhl extends LaravelModel {
195
+ identification_type_id: number;
196
+ identification_type_value: string;
197
+ name: string;
198
+ last_name: string;
199
+ address: string;
200
+ phone_code: string;
201
+ phone_number: string;
202
+ email: string;
203
+ register_date: string;
204
+ country_id: number;
205
+ employee_id: number | null;
206
+ identification_type: IdentificationType;
207
+ }
208
+ export interface BoardingProcess {
209
+ id: number;
210
+ boarding_process_type_id: number;
211
+ status_id: number;
212
+ is_finished: boolean;
213
+ start_date_time: string;
214
+ end_date_time: string;
215
+ created_at: string;
216
+ updated_at: string;
217
+ status: BoardingProcessStatus;
218
+ boarding_process_histories: BoardingProcessHistory[];
219
+ }
220
+ export interface BoardingProcessHistory {
221
+ id: number;
222
+ boarding_process_id: number;
223
+ status_id: number;
224
+ messages: string[];
225
+ created_at: string;
226
+ updated_at: string;
227
+ }
@@ -1,4 +1,4 @@
1
- import { Account, CompanyCountry, CompanyCountryTax, CountryExchange, CountryReference, CountryReferenceCurrency, Employee, Installation, Location, LocationEmployee, Parameter, SupplyEntity, Workflow } from './api-companies.interfaces';
1
+ import { Account, BoardingProcess, CompanyCountry, CompanyCountryTax, CountryExchange, CountryReference, CountryReferenceCurrency, Employee, EmployeeCustomerDhl, Installation, Location, LocationEmployee, Parameter, SupplyEntity, Workflow } from './api-companies.interfaces';
2
2
  export type LocationEmployeesOut = {
3
3
  location_employees: LocationEmployee[];
4
4
  total: number;
@@ -75,3 +75,31 @@ export type CountryReferenceOut = {
75
75
  export type WorkflowsOut = {
76
76
  workflow: Workflow[];
77
77
  };
78
+ export type EmployeesCustomersOut = {
79
+ employees_customer: EmployeeCustomerDhl[];
80
+ total: number;
81
+ };
82
+ export type EmployeeCustomersOut = {
83
+ employees_customer: EmployeeCustomerDhl;
84
+ };
85
+ export type EmployeeCustomersIn = {
86
+ identification_type_id: number;
87
+ identification_type_value: string;
88
+ name: string;
89
+ last_name: string;
90
+ address: string;
91
+ phone_code: string;
92
+ phone_number: string;
93
+ email: string;
94
+ register_date: string;
95
+ country_id: number;
96
+ employee_id: number | null;
97
+ is_active: boolean;
98
+ };
99
+ export type BoardingProcessIn = {
100
+ boarding_process: BoardingProcess;
101
+ };
102
+ export type BoardingProcessIdIn = {
103
+ boarding_process_id: number;
104
+ message: string;
105
+ };
@@ -71,6 +71,10 @@ export type ManifestMultipleOut = {
71
71
  };
72
72
  transactionId: string;
73
73
  };
74
+ export type ShipmentEmployeeCustomer = {
75
+ currentYear: number;
76
+ currentMonth: number;
77
+ };
74
78
  export type ShipmentCancellationIn = {
75
79
  shipmentId: number;
76
80
  reasonId: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@experteam-mx/ngx-services",
3
- "version": "18.4.5",
3
+ "version": "18.4.6",
4
4
  "description": "Angular common services for Experteam apps",
5
5
  "author": "Experteam Cía. Ltda.",
6
6
  "keywords": [