@experteam-mx/ngx-services 18.6.0 → 18.6.2

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.
@@ -0,0 +1,47 @@
1
+ import { Environment } from '../ngx-services.models';
2
+ import { HttpClient } from '@angular/common/http';
3
+ import { QueryParams } from './models/api.models';
4
+ import { Observable } from 'rxjs';
5
+ import { BillingPaCustomerOut, DistrictsOut, ParishesOut, ProvincesOut } from './models/api-billing-pa.types';
6
+ import * as i0 from "@angular/core";
7
+ export declare class ApiBillingPaService {
8
+ private environments;
9
+ private http;
10
+ constructor(environments: Environment, http: HttpClient);
11
+ /**
12
+ * Retrieves the URL for the Billing Pa API from the environment configurations.
13
+ *
14
+ * @return {string} The URL of the Billing Pa API.
15
+ */
16
+ get url(): string;
17
+ /**
18
+ * Retrieves a list of districts based on query parameters.
19
+ *
20
+ * @param {QueryParams} params - Query parameters for filtering the districts.
21
+ * @returns {Observable<DistrictsOut>} The list of districts.
22
+ */
23
+ getDistricts(params: QueryParams): Observable<DistrictsOut>;
24
+ /**
25
+ * Retrieves a list of parishes based on query parameters.
26
+ *
27
+ * @param {QueryParams} params - Query parameters for filtering the parishes.
28
+ * @returns {Observable<ParishesOut>} The list of parishes.
29
+ */
30
+ getParishes(params: QueryParams): Observable<ParishesOut>;
31
+ /**
32
+ * Retrieves a list of provinces based on query parameters.
33
+ *
34
+ * @param {QueryParams} params - Query parameters for filtering the provinces.
35
+ * @returns {Observable<ProvincesOut>} The list of provinces.
36
+ */
37
+ getProvinces(params: QueryParams): Observable<ProvincesOut>;
38
+ /**
39
+ * Retrieves the details of a customer based on query parameters.
40
+ *
41
+ * @param {QueryParams} params - Query parameters for get customer.
42
+ * @return {Observable<BillingPaCustomerOut>} An observable that emits customer data.
43
+ */
44
+ getValidateCustomer(params: QueryParams): Observable<BillingPaCustomerOut>;
45
+ static ɵfac: i0.ɵɵFactoryDeclaration<ApiBillingPaService, never>;
46
+ static ɵprov: i0.ɵɵInjectableDeclaration<ApiBillingPaService>;
47
+ }
@@ -0,0 +1,27 @@
1
+ import { HttpClient } from '@angular/common/http';
2
+ import { Environment } from '../ngx-services.models';
3
+ import { Observable } from 'rxjs';
4
+ import { CookieService } from 'ngx-cookie-service';
5
+ import { ShipmentOut } from './models/api-composition.types';
6
+ import * as i0 from "@angular/core";
7
+ export declare class ApiCompositionService {
8
+ private environments;
9
+ private cookie;
10
+ private http;
11
+ constructor(environments: Environment, cookie: CookieService, http: HttpClient);
12
+ /**
13
+ * Retrieves the API security URL from the environment configuration.
14
+ *
15
+ * @return {string} The API security URL.
16
+ */
17
+ get url(): string;
18
+ /**
19
+ * Retrieves shipment details based on the provided shipment ID.
20
+ *
21
+ * @param {number} id - The unique identifier of the shipment to retrieve.
22
+ * @return {Observable<ShipmentOut>} An observable that emits the details of the shipment.
23
+ */
24
+ getShipment(id: number): Observable<ShipmentOut>;
25
+ static ɵfac: i0.ɵɵFactoryDeclaration<ApiCompositionService, never>;
26
+ static ɵprov: i0.ɵɵInjectableDeclaration<ApiCompositionService>;
27
+ }
@@ -0,0 +1,26 @@
1
+ import { LaravelModel } from './api.models';
2
+ export interface BillingPaCustomer {
3
+ document_id: number;
4
+ name: string;
5
+ number: string;
6
+ type_ruc: number;
7
+ type_ruc_code: string;
8
+ verification_code: string;
9
+ type_rec: string;
10
+ identification_type_id: number;
11
+ }
12
+ export interface District extends LaravelModel {
13
+ code: string;
14
+ name: string;
15
+ province_id: number;
16
+ }
17
+ export interface Parish extends LaravelModel {
18
+ code: string;
19
+ name: string;
20
+ district_id: number;
21
+ province_id: number;
22
+ }
23
+ export interface Province extends LaravelModel {
24
+ code: string;
25
+ name: string;
26
+ }
@@ -0,0 +1,16 @@
1
+ import { BillingPaCustomer, District, Parish, Province } from './api-billing-pa.interfaces';
2
+ export type DistrictsOut = {
3
+ total: number;
4
+ districts: District[];
5
+ };
6
+ export type BillingPaCustomerOut = {
7
+ customer: BillingPaCustomer;
8
+ };
9
+ export type ParishesOut = {
10
+ total: number;
11
+ parishes: Parish[];
12
+ };
13
+ export type ProvincesOut = {
14
+ total: number;
15
+ provinces: Province[];
16
+ };
@@ -184,6 +184,7 @@ export interface Location extends LaravelModel {
184
184
  [key: string]: string;
185
185
  };
