fix(插件管理): 修复查看插件报错问题
This commit is contained in:
parent
c706564720
commit
9814b18588
|
@ -53,7 +53,6 @@ public class CommonUtil {
|
||||||
|
|
||||||
public static List<Class<?>> getSubClass(String fileName) throws Exception {
|
public static List<Class<?>> getSubClass(String fileName) throws Exception {
|
||||||
List<Class<?>> classes = new LinkedList<>();
|
List<Class<?>> classes = new LinkedList<>();
|
||||||
ResourcePatternResolver resourceLoader = new PathMatchingResourcePatternResolver();
|
|
||||||
if (StringUtil.isNotEmpty(fileName) && fileName.endsWith(".jar")) {
|
if (StringUtil.isNotEmpty(fileName) && fileName.endsWith(".jar")) {
|
||||||
fileName = fileName.substring(0, fileName.length() - 4);
|
fileName = fileName.substring(0, fileName.length() - 4);
|
||||||
}
|
}
|
||||||
|
|
|
@ -91,7 +91,7 @@ export default {
|
||||||
this.initPlugins();
|
this.initPlugins();
|
||||||
},
|
},
|
||||||
handleView(row){
|
handleView(row){
|
||||||
this.$refs.scriptView.open(row.pluginId);
|
this.$refs.scriptView.open(row.scriptId);
|
||||||
},
|
},
|
||||||
handleDelete(id) {
|
handleDelete(id) {
|
||||||
this.$confirm(this.$t('api_test.jar_config.delete_tip'), '', {
|
this.$confirm(this.$t('api_test.jar_config.delete_tip'), '', {
|
||||||
|
|
|
@ -45,8 +45,12 @@ export default {
|
||||||
getPlugin(id) {
|
getPlugin(id) {
|
||||||
if (id) {
|
if (id) {
|
||||||
this.$get('/plugin/get/' + id, response => {
|
this.$get('/plugin/get/' + id, response => {
|
||||||
|
if (response.data) {
|
||||||
this.plugin = response.data;
|
this.plugin = response.data;
|
||||||
this.reload();
|
this.reload();
|
||||||
|
} else {
|
||||||
|
this.$warning("未找到脚本内容");
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue