namirasoft-expert 1.4.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.
- package/dist/NamirasoftExpertServer.d.ts +23 -0
- package/dist/NamirasoftExpertServer.js +30 -0
- package/dist/NamirasoftExpertServer.js.map +1 -0
- package/dist/NamirasoftExpertServerAgent.d.ts +18 -0
- package/dist/NamirasoftExpertServerAgent.js +64 -0
- package/dist/NamirasoftExpertServerAgent.js.map +1 -0
- package/dist/NamirasoftExpertServerAgentCategory.d.ts +17 -0
- package/dist/NamirasoftExpertServerAgentCategory.js +56 -0
- package/dist/NamirasoftExpertServerAgentCategory.js.map +1 -0
- package/dist/NamirasoftExpertServerAgentField.d.ts +18 -0
- package/dist/NamirasoftExpertServerAgentField.js +64 -0
- package/dist/NamirasoftExpertServerAgentField.js.map +1 -0
- package/dist/NamirasoftExpertServerAgentTag.d.ts +18 -0
- package/dist/NamirasoftExpertServerAgentTag.js +64 -0
- package/dist/NamirasoftExpertServerAgentTag.js.map +1 -0
- package/dist/NamirasoftExpertServerBase.d.ts +5 -0
- package/dist/NamirasoftExpertServerBase.js +11 -0
- package/dist/NamirasoftExpertServerBase.js.map +1 -0
- package/dist/NamirasoftExpertServerChat.d.ts +14 -0
- package/dist/NamirasoftExpertServerChat.js +41 -0
- package/dist/NamirasoftExpertServerChat.js.map +1 -0
- package/dist/NamirasoftExpertServerHealth.d.ts +8 -0
- package/dist/NamirasoftExpertServerHealth.js +35 -0
- package/dist/NamirasoftExpertServerHealth.js.map +1 -0
- package/dist/NamirasoftExpertServerHealthz.d.ts +7 -0
- package/dist/NamirasoftExpertServerHealthz.js +28 -0
- package/dist/NamirasoftExpertServerHealthz.js.map +1 -0
- package/dist/NamirasoftExpertServerMetrics.d.ts +7 -0
- package/dist/NamirasoftExpertServerMetrics.js +28 -0
- package/dist/NamirasoftExpertServerMetrics.js.map +1 -0
- package/dist/NamirasoftExpertServerValue.d.ts +7 -0
- package/dist/NamirasoftExpertServerValue.js +29 -0
- package/dist/NamirasoftExpertServerValue.js.map +1 -0
- package/dist/command/AgentCategoryCommand.d.ts +4 -0
- package/dist/command/AgentCategoryCommand.js +21 -0
- package/dist/command/AgentCategoryCommand.js.map +1 -0
- package/dist/command/AgentCategoryCreateCommand.d.ts +5 -0
- package/dist/command/AgentCategoryCreateCommand.js +58 -0
- package/dist/command/AgentCategoryCreateCommand.js.map +1 -0
- package/dist/command/AgentCategoryDeleteCommand.d.ts +5 -0
- package/dist/command/AgentCategoryDeleteCommand.js +38 -0
- package/dist/command/AgentCategoryDeleteCommand.js.map +1 -0
- package/dist/command/AgentCategoryGetCommand.d.ts +5 -0
- package/dist/command/AgentCategoryGetCommand.js +38 -0
- package/dist/command/AgentCategoryGetCommand.js.map +1 -0
- package/dist/command/AgentCategoryListCommand.d.ts +5 -0
- package/dist/command/AgentCategoryListCommand.js +38 -0
- package/dist/command/AgentCategoryListCommand.js.map +1 -0
- package/dist/command/AgentCommand.d.ts +4 -0
- package/dist/command/AgentCommand.js +23 -0
- package/dist/command/AgentCommand.js.map +1 -0
- package/dist/command/AgentCreateCommand.d.ts +5 -0
- package/dist/command/AgentCreateCommand.js +148 -0
- package/dist/command/AgentCreateCommand.js.map +1 -0
- package/dist/command/AgentDeleteCommand.d.ts +5 -0
- package/dist/command/AgentDeleteCommand.js +38 -0
- package/dist/command/AgentDeleteCommand.js.map +1 -0
- package/dist/command/AgentFieldCommand.d.ts +4 -0
- package/dist/command/AgentFieldCommand.js +23 -0
- package/dist/command/AgentFieldCommand.js.map +1 -0
- package/dist/command/AgentFieldCreateCommand.d.ts +5 -0
- package/dist/command/AgentFieldCreateCommand.js +67 -0
- package/dist/command/AgentFieldCreateCommand.js.map +1 -0
- package/dist/command/AgentFieldDeleteCommand.d.ts +5 -0
- package/dist/command/AgentFieldDeleteCommand.js +38 -0
- package/dist/command/AgentFieldDeleteCommand.js.map +1 -0
- package/dist/command/AgentFieldGetCommand.d.ts +5 -0
- package/dist/command/AgentFieldGetCommand.js +38 -0
- package/dist/command/AgentFieldGetCommand.js.map +1 -0
- package/dist/command/AgentFieldListCommand.d.ts +5 -0
- package/dist/command/AgentFieldListCommand.js +38 -0
- package/dist/command/AgentFieldListCommand.js.map +1 -0
- package/dist/command/AgentFieldUpdateCommand.d.ts +5 -0
- package/dist/command/AgentFieldUpdateCommand.js +67 -0
- package/dist/command/AgentFieldUpdateCommand.js.map +1 -0
- package/dist/command/AgentGetCommand.d.ts +5 -0
- package/dist/command/AgentGetCommand.js +38 -0
- package/dist/command/AgentGetCommand.js.map +1 -0
- package/dist/command/AgentListCommand.d.ts +5 -0
- package/dist/command/AgentListCommand.js +38 -0
- package/dist/command/AgentListCommand.js.map +1 -0
- package/dist/command/AgentTagCommand.d.ts +4 -0
- package/dist/command/AgentTagCommand.js +23 -0
- package/dist/command/AgentTagCommand.js.map +1 -0
- package/dist/command/AgentTagCreateCommand.d.ts +5 -0
- package/dist/command/AgentTagCreateCommand.js +67 -0
- package/dist/command/AgentTagCreateCommand.js.map +1 -0
- package/dist/command/AgentTagDeleteCommand.d.ts +5 -0
- package/dist/command/AgentTagDeleteCommand.js +38 -0
- package/dist/command/AgentTagDeleteCommand.js.map +1 -0
- package/dist/command/AgentTagGetCommand.d.ts +5 -0
- package/dist/command/AgentTagGetCommand.js +38 -0
- package/dist/command/AgentTagGetCommand.js.map +1 -0
- package/dist/command/AgentTagListCommand.d.ts +5 -0
- package/dist/command/AgentTagListCommand.js +38 -0
- package/dist/command/AgentTagListCommand.js.map +1 -0
- package/dist/command/AgentTagUpdateCommand.d.ts +5 -0
- package/dist/command/AgentTagUpdateCommand.js +67 -0
- package/dist/command/AgentTagUpdateCommand.js.map +1 -0
- package/dist/command/AgentUpdateCommand.d.ts +5 -0
- package/dist/command/AgentUpdateCommand.js +148 -0
- package/dist/command/AgentUpdateCommand.js.map +1 -0
- package/dist/command/ChatCommand.d.ts +4 -0
- package/dist/command/ChatCommand.js +17 -0
- package/dist/command/ChatCommand.js.map +1 -0
- package/dist/command/ChatGetCommand.d.ts +5 -0
- package/dist/command/ChatGetCommand.js +38 -0
- package/dist/command/ChatGetCommand.js.map +1 -0
- package/dist/command/ChatListCommand.d.ts +5 -0
- package/dist/command/ChatListCommand.js +38 -0
- package/dist/command/ChatListCommand.js.map +1 -0
- package/dist/command/HealthCommand.d.ts +4 -0
- package/dist/command/HealthCommand.js +17 -0
- package/dist/command/HealthCommand.js.map +1 -0
- package/dist/command/HealthLivenessCommand.d.ts +5 -0
- package/dist/command/HealthLivenessCommand.js +38 -0
- package/dist/command/HealthLivenessCommand.js.map +1 -0
- package/dist/command/HealthReadinessCommand.d.ts +5 -0
- package/dist/command/HealthReadinessCommand.js +38 -0
- package/dist/command/HealthReadinessCommand.js.map +1 -0
- package/dist/command/HealthzCommand.d.ts +4 -0
- package/dist/command/HealthzCommand.js +15 -0
- package/dist/command/HealthzCommand.js.map +1 -0
- package/dist/command/HealthzGetCommand.d.ts +5 -0
- package/dist/command/HealthzGetCommand.js +38 -0
- package/dist/command/HealthzGetCommand.js.map +1 -0
- package/dist/command/MetricsCommand.d.ts +4 -0
- package/dist/command/MetricsCommand.js +15 -0
- package/dist/command/MetricsCommand.js.map +1 -0
- package/dist/command/MetricsGetCommand.d.ts +5 -0
- package/dist/command/MetricsGetCommand.js +38 -0
- package/dist/command/MetricsGetCommand.js.map +1 -0
- package/dist/command/ValueCommand.d.ts +4 -0
- package/dist/command/ValueCommand.js +15 -0
- package/dist/command/ValueCommand.js.map +1 -0
- package/dist/command/ValueListCommand.d.ts +5 -0
- package/dist/command/ValueListCommand.js +38 -0
- package/dist/command/ValueListCommand.js.map +1 -0
- package/dist/command/cli.d.ts +2 -0
- package/dist/command/cli.js +30 -0
- package/dist/command/cli.js.map +1 -0
- package/dist/enum/ChatType.d.ts +6 -0
- package/dist/enum/ChatType.js +11 -0
- package/dist/enum/ChatType.js.map +1 -0
- package/dist/index.d.ts +62 -0
- package/dist/index.js +79 -0
- package/dist/index.js.map +1 -0
- package/dist/meta/AgentCategoryMetaTable.d.ts +15 -0
- package/dist/meta/AgentCategoryMetaTable.js +39 -0
- package/dist/meta/AgentCategoryMetaTable.js.map +1 -0
- package/dist/meta/AgentFieldMetaTable.d.ts +16 -0
- package/dist/meta/AgentFieldMetaTable.js +39 -0
- package/dist/meta/AgentFieldMetaTable.js.map +1 -0
- package/dist/meta/AgentMetaTable.d.ts +25 -0
- package/dist/meta/AgentMetaTable.js +48 -0
- package/dist/meta/AgentMetaTable.js.map +1 -0
- package/dist/meta/AgentTagMetaTable.d.ts +16 -0
- package/dist/meta/AgentTagMetaTable.js +39 -0
- package/dist/meta/AgentTagMetaTable.js.map +1 -0
- package/dist/meta/ChatMetaTable.d.ts +19 -0
- package/dist/meta/ChatMetaTable.js +44 -0
- package/dist/meta/ChatMetaTable.js.map +1 -0
- package/dist/meta/NamirasoftExpertMetaDatabase.d.ts +21 -0
- package/dist/meta/NamirasoftExpertMetaDatabase.js +35 -0
- package/dist/meta/NamirasoftExpertMetaDatabase.js.map +1 -0
- package/dist/row/AgentCategoryRow.d.ts +8 -0
- package/dist/row/AgentCategoryRow.js +3 -0
- package/dist/row/AgentCategoryRow.js.map +1 -0
- package/dist/row/AgentFieldRow.d.ts +9 -0
- package/dist/row/AgentFieldRow.js +3 -0
- package/dist/row/AgentFieldRow.js.map +1 -0
- package/dist/row/AgentInputRow.d.ts +14 -0
- package/dist/row/AgentInputRow.js +3 -0
- package/dist/row/AgentInputRow.js.map +1 -0
- package/dist/row/AgentRow.d.ts +18 -0
- package/dist/row/AgentRow.js +3 -0
- package/dist/row/AgentRow.js.map +1 -0
- package/dist/row/AgentTagRow.d.ts +9 -0
- package/dist/row/AgentTagRow.js +3 -0
- package/dist/row/AgentTagRow.js.map +1 -0
- package/dist/row/ChatRow.d.ts +13 -0
- package/dist/row/ChatRow.js +3 -0
- package/dist/row/ChatRow.js.map +1 -0
- package/dist/row/EntityCategoryInputRow.d.ts +4 -0
- package/dist/row/EntityCategoryInputRow.js +3 -0
- package/dist/row/EntityCategoryInputRow.js.map +1 -0
- package/dist/row/EntityFieldInputRow.d.ts +5 -0
- package/dist/row/EntityFieldInputRow.js +3 -0
- package/dist/row/EntityFieldInputRow.js.map +1 -0
- package/dist/row/EntityTagInputRow.d.ts +5 -0
- package/dist/row/EntityTagInputRow.js +3 -0
- package/dist/row/EntityTagInputRow.js.map +1 -0
- package/logo.png +0 -0
- package/package.json +28 -0
- package/src/NamirasoftExpertServer.ts +57 -0
- package/src/NamirasoftExpertServerAgent.ts +71 -0
- package/src/NamirasoftExpertServerAgentCategory.ts +64 -0
- package/src/NamirasoftExpertServerAgentField.ts +71 -0
- package/src/NamirasoftExpertServerAgentTag.ts +71 -0
- package/src/NamirasoftExpertServerBase.ts +30 -0
- package/src/NamirasoftExpertServerChat.ts +50 -0
- package/src/NamirasoftExpertServerHealth.ts +43 -0
- package/src/NamirasoftExpertServerHealthz.ts +37 -0
- package/src/NamirasoftExpertServerMetrics.ts +37 -0
- package/src/NamirasoftExpertServerValue.ts +38 -0
- package/src/command/AgentCategoryCommand.ts +38 -0
- package/src/command/AgentCategoryCreateCommand.ts +65 -0
- package/src/command/AgentCategoryDeleteCommand.ts +45 -0
- package/src/command/AgentCategoryGetCommand.ts +45 -0
- package/src/command/AgentCategoryListCommand.ts +45 -0
- package/src/command/AgentCommand.ts +40 -0
- package/src/command/AgentCreateCommand.ts +155 -0
- package/src/command/AgentDeleteCommand.ts +45 -0
- package/src/command/AgentFieldCommand.ts +40 -0
- package/src/command/AgentFieldCreateCommand.ts +74 -0
- package/src/command/AgentFieldDeleteCommand.ts +45 -0
- package/src/command/AgentFieldGetCommand.ts +45 -0
- package/src/command/AgentFieldListCommand.ts +45 -0
- package/src/command/AgentFieldUpdateCommand.ts +74 -0
- package/src/command/AgentGetCommand.ts +45 -0
- package/src/command/AgentListCommand.ts +45 -0
- package/src/command/AgentTagCommand.ts +40 -0
- package/src/command/AgentTagCreateCommand.ts +74 -0
- package/src/command/AgentTagDeleteCommand.ts +45 -0
- package/src/command/AgentTagGetCommand.ts +45 -0
- package/src/command/AgentTagListCommand.ts +45 -0
- package/src/command/AgentTagUpdateCommand.ts +74 -0
- package/src/command/AgentUpdateCommand.ts +155 -0
- package/src/command/ChatCommand.ts +34 -0
- package/src/command/ChatGetCommand.ts +45 -0
- package/src/command/ChatListCommand.ts +45 -0
- package/src/command/HealthCommand.ts +34 -0
- package/src/command/HealthLivenessCommand.ts +45 -0
- package/src/command/HealthReadinessCommand.ts +45 -0
- package/src/command/HealthzCommand.ts +32 -0
- package/src/command/HealthzGetCommand.ts +45 -0
- package/src/command/MetricsCommand.ts +32 -0
- package/src/command/MetricsGetCommand.ts +45 -0
- package/src/command/ValueCommand.ts +32 -0
- package/src/command/ValueListCommand.ts +45 -0
- package/src/command/cli.ts +49 -0
- package/src/enum/ChatType.ts +27 -0
- package/src/index.ts +82 -0
- package/src/meta/AgentCategoryMetaTable.ts +60 -0
- package/src/meta/AgentFieldMetaTable.ts +61 -0
- package/src/meta/AgentMetaTable.ts +79 -0
- package/src/meta/AgentTagMetaTable.ts +61 -0
- package/src/meta/ChatMetaTable.ts +69 -0
- package/src/meta/NamirasoftExpertMetaDatabase.ts +63 -0
- package/src/row/AgentCategoryRow.ts +29 -0
- package/src/row/AgentFieldRow.ts +30 -0
- package/src/row/AgentInputRow.ts +35 -0
- package/src/row/AgentRow.ts +39 -0
- package/src/row/AgentTagRow.ts +30 -0
- package/src/row/ChatRow.ts +35 -0
- package/src/row/EntityCategoryInputRow.ts +25 -0
- package/src/row/EntityFieldInputRow.ts +26 -0
- package/src/row/EntityTagInputRow.ts +26 -0
- package/tsconfig.json +42 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemoryDedicated } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class HealthLivenessCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, [], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-expert account config \nor \nns-expert account login.");
|
|
37
|
+
let storage = new IStorageMemoryDedicated();
|
|
38
|
+
let token_manager = new TokenManager(storage, () => { });
|
|
39
|
+
token_manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-expert-server-url");
|
|
41
|
+
let server = new NamirasoftExpertServer(url, token_manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.health.Liveness();
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemoryDedicated } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class HealthReadinessCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, [], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-expert account config \nor \nns-expert account login.");
|
|
37
|
+
let storage = new IStorageMemoryDedicated();
|
|
38
|
+
let token_manager = new TokenManager(storage, () => { });
|
|
39
|
+
token_manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-expert-server-url");
|
|
41
|
+
let server = new NamirasoftExpertServer(url, token_manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.health.Readiness();
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseNavigatorCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { HealthzGetCommand } from "./HealthzGetCommand";
|
|
23
|
+
|
|
24
|
+
export class HealthzCommand extends BaseNavigatorCommand
|
|
25
|
+
{
|
|
26
|
+
constructor(argv: string[])
|
|
27
|
+
{
|
|
28
|
+
super(argv, {
|
|
29
|
+
"get": HealthzGetCommand,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemoryDedicated } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class HealthzGetCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, [], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-expert account config \nor \nns-expert account login.");
|
|
37
|
+
let storage = new IStorageMemoryDedicated();
|
|
38
|
+
let token_manager = new TokenManager(storage, () => { });
|
|
39
|
+
token_manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-expert-server-url");
|
|
41
|
+
let server = new NamirasoftExpertServer(url, token_manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.healthz.Get();
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseNavigatorCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { MetricsGetCommand } from "./MetricsGetCommand";
|
|
23
|
+
|
|
24
|
+
export class MetricsCommand extends BaseNavigatorCommand
|
|
25
|
+
{
|
|
26
|
+
constructor(argv: string[])
|
|
27
|
+
{
|
|
28
|
+
super(argv, {
|
|
29
|
+
"get": MetricsGetCommand,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemoryDedicated } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class MetricsGetCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, [], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-expert account config \nor \nns-expert account login.");
|
|
37
|
+
let storage = new IStorageMemoryDedicated();
|
|
38
|
+
let token_manager = new TokenManager(storage, () => { });
|
|
39
|
+
token_manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-expert-server-url");
|
|
41
|
+
let server = new NamirasoftExpertServer(url, token_manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.metrics.Get();
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseNavigatorCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { ValueListCommand } from "./ValueListCommand";
|
|
23
|
+
|
|
24
|
+
export class ValueCommand extends BaseNavigatorCommand
|
|
25
|
+
{
|
|
26
|
+
constructor(argv: string[])
|
|
27
|
+
{
|
|
28
|
+
super(argv, {
|
|
29
|
+
"list": ValueListCommand,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { BaseFinalCommand } from "namirasoft-node-cli";
|
|
22
|
+
import { IStorageMemoryDedicated } from "namirasoft-core";
|
|
23
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
24
|
+
import { TokenManager } from "namirasoft-account";
|
|
25
|
+
|
|
26
|
+
export class ValueListCommand extends BaseFinalCommand
|
|
27
|
+
{
|
|
28
|
+
constructor(argv: string[])
|
|
29
|
+
{
|
|
30
|
+
super(argv, ["table", "column", "search", "field_id", "limit"], []);
|
|
31
|
+
}
|
|
32
|
+
override async exec()
|
|
33
|
+
{
|
|
34
|
+
let token = this.app.storage.getNSAToken();
|
|
35
|
+
if (token == null)
|
|
36
|
+
throw new Error("Token is not available. Please login first using:\nns-expert account config \nor \nns-expert account login.");
|
|
37
|
+
let storage = new IStorageMemoryDedicated();
|
|
38
|
+
let token_manager = new TokenManager(storage, () => { });
|
|
39
|
+
token_manager.setValue(token, false);
|
|
40
|
+
let url = this.app.storage.getItem("ns-expert-server-url");
|
|
41
|
+
let server = new NamirasoftExpertServer(url, token_manager, e => this.app.logger.error(e.message));
|
|
42
|
+
let ans = await server.value.List(this.arg_values[0], this.arg_values[1], this.arg_values[2], this.arg_values[3], this.arg_values[4]);
|
|
43
|
+
this.app.logger.success(JSON.stringify(ans));
|
|
44
|
+
}
|
|
45
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/****************************************************************/
|
|
3
|
+
/* */
|
|
4
|
+
/* This is an Auto-Generated File */
|
|
5
|
+
/* Made By */
|
|
6
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
7
|
+
/* */
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/****************************************************************/
|
|
10
|
+
/* */
|
|
11
|
+
/* Please do not make any change to this file */
|
|
12
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
13
|
+
/* */
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/****************************************************************/
|
|
16
|
+
/* */
|
|
17
|
+
/* Namira Software Corporation */
|
|
18
|
+
/* https://namirasoft.com */
|
|
19
|
+
/* */
|
|
20
|
+
/****************************************************************/
|
|
21
|
+
|
|
22
|
+
import { AccountCommand } from "namirasoft-account";
|
|
23
|
+
import { AgentCategoryCommand } from "./AgentCategoryCommand";
|
|
24
|
+
import { AgentCommand } from "./AgentCommand";
|
|
25
|
+
import { AgentFieldCommand } from "./AgentFieldCommand";
|
|
26
|
+
import { AgentTagCommand } from "./AgentTagCommand";
|
|
27
|
+
import { Application, BaseStorage } from "namirasoft-node-cli";
|
|
28
|
+
import { ChatCommand } from "./ChatCommand";
|
|
29
|
+
import { ConfigCommand } from "namirasoft-node-cli";
|
|
30
|
+
import { HealthCommand } from "./HealthCommand";
|
|
31
|
+
import { HealthzCommand } from "./HealthzCommand";
|
|
32
|
+
import { MetricsCommand } from "./MetricsCommand";
|
|
33
|
+
import { ValueCommand } from "./ValueCommand";
|
|
34
|
+
|
|
35
|
+
let app = new Application("ns-expert", new BaseStorage(),
|
|
36
|
+
{
|
|
37
|
+
"healthz": HealthzCommand,
|
|
38
|
+
"health": HealthCommand,
|
|
39
|
+
"metrics": MetricsCommand,
|
|
40
|
+
"value": ValueCommand,
|
|
41
|
+
"agentcategory": AgentCategoryCommand,
|
|
42
|
+
"agentfield": AgentFieldCommand,
|
|
43
|
+
"agenttag": AgentTagCommand,
|
|
44
|
+
"agent": AgentCommand,
|
|
45
|
+
"chat": ChatCommand,
|
|
46
|
+
"account": AccountCommand,
|
|
47
|
+
"config": (argv: string[]) => new ConfigCommand(argv, ["ns-expert-server-url"])
|
|
48
|
+
});
|
|
49
|
+
app.run();
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
export enum ChatType
|
|
22
|
+
{
|
|
23
|
+
DescriptionWriter = "DescriptionWriter",
|
|
24
|
+
RoleGenerator = "RoleGenerator",
|
|
25
|
+
RoleAssigner = "RoleAssigner",
|
|
26
|
+
IncidentAnalyzer = "IncidentAnalyzer",
|
|
27
|
+
}
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
export * from "./NamirasoftExpertServer";
|
|
22
|
+
export * from "./NamirasoftExpertServerAgent";
|
|
23
|
+
export * from "./NamirasoftExpertServerAgentCategory";
|
|
24
|
+
export * from "./NamirasoftExpertServerAgentField";
|
|
25
|
+
export * from "./NamirasoftExpertServerAgentTag";
|
|
26
|
+
export * from "./NamirasoftExpertServerBase";
|
|
27
|
+
export * from "./NamirasoftExpertServerChat";
|
|
28
|
+
export * from "./NamirasoftExpertServerHealth";
|
|
29
|
+
export * from "./NamirasoftExpertServerHealthz";
|
|
30
|
+
export * from "./NamirasoftExpertServerMetrics";
|
|
31
|
+
export * from "./NamirasoftExpertServerValue";
|
|
32
|
+
export * from "./command/AgentCategoryCommand";
|
|
33
|
+
export * from "./command/AgentCategoryCreateCommand";
|
|
34
|
+
export * from "./command/AgentCategoryDeleteCommand";
|
|
35
|
+
export * from "./command/AgentCategoryGetCommand";
|
|
36
|
+
export * from "./command/AgentCategoryListCommand";
|
|
37
|
+
export * from "./command/AgentCommand";
|
|
38
|
+
export * from "./command/AgentCreateCommand";
|
|
39
|
+
export * from "./command/AgentDeleteCommand";
|
|
40
|
+
export * from "./command/AgentFieldCommand";
|
|
41
|
+
export * from "./command/AgentFieldCreateCommand";
|
|
42
|
+
export * from "./command/AgentFieldDeleteCommand";
|
|
43
|
+
export * from "./command/AgentFieldGetCommand";
|
|
44
|
+
export * from "./command/AgentFieldListCommand";
|
|
45
|
+
export * from "./command/AgentFieldUpdateCommand";
|
|
46
|
+
export * from "./command/AgentGetCommand";
|
|
47
|
+
export * from "./command/AgentListCommand";
|
|
48
|
+
export * from "./command/AgentTagCommand";
|
|
49
|
+
export * from "./command/AgentTagCreateCommand";
|
|
50
|
+
export * from "./command/AgentTagDeleteCommand";
|
|
51
|
+
export * from "./command/AgentTagGetCommand";
|
|
52
|
+
export * from "./command/AgentTagListCommand";
|
|
53
|
+
export * from "./command/AgentTagUpdateCommand";
|
|
54
|
+
export * from "./command/AgentUpdateCommand";
|
|
55
|
+
export * from "./command/ChatCommand";
|
|
56
|
+
export * from "./command/ChatGetCommand";
|
|
57
|
+
export * from "./command/ChatListCommand";
|
|
58
|
+
export * from "./command/HealthCommand";
|
|
59
|
+
export * from "./command/HealthLivenessCommand";
|
|
60
|
+
export * from "./command/HealthReadinessCommand";
|
|
61
|
+
export * from "./command/HealthzCommand";
|
|
62
|
+
export * from "./command/HealthzGetCommand";
|
|
63
|
+
export * from "./command/MetricsCommand";
|
|
64
|
+
export * from "./command/MetricsGetCommand";
|
|
65
|
+
export * from "./command/ValueCommand";
|
|
66
|
+
export * from "./command/ValueListCommand";
|
|
67
|
+
export * from "./enum/ChatType";
|
|
68
|
+
export * from "./meta/AgentCategoryMetaTable";
|
|
69
|
+
export * from "./meta/AgentFieldMetaTable";
|
|
70
|
+
export * from "./meta/AgentMetaTable";
|
|
71
|
+
export * from "./meta/AgentTagMetaTable";
|
|
72
|
+
export * from "./meta/ChatMetaTable";
|
|
73
|
+
export * from "./meta/NamirasoftExpertMetaDatabase";
|
|
74
|
+
export * from "./row/AgentCategoryRow";
|
|
75
|
+
export * from "./row/AgentFieldRow";
|
|
76
|
+
export * from "./row/AgentInputRow";
|
|
77
|
+
export * from "./row/AgentRow";
|
|
78
|
+
export * from "./row/AgentTagRow";
|
|
79
|
+
export * from "./row/ChatRow";
|
|
80
|
+
export * from "./row/EntityCategoryInputRow";
|
|
81
|
+
export * from "./row/EntityFieldInputRow";
|
|
82
|
+
export * from "./row/EntityTagInputRow";
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { AgentCategoryRow } from "../row/AgentCategoryRow";
|
|
22
|
+
import { BaseUUID, BaseMetaColumn } from "namirasoft-core";
|
|
23
|
+
import { FilterItem, SortItem } from "namirasoft-core";
|
|
24
|
+
import { NSBaseMetaDatabase, NSBaseMetaTable } from "namirasoft-site";
|
|
25
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
26
|
+
|
|
27
|
+
export class AgentCategoryMetaTable extends NSBaseMetaTable<NamirasoftExpertServer, AgentCategoryRow>
|
|
28
|
+
{
|
|
29
|
+
public override columns: {
|
|
30
|
+
id: BaseMetaColumn;
|
|
31
|
+
user_id: BaseMetaColumn;
|
|
32
|
+
entity_id: BaseMetaColumn;
|
|
33
|
+
category_id: BaseMetaColumn;
|
|
34
|
+
created_at: BaseMetaColumn;
|
|
35
|
+
updated_at: BaseMetaColumn;
|
|
36
|
+
}
|
|
37
|
+
constructor(database: NSBaseMetaDatabase<NamirasoftExpertServer>)
|
|
38
|
+
{
|
|
39
|
+
super(database, "agent_category", "Agent Category", new BaseUUID(""));
|
|
40
|
+
this.columns = {
|
|
41
|
+
id: new BaseMetaColumn(this, "id", "ID", "Integer", true),
|
|
42
|
+
user_id: new BaseMetaColumn(this, "user_id", "User ID", "String", true),
|
|
43
|
+
entity_id: new BaseMetaColumn(this, "entity_id", "Entity ID", "String", true),
|
|
44
|
+
category_id: new BaseMetaColumn(this, "category_id", "Category ID", "String", true),
|
|
45
|
+
created_at: new BaseMetaColumn(this, "created_at", "Created At", "DateTime", true),
|
|
46
|
+
updated_at: new BaseMetaColumn(this, "updated_at", "Updated At", "DateTime", true),
|
|
47
|
+
};
|
|
48
|
+
this.back_end.get = async (id: string) =>
|
|
49
|
+
{
|
|
50
|
+
let server = this.database.getServer();
|
|
51
|
+
return await server.agent_category.Get(id);
|
|
52
|
+
};
|
|
53
|
+
this.back_end.list = async (filters: FilterItem[] | null, page: (number | null), size: (number | null), sorts: SortItem[]) =>
|
|
54
|
+
{
|
|
55
|
+
let server = this.database.getServer();
|
|
56
|
+
return await server.agent_category.List(filters, page, size, sorts);
|
|
57
|
+
};
|
|
58
|
+
this.front_end.getUpdateLink = () => "";
|
|
59
|
+
}
|
|
60
|
+
};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/****************************************************************/
|
|
2
|
+
/* */
|
|
3
|
+
/* This is an Auto-Generated File */
|
|
4
|
+
/* Made By */
|
|
5
|
+
/* Namirasoft SDK Generator NPM Package */
|
|
6
|
+
/* */
|
|
7
|
+
/****************************************************************/
|
|
8
|
+
/****************************************************************/
|
|
9
|
+
/* */
|
|
10
|
+
/* Please do not make any change to this file */
|
|
11
|
+
/* If any change is required, ns-sdkg command must be used */
|
|
12
|
+
/* */
|
|
13
|
+
/****************************************************************/
|
|
14
|
+
/****************************************************************/
|
|
15
|
+
/* */
|
|
16
|
+
/* Namira Software Corporation */
|
|
17
|
+
/* https://namirasoft.com */
|
|
18
|
+
/* */
|
|
19
|
+
/****************************************************************/
|
|
20
|
+
|
|
21
|
+
import { AgentFieldRow } from "../row/AgentFieldRow";
|
|
22
|
+
import { BaseUUID, BaseMetaColumn } from "namirasoft-core";
|
|
23
|
+
import { FilterItem, SortItem } from "namirasoft-core";
|
|
24
|
+
import { NSBaseMetaDatabase, NSBaseMetaTable } from "namirasoft-site";
|
|
25
|
+
import { NamirasoftExpertServer } from "../NamirasoftExpertServer";
|
|
26
|
+
|
|
27
|
+
export class AgentFieldMetaTable extends NSBaseMetaTable<NamirasoftExpertServer, AgentFieldRow>
|
|
28
|
+
{
|
|
29
|
+
public override columns: {
|
|
30
|
+
id: BaseMetaColumn;
|
|
31
|
+
user_id: BaseMetaColumn;
|
|
32
|
+
entity_id: BaseMetaColumn;
|
|
33
|
+
field_id: BaseMetaColumn;
|
|
34
|
+
value: BaseMetaColumn;
|
|
35
|
+
created_at: BaseMetaColumn;
|
|
36
|
+
updated_at: BaseMetaColumn;
|
|
37
|
+
}
|
|
38
|
+
constructor(database: NSBaseMetaDatabase<NamirasoftExpertServer>)
|
|
39
|
+
{
|
|
40
|
+
super(database, "agent_field", "Agent Field", new BaseUUID(""));
|
|
41
|
+
this.columns = {
|
|
42
|
+
id: new BaseMetaColumn(this, "id", "ID", "Integer", true),
|
|
43
|
+
user_id: new BaseMetaColumn(this, "user_id", "User ID", "String", true),
|
|
44
|
+
entity_id: new BaseMetaColumn(this, "entity_id", "Entity ID", "String", true),
|
|
45
|
+
field_id: new BaseMetaColumn(this, "field_id", "Field ID", "String", true),
|
|
46
|
+
value: new BaseMetaColumn(this, "value", "Value", "String", false),
|
|
47
|
+
created_at: new BaseMetaColumn(this, "created_at", "Created At", "DateTime", true),
|
|
48
|
+
updated_at: new BaseMetaColumn(this, "updated_at", "Updated At", "DateTime", true),
|
|
49
|
+
};
|
|
50
|
+
this.back_end.get = async (id: string) =>
|
|
51
|
+
{
|
|
52
|
+
let server = this.database.getServer();
|
|
53
|
+
return await server.agent_field.Get(id);
|
|
54
|
+
};
|
|
55
|
+
this.back_end.list = async (filters: FilterItem[] | null, page: (number | null), size: (number | null), sorts: SortItem[]) =>
|
|
56
|
+
{
|
|
57
|
+
let server = this.database.getServer();
|
|
58
|
+
return await server.agent_field.List(filters, page, size, sorts);
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
};
|