186
186
  facility_id: number;
187
+ billing_code: string;
187
188
  accounts: Account[];
188
189
  company_country: CompanyCountry;
189
190
  state: State;
@@ -0,0 +1,289 @@
1
+ import { ActiveLessSymfonyModel, SymfonyModel } from './api.models';
2
+ import { CustomerType } from './api-shipments.enums';
3
+ export interface ShipmentComposition extends SymfonyModel {
4
+ currencyCode: string;
5
+ extraCharges: ExtraChargeComposition[];
6
+ globalProductCode: string;
7
+ globalProductName: string;
8
+ localProductCode: string;
9
+ localProductName: string;
10
+ trackingNumber: string;
11
+ contentDescription: string;
12
+ realWeight: number;
13
+ piecesNumber: number;
14
+ productSubtotal: number;
15
+ productTax: number;
16
+ productTotal: number;
17
+ declaredValue: number;
18
+ insuredValue: number;
19
+ accountNumber: string;
20
+ userId: number;
21
+ installationId: number;
22
+ companyCountryId: number;
23
+ productId: number;
24
+ countryReferenceCurrencyId: number;
25
+ commercialExchangeRate: number;
26
+ ibsExchangeRate: number;
27
+ shipmentStatusId: number;
28
+ shipmentAddresses: ShipmentAddresses[];
29
+ shipmentPieces: ShipmentPieces[];
30
+ shipmentCompanyCountryExtraCharges: ShipmentCompanyCountryExtraCharges[];
31
+ shipmentGsop: ShipmentGsop;
32
+ additionalData: AdditionalData;
33
+ transactionId: string;
34
+ requiresPayment: boolean;
35
+ originServiceAreaCode: string;
36
+ originFacilityCode: string;
37
+ destinationServiceAreaCode: string;
38
+ destinationFacilityCode: string;
39
+ productTaxes: string[];
40
+ isInspected: boolean;
41
+ extraFields: {
42
+ [key: string]: string | number | boolean;
43
+ };
44
+ shipmentContentTypeId: number;
45
+ commercialInvoice: CommercialInvoice;
46
+ shipmentScopeId: number;
47
+ shipmentGroupId: number;
48
+ product: string[];
49
+ declaredCurrency: string;
50
+ insuredCurrency: string;
51
+ deliveryDateTime: string;
52
+ date: string;
53
+ promotionCode: string;
54
+ priceOverrideApproverId: number;
55
+ priceOverrideReasonId: number;
56
+ customs: Customs;
57
+ exportReasonId: number;
58
+ exportReason: string[];
59
+ shipmentBookPickup: ShipmentBookPickup;
60
+ questionId: number;
61
+ isInsured: boolean;
62
+ itnNumber: string;
63
+ einNumber: string;
64
+ otherAccountNumber: string;
65
+ dutiesAndTaxesAccountNumber: string;
66
+ discountId: string;
67
+ discountReference: string;
68
+ totalPublishedValue: number;
69
+ totalPartnerAccountValue: number;
70
+ isMarketingConsent: boolean;
71
+ isTermCondition: boolean;
72
+ isDocument: boolean;
73
+ isCash: boolean;
74
+ isPriceOverride: boolean;
75
+ isProforma: boolean;
76
+ isPromotionCode: boolean;
77
+ isRetailRate: boolean;
78
+ isOtherOrigin: boolean;
79
+ isOccurs: boolean;
80
+ isDutiesAndTaxes: boolean;
81
+ }
82
+ export interface ExtraChargeComposition {
83
+ globalServiceCode: string;
84
+ localServiceCode: string;
85
+ globalServiceName: string;
86
+ localServiceName: string;
87
+ subtotal: number;
88
+ tax: number;
89
+ total: number;
90
+ taxes: Tax[];
91
+ }
92
+ export interface Tax {
93
+ code: string;
94
+ percent: number;
95
+ baseAmount: number;
96
+ amount: number;
97
+ }
98
+ export interface ShipmentAddresses extends SymfonyModel {
99
+ index: number;
100
+ identificationTypeId: number;
101
+ identificationNumber: string;
102
+ companyName: string;
103
+ fullName: string;
104
+ email: string;
105
+ phoneCode: string;
106
+ phoneNumber: string;
107
+ postalCode: string;
108
+ stateCode: string;
109
+ countyName: string;
110
+ cityName: string;
111
+ addressLine1: string;
112
+ addressLine2: string;
113
+ addressLine3: string;
114
+ countryId: number;
115
+ identificationType: IdentificationTypeComposition;
116
+ roleType: CustomerType;
117
+ }
118
+ export interface IdentificationTypeComposition extends SymfonyModel {
119
+ name: string;
120
+ companyCountryId: number;
121
+ }
122
+ export interface ShipmentPieces extends ActiveLessSymfonyModel {
123
+ number: number;
124
+ height: number;
125
+ length: number;
126
+ width: number;
127
+ realWeight: number;
128
+ volumetricWeight: number;
129
+ dataIdentifier: string;
130
+ trackingNumber: string;
131
+ licensePlateBarCode: string;
132
+ shipmentPieceCompanyCountrySupplies: ShipmentPieceCompanyCountrySupplies[];
133
+ }
134
+ export interface ShipmentPieceCompanyCountrySupplies extends ActiveLessSymfonyModel {
135
+ supplyId: number;
136
+ quantity: number;
137
+ subtotal: number;
138
+ taxBase: number;
139
+ taxPercent: number;
140
+ tax: number;
141
+ total: number;
142
+ description: string;
143
+ supply: Supply;
144
+ }
145
+ export interface Supply extends ActiveLessSymfonyModel {
146
+ name: string;
147
+ description: string;
148
+ countryId: number;
149
+ enabledForDropoff: boolean;
150
+ supplyType: SupplyTypeComposition;
151
+ supplyPacking: SupplyPackingComposition;
152
+ }
153
+ export interface SupplyTypeComposition extends SymfonyModel {
154
+ name: string;
155
+ }
156
+ export interface SupplyPackingComposition extends ActiveLessSymfonyModel {
157
+ value: number;
158
+ weight: number;
159
+ height: number;
160
+ depth: number;
161
+ width: number;
162
+ }
163
+ export interface CommercialInvoice extends ActiveLessSymfonyModel {
164
+ documentTypeId: number;
165
+ tradingTransactionTypeId: number;
166
+ documentFunctionId: number;
167
+ number: string;
168
+ remarks: string;
169
+ items: Item[];
170
+ documentType: DocumentType;
171
+ tradingTransactionType: TradingTransactionType;
172
+ documentFunction: DocumentFunction;
173
+ }
174
+ export interface Item extends ActiveLessSymfonyModel {
175
+ description: string;
176
+ quantity: number;
177
+ quantityUnitId: number;
178
+ subtotal: number;
179
+ manufactureCountryCode: string;
180
+ realWeight: number;
181
+ commodityId: number;
182
+ quantityUnit: QuantityUnit;
183
+ manufactureCountry: ManufactureCountry;
184
+ commodity: Commodity;
185
+ }
186
+ export interface QuantityUnit extends SymfonyModel {
187
+ code: string;
188
+ name: string;
189
+ }
190
+ export interface ManufactureCountry {
191
+ id: string;
192
+ code: string;
193
+ name: string;
194
+ locationType: string[];
195
+ unit: string[];
196
+ timezone: string;
197
+ hasImportService: boolean;
198
+ isActive: boolean;
199
+ regions: string[];
200
+ zones: string[];
201
+ isoCode: string;
202
+ }
203
+ export interface Commodity extends SymfonyModel {
204
+ code: string;
205
+ name: string;
206
+ countryId: number;
207
+ }
208
+ export interface DocumentType extends SymfonyModel {
209
+ code: string;
210
+ name: string;
211
+ description: string;
212
+ }
213
+ export interface TradingTransactionType extends SymfonyModel {
214
+ code: string;
215
+ name: string;
216
+ description: string;
217
+ }
218
+ export interface DocumentFunction extends SymfonyModel {
219
+ code: string;
220
+ name: string;
221
+ }
222
+ export interface ShipmentGsop extends ActiveLessSymfonyModel {
223
+ productContentCode: string;
224
+ originServiceAreaCode: string;
225
+ destinationServiceAreaCode: string;
226
+ internalServiceCode: string;
227
+ awbBarCode: string;
228
+ dhlRoutingBarCode: string;
229
+ }
230
+ export interface ShipmentCompanyCountryExtraCharges extends ActiveLessSymfonyModel {
231
+ subtotal: number;
232
+ tax: number;
233
+ total: number;
234
+ extraChargeId: number;
235
+ extraChargeCode: string;
236
+ }
237
+ export interface AdditionalData {
238
+ awbTypeCode: string;
239
+ countryCode: string;
240
+ shipmentTypeCode: string;
241
+ productGlobalCode: string;
242
+ productLocalCode: string;
243
+ currencyCode: string;
244
+ userUsername: string;
245
+ locationFacilityCode: string;
246
+ }
247
+ export interface Customs {
248
+ criteria: Criteria;
249
+ rules: Rules[];
250
+ }
251
+ export interface Criteria {
252
+ origin: string;
253
+ destination: string;
254
+ dutiable: boolean;
255
+ declaredValue: number;
256
+ }
257
+ export interface Rules {
258
+ id: number;
259
+ level: string;
260
+ attributes: Attributes[];
261
+ }
262
+ export interface Attributes {
263
+ id: number;
264
+ field: string;
265
+ dhlCode: string;
266
+ values: Values;
267
+ }
268
+ export interface Values {
269
+ shipment: string;
270
+ customer: CustomerComposition;
271
+ invoiceHeader: string;
272
+ invoiceItem: string[];
273
+ }
274
+ export interface CustomerComposition {
275
+ SP: string;
276
+ RV: string;
277
+ }
278
+ export interface ShipmentBookPickup extends ActiveLessSymfonyModel {
279
+ pickupDate: string;
280
+ readyByTime: string;
281
+ closeTime: string;
282
+ confirmationNumber: string;
283
+ packageLocationId: number;
284
+ remarks: string;
285
+ packageLocation: PackageLocation;
286
+ }
287
+ export interface PackageLocation extends SymfonyModel {
288
+ name: string;
289
+ }
@@ -0,0 +1,4 @@
1
+ import { ShipmentComposition } from './api-composition.interfaces';
2
+ export type ShipmentOut = {
3
+ shipment: ShipmentComposition;
4
+ };
@@ -0,0 +1,6 @@
1
+ export declare enum CustomerType {
2
+ SHIPPER = "SP",
3
+ CONSIGNEE = "RV",
4
+ IMPORTER = "IP",
5
+ EXPORTER = "EP"
6
+ }
@@ -17,6 +17,7 @@ import { InjectionToken } from '@angular/core';
17
17
  export type Environment = {
18
18
  apiBillingDO?: string;
19
19
  apiBillingMX?: string;
20
+ apiBillingPA?: string;
20
21
  apiCashOperationsUrl?: string;
21
22
  apiCatalogsUrl?: string;
22
23
  apiCompaniesUrl?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@experteam-mx/ngx-services",
3
- "version": "18.6.0",
3
+ "version": "18.6.2",
4
4
  "description": "Angular common services for Experteam apps",
5
5
  "author": "Experteam Cía. Ltda.",
6
6
  "keywords": [
package/public-api.d.ts CHANGED
@@ -2,6 +2,7 @@ export * from './lib/ngx-services.models';
2
2
  export * from './lib/ngx-services.module';
3
3
  export * from './lib/apis/api-billing-do.service';
4
4
  export * from './lib/apis/api-billing-mx.service';
5
+ export * from './lib/apis/api-billing-pa.service';
5
6
  export * from './lib/apis/api-cash-operations.service';
6
7
  export * from './lib/apis/api-catalogs.service';
7
8
  export * from './lib/apis/api-companies.service';
@@ -14,6 +15,8 @@ export * from './lib/apis/api-reports.service';
14
15
  export * from './lib/apis/api-security.service';
15
16
  export * from './lib/apis/api-shipments.service';
16
17
  export * from './lib/apis/models/api-billing.types';
18
+ export * from './lib/apis/models/api-billing-pa.interfaces';
19
+ export * from './lib/apis/models/api-billing-pa.types';
17
20
  export * from './lib/apis/models/api-cash-operations.interfaces';
18
21
  export * from './lib/apis/models/api-cash-operations.types';
19
22
  export * from './lib/apis/models/api-catalog.interfaces';