ide-assi 0.26.0 → 0.28.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.
@@ -193279,7 +193279,7 @@ class IdeAi
193279
193279
  return arr;
193280
193280
  };
193281
193281
 
193282
- #getTableInfo = async () => {
193282
+ #getTableList = async () => {
193283
193283
  const response = await fetch("/api/meta/selectTableList", {
193284
193284
  method: "POST",
193285
193285
  headers: { "Content-Type": "application/json" },
@@ -193291,15 +193291,20 @@ class IdeAi
193291
193291
  return await response.json();
193292
193292
  };
193293
193293
 
193294
- #findMenu = async (question) => {
193295
- const menus = this.#getMenuInfo();
193296
- const tables = await this.#getTableInfo();
193294
+ #getColumnInfo = async () => {
193295
+ const response = await fetch("/api/meta/selectColumnInfo", {
193296
+ method: "POST",
193297
+ headers: { "Content-Type": "application/json" },
193298
+ body: JSON.stringify({
193299
+ schema: this.#SCHEMA,
193300
+ })
193301
+ });
193297
193302
 
193298
- console.log(menus);
193299
- console.log(tables);
193303
+ return await response.json();
193300
193304
  };
193301
193305
 
193302
193306
 
193307
+
193303
193308
  /**
193304
193309
  * 1. 소스 명칭 package 예) tmpl.population
193305
193310
  * 2. 소스가 없으면 소스 생성
@@ -193310,7 +193315,7 @@ class IdeAi
193310
193315
  generateSource = async (userPrompt) => {
193311
193316
 
193312
193317
  const menus = this.#getMenuInfo();
193313
- const tables = await this.#getTableInfo();
193318
+ const tables = await this.#getTableList();
193314
193319
 
193315
193320
  console.log(menus);
193316
193321
  console.log(tables);
@@ -193326,6 +193331,7 @@ class IdeAi
193326
193331
  });
193327
193332
 
193328
193333
  const res = await response.json();
193334
+ console.log(res.table);
193329
193335
 
193330
193336
  if (res.result == "1") {
193331
193337
  const response2 = await fetch(`${this.#API_URL}/ai/generateSource`, {
@@ -193333,8 +193339,8 @@ class IdeAi
193333
193339
  headers: { "Content-Type": "application/json" },
193334
193340
  body: JSON.stringify({
193335
193341
  userPrompt: userPrompt,
193336
- menus: menus,
193337
- tables: tables.list,
193342
+ url: res.menu.url,
193343
+ tables: res.table,
193338
193344
  })
193339
193345
  });
193340
193346
 
@@ -193348,8 +193354,8 @@ class IdeAi
193348
193354
  contents: source.mybatis,
193349
193355
  })
193350
193356
  });
193351
- console.log(response3);
193352
- console.log(await response3.json());
193357
+ //console.log(response3);
193358
+ //console.log(await response3.json());
193353
193359
 
193354
193360
  return await response3.json();
193355
193361
  }
@@ -193275,7 +193275,7 @@ class IdeAi
193275
193275
  return arr;
193276
193276
  };
193277
193277
 
193278
- #getTableInfo = async () => {
193278
+ #getTableList = async () => {
193279
193279
  const response = await fetch("/api/meta/selectTableList", {
193280
193280
  method: "POST",
193281
193281
  headers: { "Content-Type": "application/json" },
@@ -193287,15 +193287,20 @@ class IdeAi
193287
193287
  return await response.json();
193288
193288
  };
193289
193289
 
193290
- #findMenu = async (question) => {
193291
- const menus = this.#getMenuInfo();
193292
- const tables = await this.#getTableInfo();
193290
+ #getColumnInfo = async () => {
193291
+ const response = await fetch("/api/meta/selectColumnInfo", {
193292
+ method: "POST",
193293
+ headers: { "Content-Type": "application/json" },
193294
+ body: JSON.stringify({
193295
+ schema: this.#SCHEMA,
193296
+ })
193297
+ });
193293
193298
 
193294
- console.log(menus);
193295
- console.log(tables);
193299
+ return await response.json();
193296
193300
  };
193297
193301
 
193298
193302
 
193303
+
193299
193304
  /**
193300
193305
  * 1. 소스 명칭 package 예) tmpl.population
193301
193306
  * 2. 소스가 없으면 소스 생성
@@ -193306,7 +193311,7 @@ class IdeAi
193306
193311
  generateSource = async (userPrompt) => {
193307
193312
 
193308
193313
  const menus = this.#getMenuInfo();
193309
- const tables = await this.#getTableInfo();
193314
+ const tables = await this.#getTableList();
193310
193315
 
193311
193316
  console.log(menus);
193312
193317
  console.log(tables);
@@ -193322,6 +193327,7 @@ class IdeAi
193322
193327
  });
193323
193328
 
193324
193329
  const res = await response.json();
193330
+ console.log(res.table);
193325
193331
 
193326
193332
  if (res.result == "1") {
193327
193333
  const response2 = await fetch(`${this.#API_URL}/ai/generateSource`, {
@@ -193329,8 +193335,8 @@ class IdeAi
193329
193335
  headers: { "Content-Type": "application/json" },
193330
193336
  body: JSON.stringify({
193331
193337
  userPrompt: userPrompt,
193332
- menus: menus,
193333
- tables: tables.list,
193338
+ url: res.menu.url,
193339
+ tables: res.table,
193334
193340
  })
193335
193341
  });
193336
193342
 
@@ -193344,8 +193350,8 @@ class IdeAi
193344
193350
  contents: source.mybatis,
193345
193351
  })
193346
193352
  });
193347
- console.log(response3);
193348
- console.log(await response3.json());
193353
+ //console.log(response3);
193354
+ //console.log(await response3.json());
193349
193355
 
193350
193356
  return await response3.json();
193351
193357
  }
@@ -22,7 +22,7 @@ export class IdeAi
22
22
  return arr;
23
23
  };
24
24
 
25
- #getTableInfo = async () => {
25
+ #getTableList = async () => {
26
26
  const response = await fetch("/api/meta/selectTableList", {
27
27
  method: "POST",
28
28
  headers: { "Content-Type": "application/json" },
@@ -34,15 +34,20 @@ export class IdeAi
34
34
  return await response.json();
35
35
  };
36
36
 
37
- #findMenu = async (question) => {
38
- const menus = this.#getMenuInfo();
39
- const tables = await this.#getTableInfo();
37
+ #getColumnInfo = async () => {
38
+ const response = await fetch("/api/meta/selectColumnInfo", {
39
+ method: "POST",
40
+ headers: { "Content-Type": "application/json" },
41
+ body: JSON.stringify({
42
+ schema: this.#SCHEMA,
43
+ })
44
+ });
40
45
 
41
- console.log(menus);
42
- console.log(tables);
46
+ return await response.json();
43
47
  };
44
48
 
45
49
 
50
+
46
51
  /**
47
52
  * 1. 소스 명칭 package 예) tmpl.population
48
53
  * 2. 소스가 없으면 소스 생성
@@ -53,7 +58,7 @@ export class IdeAi
53
58
  generateSource = async (userPrompt) => {
54
59
 
55
60
  const menus = this.#getMenuInfo();
56
- const tables = await this.#getTableInfo();
61
+ const tables = await this.#getTableList();
57
62
 
58
63
  console.log(menus);
59
64
  console.log(tables);
@@ -69,6 +74,7 @@ export class IdeAi
69
74
  });
70
75
 
71
76
  const res = await response.json();
77
+ console.log(res.table);
72
78
 
73
79
  if (res.result == "1") {
74
80
  const response2 = await fetch(`${this.#API_URL}/ai/generateSource`, {
@@ -76,8 +82,8 @@ export class IdeAi
76
82
  headers: { "Content-Type": "application/json" },
77
83
  body: JSON.stringify({
78
84
  userPrompt: userPrompt,
79
- menus: menus,
80
- tables: tables.list,
85
+ url: res.menu.url,
86
+ tables: res.table,
81
87
  })
82
88
  });
83
89
 
@@ -91,8 +97,8 @@ export class IdeAi
91
97
  contents: source.mybatis,
92
98
  })
93
99
  });
94
- console.log(response3);
95
- console.log(await response3.json());
100
+ //console.log(response3);
101
+ //console.log(await response3.json());
96
102
 
97
103
  return await response3.json();
98
104
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ide-assi",
3
3
  "type": "module",
4
- "version": "0.26.0",
4
+ "version": "0.28.0",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "exports": {
@@ -22,7 +22,7 @@ export class IdeAi
22
22
  return arr;
23
23
  };
24
24
 
25
- #getTableInfo = async () => {
25
+ #getTableList = async () => {
26
26
  const response = await fetch("/api/meta/selectTableList", {
27
27
  method: "POST",
28
28
  headers: { "Content-Type": "application/json" },
@@ -34,15 +34,20 @@ export class IdeAi
34
34
  return await response.json();
35
35
  };
36
36
 
37
- #findMenu = async (question) => {
38
- const menus = this.#getMenuInfo();
39
- const tables = await this.#getTableInfo();
37
+ #getColumnInfo = async () => {
38
+ const response = await fetch("/api/meta/selectColumnInfo", {
39
+ method: "POST",
40
+ headers: { "Content-Type": "application/json" },
41
+ body: JSON.stringify({
42
+ schema: this.#SCHEMA,
43
+ })
44
+ });
40
45
 
41
- console.log(menus);
42
- console.log(tables);
46
+ return await response.json();
43
47
  };
44
48
 
45
49
 
50
+
46
51
  /**
47
52
  * 1. 소스 명칭 package 예) tmpl.population
48
53
  * 2. 소스가 없으면 소스 생성
@@ -53,7 +58,7 @@ export class IdeAi
53
58
  generateSource = async (userPrompt) => {
54
59
 
55
60
  const menus = this.#getMenuInfo();
56
- const tables = await this.#getTableInfo();
61
+ const tables = await this.#getTableList();
57
62
 
58
63
  console.log(menus);
59
64
  console.log(tables);
@@ -69,6 +74,7 @@ export class IdeAi
69
74
  });
70
75
 
71
76
  const res = await response.json();
77
+ console.log(res.table);
72
78
 
73
79
  if (res.result == "1") {
74
80
  const response2 = await fetch(`${this.#API_URL}/ai/generateSource`, {
@@ -76,8 +82,8 @@ export class IdeAi
76
82
  headers: { "Content-Type": "application/json" },
77
83
  body: JSON.stringify({
78
84
  userPrompt: userPrompt,
79
- menus: menus,
80
- tables: tables.list,
85
+ url: res.menu.url,
86
+ tables: res.table,
81
87
  })
82
88
  });
83
89
 
@@ -91,8 +97,8 @@ export class IdeAi
91
97
  contents: source.mybatis,
92
98
  })
93
99
  });
94
- console.log(response3);
95
- console.log(await response3.json());
100
+ //console.log(response3);
101
+ //console.log(await response3.json());
96
102
 
97
103
  return await response3.json();
98
104
  }