@aristid/leav-types 1.4.1-248b9e2b → 1.4.1-31443cb4
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/apps/core/config/default.d.ts +8 -2
- package/apps/core/config/development.d.ts +7 -0
- package/apps/core/src/__tests__/e2e/api/e2eUtils.d.ts +14 -3
- package/apps/core/src/__tests__/integration/domain/taskManagerDomain.test.d.ts +1 -0
- package/apps/core/src/__tests__/integration/infra/integrationTestRepoUtils.d.ts +1 -1
- package/apps/core/src/__tests__/integration/integrationTestUtils.d.ts +7 -0
- package/apps/core/src/_types/config.d.ts +14 -0
- package/apps/core/src/_types/errors.d.ts +0 -1
- package/apps/core/src/app/core/tasksManagerApp.d.ts +1 -1
- package/apps/core/src/domain/actions/excelCalculationAction.d.ts +6 -4
- package/apps/core/src/domain/tasksManager/tasksManagerDomain.d.ts +1 -1
- package/apps/core/src/interface/tasksManager.d.ts +1 -1
- package/apps/core/src/utils/helpers/getExcelData.d.ts +3 -0
- package/apps/core/src/utils/helpers/getFileDataBuffer.d.ts +2 -0
- package/package.json +1 -1
|
@@ -77,6 +77,12 @@ export declare namespace mailer {
|
|
|
77
77
|
}
|
|
78
78
|
export { auth_1 as auth };
|
|
79
79
|
}
|
|
80
|
+
export declare namespace actions {
|
|
81
|
+
namespace excel {
|
|
82
|
+
let useNewHyperformula: boolean;
|
|
83
|
+
let debug: boolean;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
80
86
|
export declare namespace bugsnag {
|
|
81
87
|
let enable_1: boolean;
|
|
82
88
|
export { enable_1 as enable };
|
|
@@ -180,7 +186,7 @@ export declare namespace indexationManager {
|
|
|
180
186
|
}
|
|
181
187
|
export { queues_3 as queues };
|
|
182
188
|
}
|
|
183
|
-
|
|
189
|
+
declare let debug_1: boolean;
|
|
184
190
|
export declare let defaultUserId: string;
|
|
185
191
|
export declare namespace _export {
|
|
186
192
|
let directory_1: string;
|
|
@@ -236,4 +242,4 @@ export declare namespace logsCollector {
|
|
|
236
242
|
let queue: string;
|
|
237
243
|
}
|
|
238
244
|
export declare let pluginsPath: string[];
|
|
239
|
-
export { _export as export, _import as import };
|
|
245
|
+
export { debug_1 as debug, _export as export, _import as import };
|
|
@@ -5,13 +5,21 @@ import type FormData from 'form-data';
|
|
|
5
5
|
import { type ActionsListConfig } from '_types/actionsList';
|
|
6
6
|
import { type ITreeElement } from '_types/tree';
|
|
7
7
|
import { AttributeFormats, type AttributeTypes, type IAttributeVersionsConf, type IEmbeddedAttribute } from '../../../_types/attribute';
|
|
8
|
+
interface IE2EUser {
|
|
9
|
+
getAuthToken: () => Promise<string>;
|
|
10
|
+
}
|
|
11
|
+
export declare const e2eAdminUser: () => IE2EUser;
|
|
12
|
+
export declare const e2eGuestUser: () => Promise<IE2EUser>;
|
|
8
13
|
export declare function getGraphQLUrl(): Promise<string>;
|
|
9
14
|
export declare class E2EGraphQLError extends Error {
|
|
10
15
|
readonly response: AxiosResponse;
|
|
11
16
|
constructor(message: string, response: AxiosResponse);
|
|
12
17
|
}
|
|
13
|
-
export
|
|
14
|
-
|
|
18
|
+
export interface IMakeGraphQlCallOptions {
|
|
19
|
+
user?: IE2EUser;
|
|
20
|
+
}
|
|
21
|
+
export declare function makeGraphQlCall(query: string | FormData, options?: IMakeGraphQlCallOptions): Promise<any>;
|
|
22
|
+
export declare function gqlSaveLibrary(id: string, label: string, additionalAttributes?: string[], settings?: string): Promise<any>;
|
|
15
23
|
export declare function gqlSaveApplication(id: string, label: string, endpoint: string): Promise<any>;
|
|
16
24
|
export declare function gqlSaveAttribute(params: {
|
|
17
25
|
id: string;
|
|
@@ -48,10 +56,13 @@ export declare function gqlSaveVersionProfile(profileId: string, label: string,
|
|
|
48
56
|
* Convert object to JSON, escaping quotes to be able to use it in a graphql query
|
|
49
57
|
**/
|
|
50
58
|
export declare function toCleanJSON(obj: {}): string;
|
|
51
|
-
export declare function makeWebSocketGraphQlCall(
|
|
59
|
+
export declare function makeWebSocketGraphQlCall(options?: {
|
|
60
|
+
user: IE2EUser;
|
|
61
|
+
}): Promise<GraphqlWsClient>;
|
|
52
62
|
export declare function waitGraphqlWebSocketMessage<T>(client: GraphqlWsClient, query: string, variables: Record<string, any>, acceptMessage: (msg: T) => boolean, { timeoutMs }: {
|
|
53
63
|
timeoutMs: any;
|
|
54
64
|
}): Promise<T>;
|
|
55
65
|
export declare function waitWebSocketMessage<T>(webSocket: WebSocket, acceptMessage: (msg: T) => boolean, { timeoutMs }: {
|
|
56
66
|
timeoutMs: any;
|
|
57
67
|
}): Promise<T>;
|
|
68
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ILibraryRepo } from 'infra/library/libraryRepo';
|
|
2
2
|
import { type IRecordRepo } from 'infra/record/recordRepo';
|
|
3
3
|
import { type ITreeRepo } from 'infra/tree/treeRepo';
|
|
4
|
-
export declare const getCoreDep: <T>(path: any) => T;
|
|
5
4
|
export declare const getLibraryRepo: () => ILibraryRepo;
|
|
6
5
|
export declare const getRecordRepo: () => IRecordRepo;
|
|
7
6
|
export declare const getTreeRepo: () => ITreeRepo;
|
|
7
|
+
export * from '../integrationTestUtils';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type AwilixContainer } from 'awilix';
|
|
2
|
+
export interface IGlobalThis {
|
|
3
|
+
coreContainer: AwilixContainer;
|
|
4
|
+
taskManagerMasterTimer: NodeJS.Timeout;
|
|
5
|
+
}
|
|
6
|
+
export declare const getCoreContainer: () => AwilixContainer;
|
|
7
|
+
export declare const getCoreDep: <T>(path: any) => T;
|
|
@@ -25,6 +25,7 @@ export interface IConfig {
|
|
|
25
25
|
plugins: IKeyValue<IKeyValue<any>>;
|
|
26
26
|
preview: IPreview;
|
|
27
27
|
applications: IApplicationsConfig;
|
|
28
|
+
actions: IActions;
|
|
28
29
|
files: IFilesConfig;
|
|
29
30
|
dbProfiler: IDbProfilerConfig;
|
|
30
31
|
instanceId: string;
|
|
@@ -62,6 +63,19 @@ export interface IServer {
|
|
|
62
63
|
email: string;
|
|
63
64
|
};
|
|
64
65
|
}
|
|
66
|
+
export interface IActions {
|
|
67
|
+
excel: {
|
|
68
|
+
/**
|
|
69
|
+
* Replace deprecated hot-formula-parser npm module by new hyperformula npm module
|
|
70
|
+
* Formulas should be compatible
|
|
71
|
+
*/
|
|
72
|
+
useNewHyperformula: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Add debug log for each calculation with formula and result or error
|
|
75
|
+
*/
|
|
76
|
+
debug: boolean;
|
|
77
|
+
};
|
|
78
|
+
}
|
|
65
79
|
export interface IDb {
|
|
66
80
|
url: string;
|
|
67
81
|
name: string;
|
|
@@ -17,7 +17,6 @@ export declare enum Errors {
|
|
|
17
17
|
ENCRYPT_ERROR = "ENCRYPT_ERROR",
|
|
18
18
|
ERROR = "ERROR",
|
|
19
19
|
EXCEL_CALCULATION_ERROR = "EXCEL_CALCULATION_ERROR",
|
|
20
|
-
FILE_ERROR = "FILE_ERROR",
|
|
21
20
|
FILE_NOT_FOUND = "FILE_NOT_FOUND",
|
|
22
21
|
FORBIDDEN_FILES = "FORBIDDEN_FILES",
|
|
23
22
|
FORBIDDEN_ID = "FORBIDDEN_ID",
|
|
@@ -8,7 +8,7 @@ import { type ITasksManagerDomain } from '../../domain/tasksManager/tasksManager
|
|
|
8
8
|
import { TaskStatus } from '../../_types/tasksManager';
|
|
9
9
|
import { type IGraphqlAppModule } from 'app/graphql/graphqlApp';
|
|
10
10
|
export interface ITasksManagerApp extends IGraphqlAppModule {
|
|
11
|
-
initMaster(): Promise<NodeJS.
|
|
11
|
+
initMaster(): Promise<NodeJS.Timeout>;
|
|
12
12
|
initWorker(): Promise<void>;
|
|
13
13
|
}
|
|
14
14
|
interface IDeps {
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
+
import { type ILogger } from '@leav/logger';
|
|
1
2
|
import { type ICalculationVariable } from 'domain/helpers/calculationVariable';
|
|
2
|
-
import { type IUtils } from 'utils/utils';
|
|
3
3
|
import { type IActionsListFunction } from '../../_types/actionsList';
|
|
4
|
+
import { type IConfig } from '_types/config';
|
|
4
5
|
interface IDeps {
|
|
5
|
-
'core.domain.helpers.calculationVariable'
|
|
6
|
-
|
|
6
|
+
'core.domain.helpers.calculationVariable': ICalculationVariable;
|
|
7
|
+
config: IConfig;
|
|
8
|
+
'core.utils.logger': ILogger;
|
|
7
9
|
}
|
|
8
|
-
export default function ({ 'core.domain.helpers.calculationVariable': calculationVariable }
|
|
10
|
+
export default function ({ 'core.domain.helpers.calculationVariable': calculationVariable, 'core.utils.logger': logger, config }: IDeps): IActionsListFunction<{
|
|
9
11
|
Formula: true;
|
|
10
12
|
Description: true;
|
|
11
13
|
}>;
|
|
@@ -38,7 +38,7 @@ interface IGetTasksParams extends IGetCoreEntitiesParams {
|
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
export interface ITasksManagerDomain {
|
|
41
|
-
initMaster(): Promise<NodeJS.
|
|
41
|
+
initMaster(): Promise<NodeJS.Timeout>;
|
|
42
42
|
initWorker(): Promise<void>;
|
|
43
43
|
getTasks({ params, ctx }: {
|
|
44
44
|
params: IGetTasksParams;
|