@colijnit/mainapi 261.1.9 → 261.1.10
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/build/enum/general-method.enum.d.ts +2 -1
- package/build/enum/general-method.enum.js +1 -0
- package/build/enum/public-service-method.d.ts +2 -1
- package/build/enum/public-service-method.js +1 -0
- package/build/main-api-connection.d.ts +1 -0
- package/build/main-api.d.ts +1 -0
- package/build/main-api.js +5 -0
- package/build/main-api.unit.test.js +8 -0
- package/build/main-auth.d.ts +1 -0
- package/build/main-auth.js +16 -0
- package/build/main-public.d.ts +1 -0
- package/build/main-public.js +6 -0
- package/package.json +1 -1
|
@@ -33,5 +33,6 @@ export declare enum GeneralMethod {
|
|
|
33
33
|
MergeTexts = "mergeTexts",
|
|
34
34
|
SelectTextsByTableKey = "selectTextsByTableKey",
|
|
35
35
|
GetResultOfValidationCurrentDatabaseObjectsChecksum = "getResultOfValidationCurrentDatabaseObjectsChecksum",
|
|
36
|
-
PostalCodeRetrieval = "postalCodeRetrieval"
|
|
36
|
+
PostalCodeRetrieval = "postalCodeRetrieval",
|
|
37
|
+
CreateQrCode = "createQRCode"
|
|
37
38
|
}
|
|
@@ -38,4 +38,5 @@ var GeneralMethod;
|
|
|
38
38
|
GeneralMethod["SelectTextsByTableKey"] = "selectTextsByTableKey";
|
|
39
39
|
GeneralMethod["GetResultOfValidationCurrentDatabaseObjectsChecksum"] = "getResultOfValidationCurrentDatabaseObjectsChecksum";
|
|
40
40
|
GeneralMethod["PostalCodeRetrieval"] = "postalCodeRetrieval";
|
|
41
|
+
GeneralMethod["CreateQrCode"] = "createQRCode";
|
|
41
42
|
})(GeneralMethod || (exports.GeneralMethod = GeneralMethod = {}));
|
|
@@ -19,5 +19,6 @@ export declare enum PublicServiceMethod {
|
|
|
19
19
|
Commit = "commit",
|
|
20
20
|
GetScreenConfig = "getScreenconfig",
|
|
21
21
|
GetGoogleTranslateV3 = "getGoogleTranslateV3",
|
|
22
|
-
IsGoogleTranslateEnabled = "isGoogleTranslateEnabled"
|
|
22
|
+
IsGoogleTranslateEnabled = "isGoogleTranslateEnabled",
|
|
23
|
+
CreateQRCode = "createQRCode"
|
|
23
24
|
}
|
|
@@ -24,4 +24,5 @@ var PublicServiceMethod;
|
|
|
24
24
|
PublicServiceMethod["GetScreenConfig"] = "getScreenconfig";
|
|
25
25
|
PublicServiceMethod["GetGoogleTranslateV3"] = "getGoogleTranslateV3";
|
|
26
26
|
PublicServiceMethod["IsGoogleTranslateEnabled"] = "isGoogleTranslateEnabled";
|
|
27
|
+
PublicServiceMethod["CreateQRCode"] = "createQRCode";
|
|
27
28
|
})(PublicServiceMethod || (exports.PublicServiceMethod = PublicServiceMethod = {}));
|
|
@@ -110,4 +110,5 @@ export declare abstract class MainApiConnection {
|
|
|
110
110
|
abstract createContainer(container: Container): Promise<DataServiceResponseData>;
|
|
111
111
|
abstract updateContainer(container: Container): Promise<DataServiceResponseData>;
|
|
112
112
|
abstract getWarehousesShort(): Promise<DataServiceResponseData>;
|
|
113
|
+
abstract createQRCode(width: number, height: number, value: string, showLoader?: boolean): Promise<DataServiceResponseData>;
|
|
113
114
|
}
|
package/build/main-api.d.ts
CHANGED
|
@@ -126,6 +126,7 @@ export declare class MainApi {
|
|
|
126
126
|
initializeModelCreationRenderRequest(uploadType: string, caseName: string, quality: string, explanation: string, fileName: string, fileSize: number, fileHash: string): Promise<DataServiceResponseData>;
|
|
127
127
|
getModelCreationRenderStatus(uploadId?: string): Promise<DataServiceResponseData>;
|
|
128
128
|
getWarehousesShort(): Promise<DataServiceResponseData>;
|
|
129
|
+
createQRCode(width: number, height: number, value: string, showLoader?: boolean): Promise<DataServiceResponseData>;
|
|
129
130
|
static createConnector(isPublicSession: boolean, sessionExists: boolean): MainApiConnection;
|
|
130
131
|
private _handleConnectionReset;
|
|
131
132
|
}
|
package/build/main-api.js
CHANGED
|
@@ -362,6 +362,11 @@ class MainApi {
|
|
|
362
362
|
return this.mainApi.getWarehousesShort();
|
|
363
363
|
});
|
|
364
364
|
}
|
|
365
|
+
createQRCode(width, height, value, showLoader) {
|
|
366
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
367
|
+
return this.mainApi.createQRCode(width, height, value, showLoader);
|
|
368
|
+
});
|
|
369
|
+
}
|
|
365
370
|
static createConnector(isPublicSession, sessionExists) {
|
|
366
371
|
if (!isPublicSession || sessionExists) {
|
|
367
372
|
return new main_auth_1.MainAuth();
|
|
@@ -205,4 +205,12 @@ describe("Connector", () => {
|
|
|
205
205
|
const result = yield connector.getContainerTypes();
|
|
206
206
|
expect(result).toBeDefined();
|
|
207
207
|
}));
|
|
208
|
+
it('createQrCode', () => __awaiter(void 0, void 0, void 0, function* () {
|
|
209
|
+
yield connector.connect();
|
|
210
|
+
const height = 480;
|
|
211
|
+
const width = 480;
|
|
212
|
+
const value = "https://google.com";
|
|
213
|
+
const result = yield connector.createQRCode(width, height, value);
|
|
214
|
+
expect(result).toBeDefined();
|
|
215
|
+
}));
|
|
208
216
|
});
|
package/build/main-auth.d.ts
CHANGED
|
@@ -103,6 +103,7 @@ export declare class MainAuth extends MainApiConnection {
|
|
|
103
103
|
getContainerTypes(): Promise<DataServiceResponseData>;
|
|
104
104
|
createContainer(container: Container): Promise<DataServiceResponseData>;
|
|
105
105
|
updateContainer(container: Container): Promise<DataServiceResponseData>;
|
|
106
|
+
createQRCode(width: number, height: number, value: string, showLoader?: boolean): Promise<DataServiceResponseData>;
|
|
106
107
|
selectMultiple(moduleName: ModuleName, objectName: string, operationName?: string, parameterValues?: any, showLoader?: boolean): Promise<DataServiceResponseData>;
|
|
107
108
|
getWarehousesShort(): Promise<DataServiceResponseData>;
|
|
108
109
|
private _call;
|
package/build/main-auth.js
CHANGED
|
@@ -1014,6 +1014,22 @@ class MainAuth extends main_api_connection_1.MainApiConnection {
|
|
|
1014
1014
|
return this._call(data_service_method_enum_1.DataServiceMethod.UpdateObject, data);
|
|
1015
1015
|
});
|
|
1016
1016
|
}
|
|
1017
|
+
createQRCode(width, height, value, showLoader) {
|
|
1018
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1019
|
+
const params = {
|
|
1020
|
+
width: width,
|
|
1021
|
+
height: height,
|
|
1022
|
+
value: value
|
|
1023
|
+
};
|
|
1024
|
+
const data = {
|
|
1025
|
+
moduleName: module_name_enum_1.ModuleName.General,
|
|
1026
|
+
methodName: general_method_enum_1.GeneralMethod.CreateQrCode,
|
|
1027
|
+
parameterValues: params,
|
|
1028
|
+
refCursorAsArray: true,
|
|
1029
|
+
};
|
|
1030
|
+
return this._call(data_service_method_enum_1.DataServiceMethod.ExecuteMethod, data, backend_service_name_enum_1.BackendServiceName.DataService, showLoader);
|
|
1031
|
+
});
|
|
1032
|
+
}
|
|
1017
1033
|
selectMultiple(moduleName, objectName, operationName, parameterValues, showLoader) {
|
|
1018
1034
|
if (showLoader === undefined) {
|
|
1019
1035
|
showLoader = false;
|
package/build/main-public.d.ts
CHANGED
|
@@ -98,6 +98,7 @@ export declare class MainPublic extends MainApiConnection {
|
|
|
98
98
|
getImage(key: number | string, publication?: number, includeMimetype?: boolean, thumb?: boolean): Promise<DataServiceResponseData>;
|
|
99
99
|
getImageForCoDocument(document: CoDocument, thumb?: boolean): Promise<DataServiceResponseData>;
|
|
100
100
|
getWarehousesShort(): Promise<DataServiceResponseData>;
|
|
101
|
+
createQRCode(width: number, height: number, value: string, showLoader?: boolean): Promise<DataServiceResponseData>;
|
|
101
102
|
getContainers(): Promise<DataServiceResponseData>;
|
|
102
103
|
getContainer(containerId: number): Promise<DataServiceResponseData>;
|
|
103
104
|
getContainerInfo(containerId: number): Promise<DataServiceResponseData>;
|
package/build/main-public.js
CHANGED
|
@@ -428,6 +428,12 @@ class MainPublic extends main_api_connection_1.MainApiConnection {
|
|
|
428
428
|
return Promise.resolve(new data_service_response_data_1.DataServiceResponseData());
|
|
429
429
|
});
|
|
430
430
|
}
|
|
431
|
+
createQRCode(width, height, value, showLoader) {
|
|
432
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
433
|
+
const data = Object.assign(Object.assign({}, this.createServiceRequestData()), { width: width, height: height, value: value, showLoader: showLoader });
|
|
434
|
+
return this._call(public_service_method_1.PublicServiceMethod.CreateQRCode, data);
|
|
435
|
+
});
|
|
436
|
+
}
|
|
431
437
|
getContainers() {
|
|
432
438
|
return __awaiter(this, void 0, void 0, function* () {
|
|
433
439
|
console.warn('getContainers not implemented');
|