ide-assi 0.196.0 → 0.197.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 -29
- package/dist/bundle.esm.js +31 -29
- package/dist/components/ideAi.js +31 -2
- package/dist/components/ideUtils.js +1 -28
- package/package.json +1 -1
- package/src/components/ideAi.js +31 -2
- package/src/components/ideUtils.js +1 -28
package/dist/bundle.cjs.js
CHANGED
|
@@ -193342,34 +193342,7 @@ class IdeUtils
|
|
|
193342
193342
|
.join('.');
|
|
193343
193343
|
*/
|
|
193344
193344
|
|
|
193345
|
-
static getSourcePath = (menuUrl) => {
|
|
193346
|
-
const path = menuUrl.replace(/^\/+/, '');
|
|
193347
193345
|
|
|
193348
|
-
//const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193349
|
-
const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193350
|
-
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
193351
|
-
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
193352
|
-
|
|
193353
|
-
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
193354
|
-
|
|
193355
|
-
return {
|
|
193356
|
-
package: packageName,
|
|
193357
|
-
namespace: namespace,
|
|
193358
|
-
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193359
|
-
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193360
|
-
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193361
|
-
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193362
|
-
};
|
|
193363
|
-
/***
|
|
193364
|
-
return {
|
|
193365
|
-
basePackage: packageName,
|
|
193366
|
-
namespace: namespace,
|
|
193367
|
-
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193368
|
-
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193369
|
-
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193370
|
-
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193371
|
-
};*/
|
|
193372
|
-
};
|
|
193373
193346
|
|
|
193374
193347
|
static generatePrompt = async (path, params) => {
|
|
193375
193348
|
|
|
@@ -193711,6 +193684,35 @@ class IdeAi
|
|
|
193711
193684
|
return src;
|
|
193712
193685
|
};
|
|
193713
193686
|
|
|
193687
|
+
#getSourcePath = (menuUrl) => {
|
|
193688
|
+
const path = menuUrl.replace(/^\/+/, '');
|
|
193689
|
+
|
|
193690
|
+
const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193691
|
+
//const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193692
|
+
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
193693
|
+
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
193694
|
+
|
|
193695
|
+
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
193696
|
+
|
|
193697
|
+
return {
|
|
193698
|
+
package: packageName,
|
|
193699
|
+
namespace: namespace,
|
|
193700
|
+
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193701
|
+
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193702
|
+
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193703
|
+
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193704
|
+
};
|
|
193705
|
+
/***
|
|
193706
|
+
return {
|
|
193707
|
+
basePackage: packageName,
|
|
193708
|
+
namespace: namespace,
|
|
193709
|
+
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193710
|
+
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193711
|
+
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193712
|
+
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193713
|
+
};*/
|
|
193714
|
+
};
|
|
193715
|
+
|
|
193714
193716
|
generateSourceClient = async (userPrompt) => {
|
|
193715
193717
|
|
|
193716
193718
|
try {
|
|
@@ -193726,8 +193728,8 @@ class IdeAi
|
|
|
193726
193728
|
console.log(where);
|
|
193727
193729
|
|
|
193728
193730
|
//packageName
|
|
193729
|
-
const srcPath =
|
|
193730
|
-
srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
193731
|
+
const srcPath = this.#getSourcePath(where.menu.url);
|
|
193732
|
+
//srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
193731
193733
|
|
|
193732
193734
|
console.log(srcPath);
|
|
193733
193735
|
|
package/dist/bundle.esm.js
CHANGED
|
@@ -193338,34 +193338,7 @@ class IdeUtils
|
|
|
193338
193338
|
.join('.');
|
|
193339
193339
|
*/
|
|
193340
193340
|
|
|
193341
|
-
static getSourcePath = (menuUrl) => {
|
|
193342
|
-
const path = menuUrl.replace(/^\/+/, '');
|
|
193343
193341
|
|
|
193344
|
-
//const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193345
|
-
const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193346
|
-
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
193347
|
-
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
193348
|
-
|
|
193349
|
-
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
193350
|
-
|
|
193351
|
-
return {
|
|
193352
|
-
package: packageName,
|
|
193353
|
-
namespace: namespace,
|
|
193354
|
-
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193355
|
-
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193356
|
-
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193357
|
-
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193358
|
-
};
|
|
193359
|
-
/***
|
|
193360
|
-
return {
|
|
193361
|
-
basePackage: packageName,
|
|
193362
|
-
namespace: namespace,
|
|
193363
|
-
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193364
|
-
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193365
|
-
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193366
|
-
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193367
|
-
};*/
|
|
193368
|
-
};
|
|
193369
193342
|
|
|
193370
193343
|
static generatePrompt = async (path, params) => {
|
|
193371
193344
|
|
|
@@ -193707,6 +193680,35 @@ class IdeAi
|
|
|
193707
193680
|
return src;
|
|
193708
193681
|
};
|
|
193709
193682
|
|
|
193683
|
+
#getSourcePath = (menuUrl) => {
|
|
193684
|
+
const path = menuUrl.replace(/^\/+/, '');
|
|
193685
|
+
|
|
193686
|
+
const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193687
|
+
//const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
193688
|
+
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
193689
|
+
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
193690
|
+
|
|
193691
|
+
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
193692
|
+
|
|
193693
|
+
return {
|
|
193694
|
+
package: packageName,
|
|
193695
|
+
namespace: namespace,
|
|
193696
|
+
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193697
|
+
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193698
|
+
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193699
|
+
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193700
|
+
};
|
|
193701
|
+
/***
|
|
193702
|
+
return {
|
|
193703
|
+
basePackage: packageName,
|
|
193704
|
+
namespace: namespace,
|
|
193705
|
+
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
193706
|
+
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
193707
|
+
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
193708
|
+
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
193709
|
+
};*/
|
|
193710
|
+
};
|
|
193711
|
+
|
|
193710
193712
|
generateSourceClient = async (userPrompt) => {
|
|
193711
193713
|
|
|
193712
193714
|
try {
|
|
@@ -193722,8 +193724,8 @@ class IdeAi
|
|
|
193722
193724
|
console.log(where);
|
|
193723
193725
|
|
|
193724
193726
|
//packageName
|
|
193725
|
-
const srcPath =
|
|
193726
|
-
srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
193727
|
+
const srcPath = this.#getSourcePath(where.menu.url);
|
|
193728
|
+
//srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
193727
193729
|
|
|
193728
193730
|
console.log(srcPath);
|
|
193729
193731
|
|
package/dist/components/ideAi.js
CHANGED
|
@@ -282,6 +282,35 @@ export class IdeAi
|
|
|
282
282
|
return src;
|
|
283
283
|
};
|
|
284
284
|
|
|
285
|
+
#getSourcePath = (menuUrl) => {
|
|
286
|
+
const path = menuUrl.replace(/^\/+/, '');
|
|
287
|
+
|
|
288
|
+
const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
289
|
+
//const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
290
|
+
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
291
|
+
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
292
|
+
|
|
293
|
+
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
294
|
+
|
|
295
|
+
return {
|
|
296
|
+
package: packageName,
|
|
297
|
+
namespace: namespace,
|
|
298
|
+
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
299
|
+
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
300
|
+
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
301
|
+
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
302
|
+
};
|
|
303
|
+
/***
|
|
304
|
+
return {
|
|
305
|
+
basePackage: packageName,
|
|
306
|
+
namespace: namespace,
|
|
307
|
+
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
308
|
+
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
309
|
+
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
310
|
+
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
311
|
+
};*/
|
|
312
|
+
};
|
|
313
|
+
|
|
285
314
|
generateSourceClient = async (userPrompt) => {
|
|
286
315
|
|
|
287
316
|
try {
|
|
@@ -297,8 +326,8 @@ export class IdeAi
|
|
|
297
326
|
console.log(where);
|
|
298
327
|
|
|
299
328
|
//packageName
|
|
300
|
-
const srcPath =
|
|
301
|
-
srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
329
|
+
const srcPath = this.#getSourcePath(where.menu.url);
|
|
330
|
+
//srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
302
331
|
|
|
303
332
|
console.log(srcPath);
|
|
304
333
|
|
|
@@ -32,34 +32,7 @@ export class IdeUtils
|
|
|
32
32
|
.join('.');
|
|
33
33
|
*/
|
|
34
34
|
|
|
35
|
-
|
|
36
|
-
const path = menuUrl.replace(/^\/+/, '');
|
|
37
|
-
|
|
38
|
-
//const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
39
|
-
const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
40
|
-
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
41
|
-
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
42
|
-
|
|
43
|
-
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
44
|
-
|
|
45
|
-
return {
|
|
46
|
-
package: packageName,
|
|
47
|
-
namespace: namespace,
|
|
48
|
-
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
49
|
-
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
50
|
-
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
51
|
-
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
52
|
-
};
|
|
53
|
-
/***
|
|
54
|
-
return {
|
|
55
|
-
basePackage: packageName,
|
|
56
|
-
namespace: namespace,
|
|
57
|
-
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
58
|
-
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
59
|
-
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
60
|
-
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
61
|
-
};*/
|
|
62
|
-
};
|
|
35
|
+
|
|
63
36
|
|
|
64
37
|
static generatePrompt = async (path, params) => {
|
|
65
38
|
|
package/package.json
CHANGED
package/src/components/ideAi.js
CHANGED
|
@@ -282,6 +282,35 @@ export class IdeAi
|
|
|
282
282
|
return src;
|
|
283
283
|
};
|
|
284
284
|
|
|
285
|
+
#getSourcePath = (menuUrl) => {
|
|
286
|
+
const path = menuUrl.replace(/^\/+/, '');
|
|
287
|
+
|
|
288
|
+
const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
289
|
+
//const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
290
|
+
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
291
|
+
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
292
|
+
|
|
293
|
+
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
294
|
+
|
|
295
|
+
return {
|
|
296
|
+
package: packageName,
|
|
297
|
+
namespace: namespace,
|
|
298
|
+
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
299
|
+
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
300
|
+
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
301
|
+
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
302
|
+
};
|
|
303
|
+
/***
|
|
304
|
+
return {
|
|
305
|
+
basePackage: packageName,
|
|
306
|
+
namespace: namespace,
|
|
307
|
+
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
308
|
+
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
309
|
+
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
310
|
+
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
311
|
+
};*/
|
|
312
|
+
};
|
|
313
|
+
|
|
285
314
|
generateSourceClient = async (userPrompt) => {
|
|
286
315
|
|
|
287
316
|
try {
|
|
@@ -297,8 +326,8 @@ export class IdeAi
|
|
|
297
326
|
console.log(where);
|
|
298
327
|
|
|
299
328
|
//packageName
|
|
300
|
-
const srcPath =
|
|
301
|
-
srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
329
|
+
const srcPath = this.#getSourcePath(where.menu.url);
|
|
330
|
+
//srcPath.package = this.#parent.config.basePackage + "." + srcPath.package;
|
|
302
331
|
|
|
303
332
|
console.log(srcPath);
|
|
304
333
|
|
|
@@ -32,34 +32,7 @@ export class IdeUtils
|
|
|
32
32
|
.join('.');
|
|
33
33
|
*/
|
|
34
34
|
|
|
35
|
-
|
|
36
|
-
const path = menuUrl.replace(/^\/+/, '');
|
|
37
|
-
|
|
38
|
-
//const packageName = `${this.#parent.config.basePackage}.${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
39
|
-
const packageName = `${path.split("/").slice(0, -1).join(".").toLowerCase()}`;
|
|
40
|
-
const namespace = path.split("/").slice(0, -1).join(".").toLowerCase();
|
|
41
|
-
const fileName = path.split("/").at(-1).toLowerCase().split('-').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join('');
|
|
42
|
-
|
|
43
|
-
//console.log(this.#parent, this.#parent.config, packageName, namespace, fileName);
|
|
44
|
-
|
|
45
|
-
return {
|
|
46
|
-
package: packageName,
|
|
47
|
-
namespace: namespace,
|
|
48
|
-
controller: `${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
49
|
-
service: `${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
50
|
-
mybatis: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
51
|
-
javascript: `${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
52
|
-
};
|
|
53
|
-
/***
|
|
54
|
-
return {
|
|
55
|
-
basePackage: packageName,
|
|
56
|
-
namespace: namespace,
|
|
57
|
-
controller: `/src/main/java/${packageName.replaceAll(".", "/")}/controller/${fileName}Controller.java`,
|
|
58
|
-
service: `/src/main/java/${packageName.replaceAll(".", "/")}/service/${fileName}Service.java`,
|
|
59
|
-
mybatis: `/src/main/resource/mapper/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${fileName}Mapper.xml`,
|
|
60
|
-
javascript: `/${jsroot}/${path.split("/").slice(0, -1).join("/").toLowerCase()}/${path.split("/").at(-1)}.jsx`,
|
|
61
|
-
};*/
|
|
62
|
-
};
|
|
35
|
+
|
|
63
36
|
|
|
64
37
|
static generatePrompt = async (path, params) => {
|
|
65
38
|
|