Parcourir la source

修复JS报错的问题

mxd il y a 4 ans
Parent
commit
2db34fe5f1
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      src/main/resources/magicapi-support/js/index.js

+ 1 - 1
src/main/resources/magicapi-support/js/index.js

@@ -25,7 +25,7 @@ var MagicEditor = {
         var _this = this;
         $.getJSON('config.json',function(data){
             _this.config = data;
-            Parser.importPackages = _this.config.autoImportPackage.replace(/\\s/g,'').replace(/\*/g,'').split(',');
+            Parser.importPackages = ['java.util.','java.lang.'].concat((_this.config.autoImportPackage||'').replace(/\\s/g,'').replace(/\*/g,'').split(','));
         })
     },
     initSkin : function(){