@tec.pet/tecpet-sdk 0.0.169 → 0.0.170
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/dist/domain/integrationService/dto/pa.edit-integration-service.dto.d.ts +50 -0
- package/dist/domain/integrationService/dto/pa.edit-integration-service.dto.js +9 -0
- package/dist/domain/integrationService/dto/pa.get-integration-service-by-extern-id.dto.d.ts +3 -0
- package/dist/domain/integrationService/dto/pa.get-integration-service-by-extern-id.dto.js +2 -0
- package/dist/domain/integrationService/dto/pa.get-integration-service.dto.d.ts +6 -0
- package/dist/domain/integrationService/dto/pa.get-integration-service.dto.js +2 -0
- package/dist/domain/integrationService/index.d.ts +4 -0
- package/dist/domain/integrationService/index.js +20 -0
- package/dist/domain/integrationService/integrationService.service.d.ts +11 -0
- package/dist/domain/integrationService/integrationService.service.js +19 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +4 -0
- package/package.json +1 -1
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { ApiIntegrationType } from '../../integrationShop/dto/pa.get-integration-shop-by-login.dto';
|
|
2
|
+
import { IntegrationSyncDirection, IntegrationSyncTrigger } from '../../integrationInvoice/dto/pa.edit-integration-invoice.dto';
|
|
3
|
+
export declare enum IntegrationServiceStatusType {
|
|
4
|
+
PROCESSING = "PROCESSING",
|
|
5
|
+
INTEGRATED = "INTEGRATED",
|
|
6
|
+
FAILED = "FAILED"
|
|
7
|
+
}
|
|
8
|
+
export interface PaEditIntegrationServiceRequest {
|
|
9
|
+
type: ApiIntegrationType;
|
|
10
|
+
serviceId: number;
|
|
11
|
+
externId: string;
|
|
12
|
+
status?: IntegrationServiceStatusType;
|
|
13
|
+
integrationShopId?: number;
|
|
14
|
+
errorMessage?: string;
|
|
15
|
+
sizeItemId?: number;
|
|
16
|
+
hairItemId?: number;
|
|
17
|
+
breedId?: number;
|
|
18
|
+
syncDirection?: IntegrationSyncDirection;
|
|
19
|
+
syncTrigger?: IntegrationSyncTrigger;
|
|
20
|
+
}
|
|
21
|
+
export interface IntegrationServiceResponse {
|
|
22
|
+
id: number;
|
|
23
|
+
type: ApiIntegrationType;
|
|
24
|
+
status: IntegrationServiceStatusType;
|
|
25
|
+
externId: string;
|
|
26
|
+
errorMessage?: string;
|
|
27
|
+
service?: {
|
|
28
|
+
id: number;
|
|
29
|
+
};
|
|
30
|
+
integrationShop?: {
|
|
31
|
+
id: number;
|
|
32
|
+
};
|
|
33
|
+
sizeItem?: {
|
|
34
|
+
id: number;
|
|
35
|
+
} | null;
|
|
36
|
+
hairItem?: {
|
|
37
|
+
id: number;
|
|
38
|
+
} | null;
|
|
39
|
+
breed?: {
|
|
40
|
+
id: number;
|
|
41
|
+
} | null;
|
|
42
|
+
syncDirection?: IntegrationSyncDirection;
|
|
43
|
+
syncTrigger?: IntegrationSyncTrigger;
|
|
44
|
+
consecutiveFailures?: number;
|
|
45
|
+
lastSyncedAt?: string;
|
|
46
|
+
lastSuccessAt?: string;
|
|
47
|
+
lastErrorAt?: string;
|
|
48
|
+
createdDate?: string;
|
|
49
|
+
updatedAt?: string;
|
|
50
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IntegrationServiceStatusType = void 0;
|
|
4
|
+
var IntegrationServiceStatusType;
|
|
5
|
+
(function (IntegrationServiceStatusType) {
|
|
6
|
+
IntegrationServiceStatusType["PROCESSING"] = "PROCESSING";
|
|
7
|
+
IntegrationServiceStatusType["INTEGRATED"] = "INTEGRATED";
|
|
8
|
+
IntegrationServiceStatusType["FAILED"] = "FAILED";
|
|
9
|
+
})(IntegrationServiceStatusType || (exports.IntegrationServiceStatusType = IntegrationServiceStatusType = {}));
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./integrationService.service"), exports);
|
|
18
|
+
__exportStar(require("./dto/pa.edit-integration-service.dto"), exports);
|
|
19
|
+
__exportStar(require("./dto/pa.get-integration-service.dto"), exports);
|
|
20
|
+
__exportStar(require("./dto/pa.get-integration-service-by-extern-id.dto"), exports);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HttpClient } from "../../infra/http/client.http";
|
|
2
|
+
import { IntegrationServiceResponse, PaEditIntegrationServiceRequest } from "./dto/pa.edit-integration-service.dto";
|
|
3
|
+
import { PaGetIntegrationServiceRequest } from "./dto/pa.get-integration-service.dto";
|
|
4
|
+
import { PaGetIntegrationServiceByExternIdRequest } from "./dto/pa.get-integration-service-by-extern-id.dto";
|
|
5
|
+
export declare class IntegrationServiceService {
|
|
6
|
+
private readonly api;
|
|
7
|
+
constructor(api: HttpClient);
|
|
8
|
+
edit(body: PaEditIntegrationServiceRequest, shopId: number): Promise<IntegrationServiceResponse>;
|
|
9
|
+
get(query: PaGetIntegrationServiceRequest, shopId: number): Promise<IntegrationServiceResponse[]>;
|
|
10
|
+
getByExternId(query: PaGetIntegrationServiceByExternIdRequest, shopId: number): Promise<IntegrationServiceResponse[]>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IntegrationServiceService = void 0;
|
|
4
|
+
class IntegrationServiceService {
|
|
5
|
+
api;
|
|
6
|
+
constructor(api) {
|
|
7
|
+
this.api = api;
|
|
8
|
+
}
|
|
9
|
+
async edit(body, shopId) {
|
|
10
|
+
return await this.api.patch(`/integrationService`, body, shopId);
|
|
11
|
+
}
|
|
12
|
+
async get(query, shopId) {
|
|
13
|
+
return await this.api.get(`/integrationService`, query, shopId);
|
|
14
|
+
}
|
|
15
|
+
async getByExternId(query, shopId) {
|
|
16
|
+
return await this.api.get(`/integrationService/byExternId`, query, shopId);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
exports.IntegrationServiceService = IntegrationServiceService;
|
package/dist/index.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ import { IntegrationShopService } from "./domain/integrationShop/integrationShop
|
|
|
16
16
|
import { IntegrationClientService } from "./domain/integrationClient/integrationClient.service";
|
|
17
17
|
import { FiscalInvoiceService } from "./domain/fiscalInvoice/fiscalInvoice.service";
|
|
18
18
|
import { IntegrationInvoiceService } from "./domain/integrationInvoice/integrationInvoice.service";
|
|
19
|
+
import { IntegrationServiceService } from "./domain/integrationService/integrationService.service";
|
|
19
20
|
import { InvoiceService } from "./domain/invoice/invoice.service";
|
|
20
21
|
import { ServiceRecommendationService } from "./domain/serviceRecommendation/serviceRecommendation.service";
|
|
21
22
|
import { BlockedTimeService } from "./domain/blockedTime/blockedTime.service";
|
|
@@ -40,6 +41,7 @@ export declare class TecpetSDK {
|
|
|
40
41
|
integrationClient: IntegrationClientService;
|
|
41
42
|
fiscalInvoice: FiscalInvoiceService;
|
|
42
43
|
integrationInvoice: IntegrationInvoiceService;
|
|
44
|
+
integrationService: IntegrationServiceService;
|
|
43
45
|
invoice: InvoiceService;
|
|
44
46
|
serviceRecommendation: ServiceRecommendationService;
|
|
45
47
|
blockedTime: BlockedTimeService;
|
|
@@ -64,6 +66,7 @@ export * from './domain/integrationShop';
|
|
|
64
66
|
export * from './domain/integrationClient';
|
|
65
67
|
export * from './domain/fiscalInvoice';
|
|
66
68
|
export * from './domain/integrationInvoice';
|
|
69
|
+
export * from './domain/integrationService';
|
|
67
70
|
export * from './domain/invoice';
|
|
68
71
|
export * from './domain/serviceRecommendation';
|
|
69
72
|
export * from './domain/blockedTime';
|
package/dist/index.js
CHANGED
|
@@ -34,6 +34,7 @@ const integrationShop_service_1 = require("./domain/integrationShop/integrationS
|
|
|
34
34
|
const integrationClient_service_1 = require("./domain/integrationClient/integrationClient.service");
|
|
35
35
|
const fiscalInvoice_service_1 = require("./domain/fiscalInvoice/fiscalInvoice.service");
|
|
36
36
|
const integrationInvoice_service_1 = require("./domain/integrationInvoice/integrationInvoice.service");
|
|
37
|
+
const integrationService_service_1 = require("./domain/integrationService/integrationService.service");
|
|
37
38
|
const invoice_service_1 = require("./domain/invoice/invoice.service");
|
|
38
39
|
const serviceRecommendation_service_1 = require("./domain/serviceRecommendation/serviceRecommendation.service");
|
|
39
40
|
const blockedTime_service_1 = require("./domain/blockedTime/blockedTime.service");
|
|
@@ -58,6 +59,7 @@ class TecpetSDK {
|
|
|
58
59
|
integrationClient;
|
|
59
60
|
fiscalInvoice;
|
|
60
61
|
integrationInvoice;
|
|
62
|
+
integrationService;
|
|
61
63
|
invoice;
|
|
62
64
|
serviceRecommendation;
|
|
63
65
|
blockedTime;
|
|
@@ -82,6 +84,7 @@ class TecpetSDK {
|
|
|
82
84
|
this.integrationClient = new integrationClient_service_1.IntegrationClientService(this.api);
|
|
83
85
|
this.fiscalInvoice = new fiscalInvoice_service_1.FiscalInvoiceService(this.api);
|
|
84
86
|
this.integrationInvoice = new integrationInvoice_service_1.IntegrationInvoiceService(this.api);
|
|
87
|
+
this.integrationService = new integrationService_service_1.IntegrationServiceService(this.api);
|
|
85
88
|
this.invoice = new invoice_service_1.InvoiceService(this.api);
|
|
86
89
|
this.serviceRecommendation = new serviceRecommendation_service_1.ServiceRecommendationService(this.api);
|
|
87
90
|
this.blockedTime = new blockedTime_service_1.BlockedTimeService(this.api);
|
|
@@ -107,6 +110,7 @@ __exportStar(require("./domain/integrationShop"), exports);
|
|
|
107
110
|
__exportStar(require("./domain/integrationClient"), exports);
|
|
108
111
|
__exportStar(require("./domain/fiscalInvoice"), exports);
|
|
109
112
|
__exportStar(require("./domain/integrationInvoice"), exports);
|
|
113
|
+
__exportStar(require("./domain/integrationService"), exports);
|
|
110
114
|
__exportStar(require("./domain/invoice"), exports);
|
|
111
115
|
__exportStar(require("./domain/serviceRecommendation"), exports);
|
|
112
116
|
__exportStar(require("./domain/blockedTime"), exports);
|