ide-assi 0.12.0 → 0.14.0
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/bundle.cjs.js +31 -8
- package/dist/bundle.esm.js +31 -8
- package/dist/components/ideAi.js +31 -8
- package/package.json +1 -1
- package/src/components/ideAi.js +31 -8
package/dist/bundle.cjs.js
CHANGED
|
@@ -193260,11 +193260,12 @@ window.jQuery = window.$ = $$1;
|
|
|
193260
193260
|
class IdeAi
|
|
193261
193261
|
{
|
|
193262
193262
|
#API_URL = "http://localhost:8091";
|
|
193263
|
+
#SCHEMA = "booxtory_250131";
|
|
193263
193264
|
|
|
193264
193265
|
constructor() {
|
|
193265
193266
|
}
|
|
193266
193267
|
|
|
193267
|
-
#getMenuInfo = (
|
|
193268
|
+
#getMenuInfo = () => {
|
|
193268
193269
|
let arr = [];
|
|
193269
193270
|
|
|
193270
193271
|
ninegrid.querySelectorAll("nx-side-menu-item[url][title]").forEach(elem => {
|
|
@@ -193278,18 +193279,26 @@ class IdeAi
|
|
|
193278
193279
|
return arr;
|
|
193279
193280
|
};
|
|
193280
193281
|
|
|
193281
|
-
#getTableInfo = async (
|
|
193282
|
-
const response = await fetch(
|
|
193282
|
+
#getTableInfo = async () => {
|
|
193283
|
+
const response = await fetch("/api/meta/selectTableList", {
|
|
193283
193284
|
method: "POST",
|
|
193284
193285
|
headers: { "Content-Type": "application/json" },
|
|
193285
193286
|
body: JSON.stringify({
|
|
193286
|
-
schema:
|
|
193287
|
+
schema: this.#SCHEMA,
|
|
193287
193288
|
})
|
|
193288
193289
|
});
|
|
193289
193290
|
|
|
193290
193291
|
return await response.json();
|
|
193291
193292
|
};
|
|
193292
193293
|
|
|
193294
|
+
#findMenu = async (question) => {
|
|
193295
|
+
const menus = this.#getMenuInfo();
|
|
193296
|
+
const tables = await this.#getTableInfo();
|
|
193297
|
+
|
|
193298
|
+
console.log(menus);
|
|
193299
|
+
console.log(tables);
|
|
193300
|
+
};
|
|
193301
|
+
|
|
193293
193302
|
|
|
193294
193303
|
/**
|
|
193295
193304
|
* 1. 소스 명칭 package 예) tmpl.population
|
|
@@ -193300,11 +193309,25 @@ class IdeAi
|
|
|
193300
193309
|
*/
|
|
193301
193310
|
generateSource = async (question) => {
|
|
193302
193311
|
|
|
193303
|
-
const
|
|
193304
|
-
const
|
|
193312
|
+
const menus = this.#getMenuInfo();
|
|
193313
|
+
const tables = await this.#getTableInfo();
|
|
193314
|
+
|
|
193315
|
+
console.log(menus);
|
|
193316
|
+
console.log(tables);
|
|
193317
|
+
|
|
193318
|
+
const response = await fetch(`${#API_URL}/ai/generateSource`, {
|
|
193319
|
+
method: "POST",
|
|
193320
|
+
headers: { "Content-Type": "application/json" },
|
|
193321
|
+
body: JSON.stringify({
|
|
193322
|
+
question: question,
|
|
193323
|
+
menus: menus,
|
|
193324
|
+
tables: tables,
|
|
193325
|
+
})
|
|
193326
|
+
});
|
|
193327
|
+
|
|
193328
|
+
//console.log(await response.json());
|
|
193305
193329
|
|
|
193306
|
-
|
|
193307
|
-
console.log(tableInfo);
|
|
193330
|
+
return await response.json();
|
|
193308
193331
|
};
|
|
193309
193332
|
}
|
|
193310
193333
|
|
package/dist/bundle.esm.js
CHANGED
|
@@ -193256,11 +193256,12 @@ window.jQuery = window.$ = $$1;
|
|
|
193256
193256
|
class IdeAi
|
|
193257
193257
|
{
|
|
193258
193258
|
#API_URL = "http://localhost:8091";
|
|
193259
|
+
#SCHEMA = "booxtory_250131";
|
|
193259
193260
|
|
|
193260
193261
|
constructor() {
|
|
193261
193262
|
}
|
|
193262
193263
|
|
|
193263
|
-
#getMenuInfo = (
|
|
193264
|
+
#getMenuInfo = () => {
|
|
193264
193265
|
let arr = [];
|
|
193265
193266
|
|
|
193266
193267
|
ninegrid.querySelectorAll("nx-side-menu-item[url][title]").forEach(elem => {
|
|
@@ -193274,18 +193275,26 @@ class IdeAi
|
|
|
193274
193275
|
return arr;
|
|
193275
193276
|
};
|
|
193276
193277
|
|
|
193277
|
-
#getTableInfo = async (
|
|
193278
|
-
const response = await fetch(
|
|
193278
|
+
#getTableInfo = async () => {
|
|
193279
|
+
const response = await fetch("/api/meta/selectTableList", {
|
|
193279
193280
|
method: "POST",
|
|
193280
193281
|
headers: { "Content-Type": "application/json" },
|
|
193281
193282
|
body: JSON.stringify({
|
|
193282
|
-
schema:
|
|
193283
|
+
schema: this.#SCHEMA,
|
|
193283
193284
|
})
|
|
193284
193285
|
});
|
|
193285
193286
|
|
|
193286
193287
|
return await response.json();
|
|
193287
193288
|
};
|
|
193288
193289
|
|
|
193290
|
+
#findMenu = async (question) => {
|
|
193291
|
+
const menus = this.#getMenuInfo();
|
|
193292
|
+
const tables = await this.#getTableInfo();
|
|
193293
|
+
|
|
193294
|
+
console.log(menus);
|
|
193295
|
+
console.log(tables);
|
|
193296
|
+
};
|
|
193297
|
+
|
|
193289
193298
|
|
|
193290
193299
|
/**
|
|
193291
193300
|
* 1. 소스 명칭 package 예) tmpl.population
|
|
@@ -193296,11 +193305,25 @@ class IdeAi
|
|
|
193296
193305
|
*/
|
|
193297
193306
|
generateSource = async (question) => {
|
|
193298
193307
|
|
|
193299
|
-
const
|
|
193300
|
-
const
|
|
193308
|
+
const menus = this.#getMenuInfo();
|
|
193309
|
+
const tables = await this.#getTableInfo();
|
|
193310
|
+
|
|
193311
|
+
console.log(menus);
|
|
193312
|
+
console.log(tables);
|
|
193313
|
+
|
|
193314
|
+
const response = await fetch(`${#API_URL}/ai/generateSource`, {
|
|
193315
|
+
method: "POST",
|
|
193316
|
+
headers: { "Content-Type": "application/json" },
|
|
193317
|
+
body: JSON.stringify({
|
|
193318
|
+
question: question,
|
|
193319
|
+
menus: menus,
|
|
193320
|
+
tables: tables,
|
|
193321
|
+
})
|
|
193322
|
+
});
|
|
193323
|
+
|
|
193324
|
+
//console.log(await response.json());
|
|
193301
193325
|
|
|
193302
|
-
|
|
193303
|
-
console.log(tableInfo);
|
|
193326
|
+
return await response.json();
|
|
193304
193327
|
};
|
|
193305
193328
|
}
|
|
193306
193329
|
|
package/dist/components/ideAi.js
CHANGED
|
@@ -3,11 +3,12 @@ import ninegrid from "ninegrid2";
|
|
|
3
3
|
export class IdeAi
|
|
4
4
|
{
|
|
5
5
|
#API_URL = "http://localhost:8091";
|
|
6
|
+
#SCHEMA = "booxtory_250131";
|
|
6
7
|
|
|
7
8
|
constructor() {
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
#getMenuInfo = (
|
|
11
|
+
#getMenuInfo = () => {
|
|
11
12
|
let arr = [];
|
|
12
13
|
|
|
13
14
|
ninegrid.querySelectorAll("nx-side-menu-item[url][title]").forEach(elem => {
|
|
@@ -21,18 +22,26 @@ export class IdeAi
|
|
|
21
22
|
return arr;
|
|
22
23
|
};
|
|
23
24
|
|
|
24
|
-
#getTableInfo = async (
|
|
25
|
-
const response = await fetch(
|
|
25
|
+
#getTableInfo = async () => {
|
|
26
|
+
const response = await fetch("/api/meta/selectTableList", {
|
|
26
27
|
method: "POST",
|
|
27
28
|
headers: { "Content-Type": "application/json" },
|
|
28
29
|
body: JSON.stringify({
|
|
29
|
-
schema:
|
|
30
|
+
schema: this.#SCHEMA,
|
|
30
31
|
})
|
|
31
32
|
});
|
|
32
33
|
|
|
33
34
|
return await response.json();
|
|
34
35
|
};
|
|
35
36
|
|
|
37
|
+
#findMenu = async (question) => {
|
|
38
|
+
const menus = this.#getMenuInfo();
|
|
39
|
+
const tables = await this.#getTableInfo();
|
|
40
|
+
|
|
41
|
+
console.log(menus);
|
|
42
|
+
console.log(tables);
|
|
43
|
+
};
|
|
44
|
+
|
|
36
45
|
|
|
37
46
|
/**
|
|
38
47
|
* 1. 소스 명칭 package 예) tmpl.population
|
|
@@ -43,11 +52,25 @@ export class IdeAi
|
|
|
43
52
|
*/
|
|
44
53
|
generateSource = async (question) => {
|
|
45
54
|
|
|
46
|
-
const
|
|
47
|
-
const
|
|
55
|
+
const menus = this.#getMenuInfo();
|
|
56
|
+
const tables = await this.#getTableInfo();
|
|
57
|
+
|
|
58
|
+
console.log(menus);
|
|
59
|
+
console.log(tables);
|
|
60
|
+
|
|
61
|
+
const response = await fetch(`${#API_URL}/ai/generateSource`, {
|
|
62
|
+
method: "POST",
|
|
63
|
+
headers: { "Content-Type": "application/json" },
|
|
64
|
+
body: JSON.stringify({
|
|
65
|
+
question: question,
|
|
66
|
+
menus: menus,
|
|
67
|
+
tables: tables,
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
//console.log(await response.json());
|
|
48
72
|
|
|
49
|
-
|
|
50
|
-
console.log(tableInfo);
|
|
73
|
+
return await response.json();
|
|
51
74
|
};
|
|
52
75
|
}
|
|
53
76
|
|
package/package.json
CHANGED
package/src/components/ideAi.js
CHANGED
|
@@ -3,11 +3,12 @@ import ninegrid from "ninegrid2";
|
|
|
3
3
|
export class IdeAi
|
|
4
4
|
{
|
|
5
5
|
#API_URL = "http://localhost:8091";
|
|
6
|
+
#SCHEMA = "booxtory_250131";
|
|
6
7
|
|
|
7
8
|
constructor() {
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
#getMenuInfo = (
|
|
11
|
+
#getMenuInfo = () => {
|
|
11
12
|
let arr = [];
|
|
12
13
|
|
|
13
14
|
ninegrid.querySelectorAll("nx-side-menu-item[url][title]").forEach(elem => {
|
|
@@ -21,18 +22,26 @@ export class IdeAi
|
|
|
21
22
|
return arr;
|
|
22
23
|
};
|
|
23
24
|
|
|
24
|
-
#getTableInfo = async (
|
|
25
|
-
const response = await fetch(
|
|
25
|
+
#getTableInfo = async () => {
|
|
26
|
+
const response = await fetch("/api/meta/selectTableList", {
|
|
26
27
|
method: "POST",
|
|
27
28
|
headers: { "Content-Type": "application/json" },
|
|
28
29
|
body: JSON.stringify({
|
|
29
|
-
schema:
|
|
30
|
+
schema: this.#SCHEMA,
|
|
30
31
|
})
|
|
31
32
|
});
|
|
32
33
|
|
|
33
34
|
return await response.json();
|
|
34
35
|
};
|
|
35
36
|
|
|
37
|
+
#findMenu = async (question) => {
|
|
38
|
+
const menus = this.#getMenuInfo();
|
|
39
|
+
const tables = await this.#getTableInfo();
|
|
40
|
+
|
|
41
|
+
console.log(menus);
|
|
42
|
+
console.log(tables);
|
|
43
|
+
};
|
|
44
|
+
|
|
36
45
|
|
|
37
46
|
/**
|
|
38
47
|
* 1. 소스 명칭 package 예) tmpl.population
|
|
@@ -43,11 +52,25 @@ export class IdeAi
|
|
|
43
52
|
*/
|
|
44
53
|
generateSource = async (question) => {
|
|
45
54
|
|
|
46
|
-
const
|
|
47
|
-
const
|
|
55
|
+
const menus = this.#getMenuInfo();
|
|
56
|
+
const tables = await this.#getTableInfo();
|
|
57
|
+
|
|
58
|
+
console.log(menus);
|
|
59
|
+
console.log(tables);
|
|
60
|
+
|
|
61
|
+
const response = await fetch(`${#API_URL}/ai/generateSource`, {
|
|
62
|
+
method: "POST",
|
|
63
|
+
headers: { "Content-Type": "application/json" },
|
|
64
|
+
body: JSON.stringify({
|
|
65
|
+
question: question,
|
|
66
|
+
menus: menus,
|
|
67
|
+
tables: tables,
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
//console.log(await response.json());
|
|
48
72
|
|
|
49
|
-
|
|
50
|
-
console.log(tableInfo);
|
|
73
|
+
return await response.json();
|
|
51
74
|
};
|
|
52
75
|
}
|
|
53
76
|
|