test.js 1.4 KB

123456789101112131415161718192021222324252627
  1. output = {};
  2. try {
  3. eval(dfs.read("/script/matrix/utils/ajs/JsonImporterFuncs.js"));
  4. output.result = {};
  5. output.result.change_main = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/change_main"});
  6. output.result.event = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/event"});
  7. output.result.problem = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/problem"});
  8. output.result.report = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/report"});
  9. output.result.device_power_on_off = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/device_power_on_off"});
  10. output.result.data_collect = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/data_collect"});
  11. output.result.drill = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/drill"});
  12. output.result.implement = runServerJS("/matrix/utils/ajs/InitJsonImporter.js", {classname:"/cncc/action/implement"});
  13. } catch (e) {
  14. if (typeof (e) == "object") {
  15. output.error = e;
  16. } else if (typeof (e) == "string") {
  17. output.error = "错误:" + e;
  18. } else {
  19. output.error = JSON.stringify(e);
  20. }
  21. }
  22. // 返回输出信息
  23. OUTPUT = output;