@neuralinnovations/dataisland-sdk 0.6.34 → 0.6.36
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/package.json +1 -1
- package/dist/src/dto/queryFlowResponse.d.ts +8 -9
- package/dist/src/dto/queryFlowResponse.d.ts.map +1 -1
- package/dist/src/dto/queryFlowResponse.js +8 -10
- package/dist/src/dto/queryFlowResponse.js.map +1 -1
- package/dist/src/storages/chatbot/chatbotAccounts.impl.d.ts.map +1 -1
- package/dist/src/storages/chatbot/chatbotAccounts.impl.js +2 -1
- package/dist/src/storages/chatbot/chatbotAccounts.impl.js.map +1 -1
- package/dist/src/storages/queryFlows/queryFlow.d.ts +3 -2
- package/dist/src/storages/queryFlows/queryFlow.d.ts.map +1 -1
- package/dist/src/storages/queryFlows/queryFlow.impl.d.ts +3 -2
- package/dist/src/storages/queryFlows/queryFlow.impl.d.ts.map +1 -1
- package/dist/src/storages/queryFlows/queryFlow.impl.js +16 -8
- package/dist/src/storages/queryFlows/queryFlow.impl.js.map +1 -1
- package/dist/src/storages/queryFlows/queryFlow.js.map +1 -1
- package/dist/src/storages/queryFlows/queryFlows.d.ts +2 -2
- package/dist/src/storages/queryFlows/queryFlows.d.ts.map +1 -1
- package/dist/src/storages/queryFlows/queryFlows.impl.d.ts +2 -2
- package/dist/src/storages/queryFlows/queryFlows.impl.d.ts.map +1 -1
- package/dist/src/storages/queryFlows/queryFlows.impl.js +4 -6
- package/dist/src/storages/queryFlows/queryFlows.impl.js.map +1 -1
- package/package.json +1 -1
- package/src/dto/queryFlowResponse.ts +13 -10
- package/src/storages/chatbot/chatbotAccounts.impl.ts +2 -1
- package/src/storages/queryFlows/queryFlow.impl.ts +17 -9
- package/src/storages/queryFlows/queryFlow.ts +4 -3
- package/src/storages/queryFlows/queryFlows.impl.ts +6 -8
- package/src/storages/queryFlows/queryFlows.ts +2 -2
package/dist/package.json
CHANGED
@@ -3,14 +3,6 @@ export declare enum QueryFlowState {
|
|
3
3
|
ERROR = 1,
|
4
4
|
DONE = 100
|
5
5
|
}
|
6
|
-
export declare enum QueryFlowStatus {
|
7
|
-
STARTED = 0,
|
8
|
-
UPLOADING_FILE = 1,
|
9
|
-
PROCESSING_FILE = 2,
|
10
|
-
PREPARING_RESULTS = 3,
|
11
|
-
DONE = 4,
|
12
|
-
FAILED = 5
|
13
|
-
}
|
14
6
|
export interface QueryFileUrlDto {
|
15
7
|
name: string;
|
16
8
|
extension: string;
|
@@ -22,8 +14,10 @@ export interface QueryFlowResult {
|
|
22
14
|
export interface QueryFlowDto {
|
23
15
|
name: string;
|
24
16
|
state: QueryFlowState;
|
25
|
-
|
17
|
+
totalRowsCount: number;
|
18
|
+
completedRowsCount: number;
|
26
19
|
result: QueryFlowResult;
|
20
|
+
error: string;
|
27
21
|
}
|
28
22
|
export interface QueryFlowListResponse {
|
29
23
|
flowIds: string[];
|
@@ -31,4 +25,9 @@ export interface QueryFlowListResponse {
|
|
31
25
|
export interface QueryFlowResponse {
|
32
26
|
flowId: string;
|
33
27
|
}
|
28
|
+
export declare class SearchResource {
|
29
|
+
organizationId: string;
|
30
|
+
workspaceIds: string[];
|
31
|
+
constructor(organizationId: string, workspaceIds: string[]);
|
32
|
+
}
|
34
33
|
//# sourceMappingURL=queryFlowResponse.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlowResponse.d.ts","sourceRoot":"","sources":["../../../src/dto/queryFlowResponse.ts"],"names":[],"mappings":"AAAA,oBAAY,cAAc;IACxB,WAAW,IAAI;IACf,KAAK,IAAI;IACT,IAAI,MAAM;CACX;AAED,
|
1
|
+
{"version":3,"file":"queryFlowResponse.d.ts","sourceRoot":"","sources":["../../../src/dto/queryFlowResponse.ts"],"names":[],"mappings":"AAAA,oBAAY,cAAc;IACxB,WAAW,IAAI;IACf,KAAK,IAAI;IACT,IAAI,MAAM;CACX;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAA;IACZ,SAAS,EAAE,MAAM,CAAA;IACjB,GAAG,EAAE,MAAM,CAAA;CACZ;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,eAAe,EAAE,CAAA;CACzB;AAGD,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,cAAc,CAAC;IACtB,cAAc,EAAE,MAAM,CAAA;IACtB,kBAAkB,EAAE,MAAM,CAAA;IAC1B,MAAM,EAAE,eAAe,CAAA;IACvB,KAAK,EAAE,MAAM,CAAA;CACd;AAGD,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,MAAM,EAAE,CAAA;CAClB;AAGD,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAA;CACf;AAED,qBAAa,cAAc;IACzB,cAAc,EAAE,MAAM,CAAA;IACtB,YAAY,EAAE,MAAM,EAAE,CAAA;gBAEV,cAAc,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE;CAI3D"}
|
@@ -1,19 +1,17 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.SearchResource = exports.QueryFlowState = void 0;
|
4
4
|
var QueryFlowState;
|
5
5
|
(function (QueryFlowState) {
|
6
6
|
QueryFlowState[QueryFlowState["IN_PROGRESS"] = 0] = "IN_PROGRESS";
|
7
7
|
QueryFlowState[QueryFlowState["ERROR"] = 1] = "ERROR";
|
8
8
|
QueryFlowState[QueryFlowState["DONE"] = 100] = "DONE";
|
9
9
|
})(QueryFlowState || (exports.QueryFlowState = QueryFlowState = {}));
|
10
|
-
|
11
|
-
(
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
QueryFlowStatus[QueryFlowStatus["FAILED"] = 5] = "FAILED";
|
18
|
-
})(QueryFlowStatus || (exports.QueryFlowStatus = QueryFlowStatus = {}));
|
10
|
+
class SearchResource {
|
11
|
+
constructor(organizationId, workspaceIds) {
|
12
|
+
this.organizationId = organizationId;
|
13
|
+
this.workspaceIds = workspaceIds;
|
14
|
+
}
|
15
|
+
}
|
16
|
+
exports.SearchResource = SearchResource;
|
19
17
|
//# sourceMappingURL=queryFlowResponse.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlowResponse.js","sourceRoot":"","sources":["../../../src/dto/queryFlowResponse.ts"],"names":[],"mappings":";;;AAAA,IAAY,cAIX;AAJD,WAAY,cAAc;IACxB,iEAAe,CAAA;IACf,qDAAS,CAAA;IACT,qDAAU,CAAA;AACZ,CAAC,EAJW,cAAc,8BAAd,cAAc,QAIzB;
|
1
|
+
{"version":3,"file":"queryFlowResponse.js","sourceRoot":"","sources":["../../../src/dto/queryFlowResponse.ts"],"names":[],"mappings":";;;AAAA,IAAY,cAIX;AAJD,WAAY,cAAc;IACxB,iEAAe,CAAA;IACf,qDAAS,CAAA;IACT,qDAAU,CAAA;AACZ,CAAC,EAJW,cAAc,8BAAd,cAAc,QAIzB;AAgCD,MAAa,cAAc;IAIzB,YAAY,cAAsB,EAAE,YAAsB;QACxD,IAAI,CAAC,cAAc,GAAG,cAAc,CAAA;QACpC,IAAI,CAAC,YAAY,GAAG,YAAY,CAAA;IAClC,CAAC;CACF;AARD,wCAQC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chatbotAccounts.impl.d.ts","sourceRoot":"","sources":["../../../../src/storages/chatbot/chatbotAccounts.impl.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,gBAAgB,EAAC,MAAM,oCAAoC,CAAA;AACnE,OAAO,EAAC,OAAO,EAAC,MAAM,eAAe,CAAA;AAGrC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAA;AAEjD,OAAO,EAAqB,kBAAkB,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AAGtG,qBAAa,mBAAoB,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M,EAAE,cAAc,EAAE,MAAM,EAAE,kBAAkB,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,YAAY,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IAgDxK,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CA2BxC"}
|
@@ -60,9 +60,10 @@ class ChatbotAccountsImpl extends chatbotAccounts_1.ChatbotAccounts {
|
|
60
60
|
organizationId: this.organization.id,
|
61
61
|
accountType: type,
|
62
62
|
name: name,
|
63
|
-
token: token,
|
64
63
|
accountId: accountId,
|
64
|
+
token: token,
|
65
65
|
context: accountContext,
|
66
|
+
notificationDelays: notificationDelays,
|
66
67
|
data: data
|
67
68
|
}));
|
68
69
|
// check response status
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chatbotAccounts.impl.js","sourceRoot":"","sources":["../../../../src/storages/chatbot/chatbotAccounts.impl.ts"],"names":[],"mappings":";;;AAGA,0DAAoD;AACpD,gEAA0D;AAC1D,uDAAmD;AAEnD,+DAA0D;AAI1D,MAAa,mBAAoB,SAAQ,iCAAe;IAGtD,YACkB,YAA8B,EAC9B,OAAgB;QAChC,KAAK,EAAE,CAAA;QAFS,iBAAY,GAAZ,YAAY,CAAkB;QAC9B,YAAO,GAAP,OAAO,CAAS;IAElC,CAAC;IAED,IAAI,UAAU;QACZ,IAAI,IAAI,CAAC,WAAW,KAAK,SAAS,EAAE,CAAC;YACnC,OAAO,IAAI,CAAC,WAAW,CAAA;QACzB,CAAC;aAAK,CAAC;YACL,MAAM,IAAI,KAAK,CAAC,mEAAmE,CAAC,CAAA;QACtF,CAAC;IACH,CAAC;IAGD,KAAK,CAAC,MAAM;;QACV,MAAM,QAAQ,GAAG,MAAM,CAAA,MAAA,IAAI,CAAC,OAAO;aAChC,OAAO,CAAC,uBAAU,CAAC,0CAClB,cAAc,CAAC,4BAA4B,EAC5C,WAAW,CAAC,gBAAgB,EAAE,IAAI,CAAC,YAAY,CAAC,E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C;QAED,MAAM,IAAI,CAAC,MAAM,EAAE,CAAA;IACrB,CAAC;IAGD,KAAK,CAAC,MAAM,CAAC,EAAU;;QACrB,MAAM,OAAO,GAAG,MAAA,IAAI,CAAC,WAAW,0CAAE,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,CAAC,CAAA;QAEjE,4BAA4B;QAC5B,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,MAAM,IAAI,KAAK,CAAC,mBAAmB,EAAE,gCAAgC,IAAI,CAAC,YAAY,CAAC,EAAE,EAAE,CAAC,CAAA;QAC9F,CAAC;QAED,oCAAoC;QACpC,MAAM,QAAQ,GAAG,MAAM,CAAA,MAAA,IAAI,CAAC,OAAO;aAChC,OAAO,CAAC,uBAAU,CAAC,0CAClB,cAAc,CAAC,uBAAuB,EACvC,WAAW,CAAC,IAAI,EAAE,EAAE,EACpB,UAAU,EAAE,CAAA,CAAA;QAEf,wBAAwB;QACxB,IAAI,6BAAa,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC;YACnC,MAAM,6BAAa,CAAC,UAAU,CAC5B,qCAAqC,EAAE,mBAAmB,IAAI,CAAC,YAAY,CAAC,EAAE,EAAE,EAChF,QAAQ,CACT,CAAA;QACH,CAAC;QAED,MAAM,IAAI,CAAC,MAAM,EAAE,CAAA;IACrB,CAAC;CAGF;AAjHD,kDAiHC"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { EventDispatcher } from "../../events";
|
2
2
|
import { FlowId } from "./queryFlows";
|
3
|
-
import { QueryFileUrlDto, QueryFlowState
|
3
|
+
import { QueryFileUrlDto, QueryFlowState } from "../../dto/queryFlowResponse";
|
4
4
|
export declare enum QueryFlowEvent {
|
5
5
|
UPDATED = "updated"
|
6
6
|
}
|
@@ -8,7 +8,8 @@ export declare abstract class QueryFlow extends EventDispatcher<QueryFlowEvent,
|
|
8
8
|
abstract get id(): FlowId;
|
9
9
|
abstract get name(): string;
|
10
10
|
abstract get state(): QueryFlowState;
|
11
|
-
abstract get
|
11
|
+
abstract get error(): string;
|
12
|
+
abstract get progress(): number;
|
12
13
|
abstract get urls(): QueryFileUrlDto[] | undefined;
|
13
14
|
abstract fetch(): any;
|
14
15
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlow.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAA;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EACL,eAAe,EACf,cAAc,
|
1
|
+
{"version":3,"file":"queryFlow.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAA;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EACL,eAAe,EACf,cAAc,EACf,MAAM,6BAA6B,CAAA;AAEpC,oBAAY,cAAc;IACxB,OAAO,YAAY;CACpB;AAED,8BAAsB,SAAU,SAAQ,eAAe,CACrD,cAAc,EACd,SAAS,CACV;IAEC,QAAQ,KAAK,EAAE,IAAI,MAAM,CAAA;IAEzB,QAAQ,KAAK,IAAI,IAAI,MAAM,CAAA;IAE3B,QAAQ,KAAK,KAAK,IAAI,cAAc,CAAA;IAEpC,QAAQ,KAAK,KAAK,IAAI,MAAM,CAAA;IAE5B,QAAQ,KAAK,QAAQ,IAAI,MAAM,CAAA;IAE/B,QAAQ,KAAK,IAAI,IAAI,eAAe,EAAE,GAAG,SAAS,CAAA;IAElD,QAAQ,CAAC,KAAK,IAAI,GAAG;CAEtB"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { QueryFlow } from "./queryFlow";
|
2
|
-
import { QueryFileUrlDto, QueryFlowState
|
2
|
+
import { QueryFileUrlDto, QueryFlowState } from "../../dto/queryFlowResponse";
|
3
3
|
import { FlowId } from "./queryFlows";
|
4
4
|
import { Context } from "../../context";
|
5
5
|
export declare class QueryFlowImpl extends QueryFlow {
|
@@ -11,8 +11,9 @@ export declare class QueryFlowImpl extends QueryFlow {
|
|
11
11
|
fetch(): Promise<void>;
|
12
12
|
get id(): FlowId;
|
13
13
|
get name(): string;
|
14
|
+
get error(): string;
|
15
|
+
get progress(): number;
|
14
16
|
get urls(): QueryFileUrlDto[] | undefined;
|
15
17
|
get state(): QueryFlowState;
|
16
|
-
get status(): QueryFlowStatus;
|
17
18
|
}
|
18
19
|
//# sourceMappingURL=queryFlow.impl.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlow.impl.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAkB,MAAM,aAAa,CAAA;AACvD,OAAO,EACL,eAAe,EAEf,cAAc,
|
1
|
+
{"version":3,"file":"queryFlow.impl.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAkB,MAAM,aAAa,CAAA;AACvD,OAAO,EACL,eAAe,EAEf,cAAc,EACf,MAAM,6BAA6B,CAAA;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AAIvC,qBAAa,aAAc,SAAQ,SAAS;IAI9B,OAAO,CAAC,QAAQ,CAAC,OAAO;IAHpC,OAAO,CAAC,QAAQ,CAAC,CAAc;IAC/B,OAAO,CAAC,GAAG,CAAC,CAAQ;gBAES,OAAO,EAAE,OAAO;IAIvC,QAAQ,CAAC,EAAE,EAAE,MAAM;IAKnB,KAAK;IA0BX,IAAI,EAAE,IAAI,MAAM,CAMf;IAED,IAAI,IAAI,IAAI,MAAM,CAMjB;IAED,IAAI,KAAK,IAAI,MAAM,CAMlB;IAED,IAAI,QAAQ,IAAI,MAAM,CAMrB;IAED,IAAI,IAAI,IAAI,eAAe,EAAE,GAAG,SAAS,CAMxC;IAED,IAAI,KAAK,IAAI,cAAc,CAM1B;CAGF"}
|
@@ -48,25 +48,33 @@ class QueryFlowImpl extends queryFlow_1.QueryFlow {
|
|
48
48
|
throw new Error("Query flow is not loaded");
|
49
49
|
}
|
50
50
|
}
|
51
|
-
get
|
52
|
-
if (this._content
|
53
|
-
return this._content.
|
51
|
+
get error() {
|
52
|
+
if (this._content) {
|
53
|
+
return this._content.error;
|
54
54
|
}
|
55
55
|
else {
|
56
|
-
throw new Error("Query
|
56
|
+
throw new Error("Query flow is not loaded");
|
57
57
|
}
|
58
58
|
}
|
59
|
-
get
|
59
|
+
get progress() {
|
60
60
|
if (this._content) {
|
61
|
-
return this._content.
|
61
|
+
return this._content.completedRowsCount / this._content.totalRowsCount;
|
62
|
+
}
|
63
|
+
else {
|
64
|
+
throw new Error("Query flow is not loaded");
|
65
|
+
}
|
66
|
+
}
|
67
|
+
get urls() {
|
68
|
+
if (this._content && this._content.result.files) {
|
69
|
+
return this._content.result.files;
|
62
70
|
}
|
63
71
|
else {
|
64
72
|
throw new Error("Query fLow is not loaded");
|
65
73
|
}
|
66
74
|
}
|
67
|
-
get
|
75
|
+
get state() {
|
68
76
|
if (this._content) {
|
69
|
-
return this._content.
|
77
|
+
return this._content.state;
|
70
78
|
}
|
71
79
|
else {
|
72
80
|
throw new Error("Query fLow is not loaded");
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlow.impl.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.impl.ts"],"names":[],"mappings":";;;AAAA,2CAAuD;
|
1
|
+
{"version":3,"file":"queryFlow.impl.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.impl.ts"],"names":[],"mappings":";;;AAAA,2CAAuD;AAQvD,0DAAsD;AACtD,gEAA4D;AAE5D,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{"version":3,"file":"queryFlow.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.ts"],"names":[],"mappings":";;;AAAA,yCAA8C;
|
1
|
+
{"version":3,"file":"queryFlow.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlow.ts"],"names":[],"mappings":";;;AAAA,yCAA8C;AAO9C,IAAY,cAEX;AAFD,WAAY,cAAc;IACxB,qCAAmB,CAAA;AACrB,CAAC,EAFW,cAAc,8BAAd,cAAc,QAEzB;AAED,MAAsB,SAAU,SAAQ,wBAGvC;CAgBA;AAnBD,8BAmBC"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { EventDispatcher } from "../../events";
|
2
2
|
import { QueryFlow } from "./queryFlow";
|
3
|
-
import { WorkspaceId } from "../workspaces/workspaces";
|
4
3
|
import { UploadFile } from "../files/files";
|
4
|
+
import { SearchResource } from "../../dto/queryFlowResponse";
|
5
5
|
/**
|
6
6
|
* Query flow id.
|
7
7
|
*/
|
@@ -15,7 +15,7 @@ export declare enum QueryFlowsEvent {
|
|
15
15
|
}
|
16
16
|
export declare abstract class QueryFlows extends EventDispatcher<QueryFlowsEvent, QueryFlow> {
|
17
17
|
abstract getQueryFlows(): Promise<QueryFlow[]>;
|
18
|
-
abstract create(name: string,
|
18
|
+
abstract create(name: string, resources: SearchResource[], table: UploadFile): Promise<FlowId>;
|
19
19
|
abstract delete(id: FlowId): Promise<void>;
|
20
20
|
}
|
21
21
|
//# sourceMappingURL=queryFlows.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlows.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,eAAe,EAAC,MAAM,cAAc,CAAA;AAC5C,OAAO,EAAC,SAAS,EAAC,MAAM,aAAa,CAAA;AACrC,OAAO,EAAC,
|
1
|
+
{"version":3,"file":"queryFlows.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,eAAe,EAAC,MAAM,cAAc,CAAA;AAC5C,OAAO,EAAC,SAAS,EAAC,MAAM,aAAa,CAAA;AACrC,OAAO,EAAC,UAAU,EAAC,MAAM,gBAAgB,CAAA;AACzC,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAA;AAG5D;;GAEG;AACH,MAAM,MAAM,MAAM,GAAG,MAAM,CAAA;AAE3B;;GAEG;AACH,oBAAY,eAAe;IACzB,KAAK,UAAU;IACf,OAAO,YAAY;CACpB;AAED,8BAAsB,UAAW,SAAQ,eAAe,CACtD,eAAe,EACf,SAAS,CACV;IAEC,QAAQ,CAAC,aAAa,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;IAE9C,QAAQ,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,cAAc,EAAE,EAAE,KAAK,EAAE,UAAU,GAAI,OAAO,CAAC,MAAM,CAAC;IAE/F,QAAQ,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAE3C"}
|
@@ -2,7 +2,7 @@ import { Context } from "../../context";
|
|
2
2
|
import { FlowId, QueryFlows } from "./queryFlows";
|
3
3
|
import { QueryFlow } from "./queryFlow";
|
4
4
|
import { OrganizationImpl } from "../organizations/organization.impl";
|
5
|
-
import {
|
5
|
+
import { SearchResource } from "../../dto/queryFlowResponse";
|
6
6
|
import { UploadFile } from "../files/files";
|
7
7
|
export declare class QueryFlowsImpl extends QueryFlows {
|
8
8
|
readonly organization: OrganizationImpl;
|
@@ -13,7 +13,7 @@ export declare class QueryFlowsImpl extends QueryFlows {
|
|
13
13
|
constructor(organization: OrganizationImpl, context: Context);
|
14
14
|
getQueryFlows(): Promise<QueryFlow[]>;
|
15
15
|
internalFetchQueries(): Promise<void>;
|
16
|
-
create(name: string,
|
16
|
+
create(name: string, resources: SearchResource[], table: UploadFile): Promise<FlowId>;
|
17
17
|
delete(id: FlowId): Promise<void>;
|
18
18
|
}
|
19
19
|
//# sourceMappingURL=queryFlows.impl.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlows.impl.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,eAAe,CAAA;AACrC,OAAO,EAAC,MAAM,EAAE,UAAU,EAAkB,MAAM,cAAc,CAAA;AAChE,OAAO,EAAC,SAAS,EAAC,MAAM,aAAa,CAAA;AACrC,OAAO,EAAC,gBAAgB,EAAC,MAAM,oCAAoC,CAAA;AAGnE,OAAO,
|
1
|
+
{"version":3,"file":"queryFlows.impl.d.ts","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,eAAe,CAAA;AACrC,OAAO,EAAC,MAAM,EAAE,UAAU,EAAkB,MAAM,cAAc,CAAA;AAChE,OAAO,EAAC,SAAS,EAAC,MAAM,aAAa,CAAA;AACrC,OAAO,EAAC,gBAAgB,EAAC,MAAM,oCAAoC,CAAA;AAGnE,OAAO,EAIL,cAAc,EACf,MAAM,6BAA6B,CAAA;AAEpC,OAAO,EAAC,UAAU,EAAC,MAAM,gBAAgB,CAAA;AAEzC,qBAAa,cAAe,SAAQ,UAAU;aAS1B,YAAY,EAAE,gBAAgB;aAC9B,OAAO,EAAE,OAAO;IARlC,OAAO,CAAC,WAAW,CAAkB;IAErC,OAAO,CAAC,WAAW,CAAkB;IAErC,OAAO,CAAC,aAAa,CAAC,CAAgB;gBAGpB,YAAY,EAAE,gBAAgB,EAC9B,OAAO,EAAE,OAAO;IAI5B,aAAa,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;IA4CrC,oBAAoB;IAcpB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,cAAc,EAAE,EAAE,KAAK,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC;IA+CrF,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CA4CxC"}
|
@@ -58,13 +58,13 @@ class QueryFlowsImpl extends queryFlows_1.QueryFlows {
|
|
58
58
|
clearTimeout(this._fetchTimeout);
|
59
59
|
}
|
60
60
|
}
|
61
|
-
async create(name,
|
61
|
+
async create(name, resources, table) {
|
62
62
|
var _a;
|
63
63
|
if (name === undefined || name === null || name.trim() === "") {
|
64
64
|
throw new Error("Name is required, must be not empty");
|
65
65
|
}
|
66
|
-
if (
|
67
|
-
throw new Error("
|
66
|
+
if (resources === undefined || resources === null) {
|
67
|
+
throw new Error("Resources is required, must be not empty");
|
68
68
|
}
|
69
69
|
if (table === undefined || table === null) {
|
70
70
|
throw new Error("Create query flow, table is undefined or null");
|
@@ -74,9 +74,7 @@ class QueryFlowsImpl extends queryFlows_1.QueryFlows {
|
|
74
74
|
form.append("organizationId", this.organization.id);
|
75
75
|
form.append("name", name);
|
76
76
|
form.append("tableFile", table, table.name);
|
77
|
-
|
78
|
-
form.append("workspaceIds", item);
|
79
|
-
});
|
77
|
+
form.append("resources", JSON.stringify(resources));
|
80
78
|
// send request to the server
|
81
79
|
const response = await ((_a = this.context
|
82
80
|
.resolve(rpcService_1.RpcService)) === null || _a === void 0 ? void 0 : _a.requestBuilder("api/v1/QueryFlows").sendPostFormData(form));
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queryFlows.impl.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.impl.ts"],"names":[],"mappings":";;;AACA,6CAAgE;AAGhE,0DAAoD;AACpD,gEAA0D;
|
1
|
+
{"version":3,"file":"queryFlows.impl.js","sourceRoot":"","sources":["../../../../src/storages/queryFlows/queryFlows.impl.ts"],"names":[],"mappings":";;;AACA,6CAAgE;AAGhE,0DAAoD;AACpD,gEAA0D;AAC1D,mEAKoC;AACpC,qDAA8C;AAG9C,MAAa,cA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C;YAC9C,MAAM,aAAa,GAAG,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC,CAAA;YACpD,IAAI,aAAa,GAAG,CAAC,EAAE,CAAC;gBACtB,MAAM,IAAI,KAAK,CAAC,cAAc,EAAE,eAAe,CAAC,CAAA;YAClD,CAAC;YACD,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,aAAa,EAAE,CAAC,CAAC,CAAA;QAC3C,CAAC;QAED,iBAAiB;QACjB,IAAI,CAAC,QAAQ,CAAC;YACZ,IAAI,EAAE,4BAAe,CAAC,OAAO;YAC7B,IAAI,EAAE,IAAI;SACX,CAAC,CAAA;IACJ,CAAC;CAEF;AAnKD,wCAmKC"}
|
package/package.json
CHANGED
@@ -4,15 +4,6 @@ export enum QueryFlowState {
|
|
4
4
|
DONE = 100
|
5
5
|
}
|
6
6
|
|
7
|
-
export enum QueryFlowStatus {
|
8
|
-
STARTED = 0,
|
9
|
-
UPLOADING_FILE = 1,
|
10
|
-
PROCESSING_FILE = 2,
|
11
|
-
PREPARING_RESULTS = 3,
|
12
|
-
DONE = 4,
|
13
|
-
FAILED = 5
|
14
|
-
}
|
15
|
-
|
16
7
|
export interface QueryFileUrlDto {
|
17
8
|
name: string
|
18
9
|
extension: string
|
@@ -27,8 +18,10 @@ export interface QueryFlowResult {
|
|
27
18
|
export interface QueryFlowDto {
|
28
19
|
name: string
|
29
20
|
state: QueryFlowState,
|
30
|
-
|
21
|
+
totalRowsCount: number
|
22
|
+
completedRowsCount: number
|
31
23
|
result: QueryFlowResult
|
24
|
+
error: string
|
32
25
|
}
|
33
26
|
|
34
27
|
// GET org query flows
|
@@ -40,3 +33,13 @@ export interface QueryFlowListResponse {
|
|
40
33
|
export interface QueryFlowResponse {
|
41
34
|
flowId: string
|
42
35
|
}
|
36
|
+
|
37
|
+
export class SearchResource {
|
38
|
+
organizationId: string
|
39
|
+
workspaceIds: string[]
|
40
|
+
|
41
|
+
constructor(organizationId: string, workspaceIds: string[]){
|
42
|
+
this.organizationId = organizationId
|
43
|
+
this.workspaceIds = workspaceIds
|
44
|
+
}
|
45
|
+
}
|
@@ -79,9 +79,10 @@ export class ChatbotAccountsImpl extends ChatbotAccounts {
|
|
79
79
|
organizationId: this.organization.id,
|
80
80
|
accountType: type,
|
81
81
|
name: name,
|
82
|
-
token: token,
|
83
82
|
accountId: accountId,
|
83
|
+
token: token,
|
84
84
|
context: accountContext,
|
85
|
+
notificationDelays: notificationDelays,
|
85
86
|
data: data
|
86
87
|
})
|
87
88
|
|
@@ -2,8 +2,7 @@ import { QueryFlow, QueryFlowEvent } from "./queryFlow"
|
|
2
2
|
import {
|
3
3
|
QueryFileUrlDto,
|
4
4
|
QueryFlowDto,
|
5
|
-
QueryFlowState
|
6
|
-
QueryFlowStatus
|
5
|
+
QueryFlowState
|
7
6
|
} from "../../dto/queryFlowResponse"
|
8
7
|
import { FlowId } from "./queryFlows"
|
9
8
|
import { Context } from "../../context"
|
@@ -65,6 +64,22 @@ export class QueryFlowImpl extends QueryFlow {
|
|
65
64
|
}
|
66
65
|
}
|
67
66
|
|
67
|
+
get error(): string {
|
68
|
+
if (this._content) {
|
69
|
+
return this._content.error
|
70
|
+
} else {
|
71
|
+
throw new Error("Query flow is not loaded")
|
72
|
+
}
|
73
|
+
}
|
74
|
+
|
75
|
+
get progress(): number {
|
76
|
+
if (this._content) {
|
77
|
+
return this._content.completedRowsCount / this._content.totalRowsCount
|
78
|
+
} else {
|
79
|
+
throw new Error("Query flow is not loaded")
|
80
|
+
}
|
81
|
+
}
|
82
|
+
|
68
83
|
get urls(): QueryFileUrlDto[] | undefined {
|
69
84
|
if (this._content && this._content.result.files) {
|
70
85
|
return this._content.result.files
|
@@ -81,12 +96,5 @@ export class QueryFlowImpl extends QueryFlow {
|
|
81
96
|
}
|
82
97
|
}
|
83
98
|
|
84
|
-
get status(): QueryFlowStatus {
|
85
|
-
if (this._content) {
|
86
|
-
return this._content.status
|
87
|
-
} else {
|
88
|
-
throw new Error("Query fLow is not loaded")
|
89
|
-
}
|
90
|
-
}
|
91
99
|
|
92
100
|
}
|
@@ -2,8 +2,7 @@ import { EventDispatcher } from "../../events"
|
|
2
2
|
import { FlowId } from "./queryFlows"
|
3
3
|
import {
|
4
4
|
QueryFileUrlDto,
|
5
|
-
QueryFlowState
|
6
|
-
QueryFlowStatus
|
5
|
+
QueryFlowState
|
7
6
|
} from "../../dto/queryFlowResponse"
|
8
7
|
|
9
8
|
export enum QueryFlowEvent {
|
@@ -21,7 +20,9 @@ export abstract class QueryFlow extends EventDispatcher<
|
|
21
20
|
|
22
21
|
abstract get state(): QueryFlowState
|
23
22
|
|
24
|
-
abstract get
|
23
|
+
abstract get error(): string
|
24
|
+
|
25
|
+
abstract get progress(): number
|
25
26
|
|
26
27
|
abstract get urls(): QueryFileUrlDto[] | undefined
|
27
28
|
|
@@ -4,11 +4,11 @@ import {QueryFlow} from "./queryFlow"
|
|
4
4
|
import {OrganizationImpl} from "../organizations/organization.impl"
|
5
5
|
import {RpcService} from "../../services/rpcService"
|
6
6
|
import {ResponseUtils} from "../../services/responseUtils"
|
7
|
-
import {WorkspaceId} from "../workspaces/workspaces"
|
8
7
|
import {
|
9
8
|
QueryFlowListResponse,
|
10
9
|
QueryFlowResponse,
|
11
|
-
QueryFlowState
|
10
|
+
QueryFlowState,
|
11
|
+
SearchResource
|
12
12
|
} from "../../dto/queryFlowResponse"
|
13
13
|
import {QueryFlowImpl} from "./queryFlow.impl"
|
14
14
|
import {UploadFile} from "../files/files"
|
@@ -85,12 +85,12 @@ export class QueryFlowsImpl extends QueryFlows {
|
|
85
85
|
}
|
86
86
|
}
|
87
87
|
|
88
|
-
async create(name: string,
|
88
|
+
async create(name: string, resources: SearchResource[], table: UploadFile): Promise<FlowId> {
|
89
89
|
if (name === undefined || name === null || name.trim() === "") {
|
90
90
|
throw new Error("Name is required, must be not empty")
|
91
91
|
}
|
92
|
-
if (
|
93
|
-
throw new Error("
|
92
|
+
if (resources === undefined || resources === null) {
|
93
|
+
throw new Error("Resources is required, must be not empty")
|
94
94
|
}
|
95
95
|
if (table === undefined || table === null) {
|
96
96
|
throw new Error("Create query flow, table is undefined or null")
|
@@ -101,9 +101,7 @@ export class QueryFlowsImpl extends QueryFlows {
|
|
101
101
|
form.append("organizationId", this.organization.id)
|
102
102
|
form.append("name", name)
|
103
103
|
form.append("tableFile", table, table.name)
|
104
|
-
|
105
|
-
form.append("workspaceIds", item)
|
106
|
-
})
|
104
|
+
form.append("resources", JSON.stringify(resources))
|
107
105
|
|
108
106
|
// send request to the server
|
109
107
|
const response = await this.context
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import {EventDispatcher} from "../../events"
|
2
2
|
import {QueryFlow} from "./queryFlow"
|
3
|
-
import {WorkspaceId} from "../workspaces/workspaces"
|
4
3
|
import {UploadFile} from "../files/files"
|
4
|
+
import { SearchResource } from "../../dto/queryFlowResponse"
|
5
5
|
|
6
6
|
|
7
7
|
/**
|
@@ -24,7 +24,7 @@ export abstract class QueryFlows extends EventDispatcher<
|
|
24
24
|
|
25
25
|
abstract getQueryFlows(): Promise<QueryFlow[]>
|
26
26
|
|
27
|
-
abstract create(name: string,
|
27
|
+
abstract create(name: string, resources: SearchResource[], table: UploadFile ): Promise<FlowId>
|
28
28
|
|
29
29
|
abstract delete(id: FlowId): Promise<void>
|
30
30
|
|