diff --git a/.gitignore b/.gitignore index 7cb8961c8..93c2a5388 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ target build .idea *.iml +.DS_Store diff --git a/README.md b/README.md index 5f6df7774..f28e8542b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ - - # RAP API Management System +# RAP API Management System * THX开源工具集: [http://thx.github.io/](http://thx.github.io/) * 作者微博:[@Bosn](http://weibo.com/bosn) diff --git a/WebContent/.DS_Store b/WebContent/.DS_Store deleted file mode 100644 index 9e17d0ea6..000000000 Binary files a/WebContent/.DS_Store and /dev/null differ diff --git a/WebContent/WEB-INF/.DS_Store b/WebContent/WEB-INF/.DS_Store deleted file mode 100644 index 431513315..000000000 Binary files a/WebContent/WEB-INF/.DS_Store and /dev/null differ diff --git a/WebContent/stat/js/core/rap.js b/WebContent/stat/js/core/rap.js index 2ae09ce00..6b077a357 100644 --- a/WebContent/stat/js/core/rap.js +++ b/WebContent/stat/js/core/rap.js @@ -2649,7 +2649,8 @@ function deepCopy(o) { var action = p.getAction(actionId); var postData = 'actionData=' + encodeURIComponent(JSON.stringify(action)); var me = this; - b.g('mockDataPreviewFloater-container').innerHTML = 'loading...'; + $('#mockDataPreviewFloater-container').val('loading...'); + $('#mockRulePreviewFloater-container').val('loading...'); $('.glyphicon-question-sign').tooltip(); ecFloater.show("mockDataPreviewFloater"); b.ajax.post(URL.queryMockData, postData, function(xhr, response) { @@ -2658,8 +2659,8 @@ function deepCopy(o) { var mockRuleObj = eval('(' + response + ')'); var mockDataObj = Mock.mock(mockRuleObj); me._mockRuleObj = mockRuleObj; - b.g('mockRulePreviewFloater-container').innerHTML = JSON.stringify(mockRuleObj, null, 4); - b.g('mockDataPreviewFloater-container').innerHTML = JSON.stringify(mockDataObj, null, 4); + $('#mockRulePreviewFloater-container').val(JSON.stringify(mockRuleObj, null, 4)); + $('#mockDataPreviewFloater-container').val(JSON.stringify(mockDataObj, null, 4)); showMessage(CONST.LOAD, ELEMENT_ID.WORKSPACE_MESSAGE, MESSAGE.SAVED); } catch(e) { showMessage(CONST.ERROR, ELEMENT_ID.WORKSPACE_MESSAGE, MESSAGE.FATAL_ERROR); @@ -2668,7 +2669,7 @@ function deepCopy(o) { }; ws.refreshMockPreviewData = function() { - b.g('mockDataPreviewFloater-container').innerHTML = JSON.stringify(Mock.mock(this._mockRuleObj), null, 4); + $('#mockDataPreviewFloater-container').val(JSON.stringify(Mock.mock(this._mockRuleObj), null, 4)); }; ws.copyToClipboard = function(eleId) { diff --git a/WebContent/tester/pageTester.js b/WebContent/tester/pageTester.js index 4a1156cdd..7f1800a10 100644 --- a/WebContent/tester/pageTester.js +++ b/WebContent/tester/pageTester.js @@ -69,7 +69,7 @@ YUI().use('handlebars', 'node', 'event', 'jsonp', 'jsonp-url', 'json-stringify', success : function() { var args = []; try { - args = [JSON.parse(arguments[1].responseText)]; + args = [eval('(' + arguments[1].responseText + ')')]; } catch (ex) { log(color('error occurred!', RED) + color(', detail:' + ex.message, LIGHT_GRAY)); }