Skip to content

Commit

Permalink
SEE MORE DETAILS IN UPDATELOG.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Bosn committed Feb 12, 2014
1 parent 98883b0 commit 2e86acd
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 6 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Rigel Automation Platform
===

@version v0.7.0
@version v0.8.0
@author Bosn(霍雍), wangjeaf(思竹)
@weibo http://weibo.com/bosn, http://github.com/wangjeaf
@mail [email protected], [email protected]
Expand Down
1 change: 1 addition & 0 deletions UPDATELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
### rap v0.8 ###
* [功能] 增加新建项目默认模块、请求和参数 2014-02-12
* [功能] 增加jQuery/Kissy插件,更好的使用RAP MOCK 2014-01-14
* [BUG] 修复JSON导入最外层为数组时失效的问题 2014-01-14
* [重构] 修复JSHint提出的N多个rap.js中的编码规范问题 2014-01-14
Expand Down
12 changes: 11 additions & 1 deletion WebContent/stat/js/core/rap.js
Original file line number Diff line number Diff line change
Expand Up @@ -1004,6 +1004,9 @@ var rap = rap || {};
return _data.moduleList.length === 0;
};


p.generateId = generateId;

/**
* reset parameter id recursively
* including child parameters
Expand Down Expand Up @@ -1239,7 +1242,11 @@ var rap = rap || {};
};

ws._getData = function() {
return _data;
return p.getData();
};

ws.generateId = function() {
return p.generateId();
};

/**
Expand Down Expand Up @@ -1922,6 +1929,9 @@ var rap = rap || {};
var obj = JSON.parse(response);
if (obj.isOk) {
storeViewState();
if (obj.projectData.moduleList.length === 0) {
obj.projectData.moduleList = [{"id":ws.generateId(),"name":"某模块","introduction":"","pageList":[{"moduleId":ws.generateId(),"name":"某页面","introduction":"","id":ws.generateId(),"isIdGenerated":true,"actionList":[{"pageId":ws.generateId(),"name":"某请求","requestType":"1","requestUrl":"","responseTemplate":"","description":"","id":ws.generateId(),"requestParameterList":[{"id":ws.generateId(),"identifier":"reqParam","name":"某请求参数","remark":"","validator":"","dataType":"number","parameterList":[]}],"responseParameterList":[{"id":ws.generateId(),"identifier":"resParam","name":"某响应参数","remark":"","validator":"","dataType":"number","parameterList":[]}]}]}]}];
}
p.init(obj.projectData);
_data.projectDataOriginal = b.object.clone(obj.projectData);
setButtonsViewState(CONST.EDIT);
Expand Down
2 changes: 1 addition & 1 deletion WebContent/tcom/const.inc.vm
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#set($dateFormat = 'yyyy-MM-dd')

## 时间戳
#set($timeStamp = '20140115.v0.7')
#set($timeStamp = '20140212.v0.8')

##----------------------页面请求action地址-------------------------------
## 配置工程的上下文路径
Expand Down
4 changes: 2 additions & 2 deletions WebContent/tcom/template.rap.vm
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div class="navbar navbar-fixed-top navbar-inverse" role="navigation">
<div class="container">
<div class="navbar-header">
<a class="navbar-brand" href="http://rap.alibaba-inc.com">RAP V0.7</a>
<a class="navbar-brand" href="http://rap.alibaba-inc.com">RAP V0.8</a>
</div>
<div class="collapse navbar-collapse">
<ul class="nav navbar-nav">
Expand Down Expand Up @@ -58,7 +58,7 @@
<a class="btn btn-navbar" data-toggle="collapse"
data-target=".nav-collapse"> <span class="icon-bar"></span> <span
class="icon-bar"></span> <span class="icon-bar"></span>
</a> <a class="brand" href="http://rap.alibaba-inc.com">RAP v0.7</a>
</a> <a class="brand" href="http://rap.alibaba-inc.com">RAP v0.8</a>
<div class="nav-collapse collapse">
<ul class="nav">
<li><a href="$platformUrl.home">首页</a></li>
Expand Down
9 changes: 8 additions & 1 deletion WebContent/workspace/myWorkspace.vm
Original file line number Diff line number Diff line change
Expand Up @@ -279,8 +279,15 @@
"pageTester" : "$testerUrl.pageTester"
},
ws = rap.workspace,
data = $workspaceJsonString,
util = rap.util;
ws.init($workspaceJsonString, urlObj);

if (data.projectData.moduleList.length === 0) {
data.projectData.moduleList = [{"id":ws.generateId(),"name":"某模块","introduction":"","pageList":[{"moduleId":ws.generateId(),"name":"某页面","introduction":"","id":ws.generateId(),"isIdGenerated":true,"actionList":[{"pageId":ws.generateId(),"name":"某请求","requestType":"1","requestUrl":"","responseTemplate":"","description":"","id":ws.generateId(),"requestParameterList":[{"id":ws.generateId(),"identifier":"reqParam","name":"某请求参数","remark":"","validator":"","dataType":"number","parameterList":[]}],"responseParameterList":[{"id":ws.generateId(),"identifier":"resParam","name":"某响应参数","remark":"","validator":"","dataType":"number","parameterList":[]}]}]}]}];
}


ws.init(data, urlObj);

/**
* loading hint
Expand Down

0 comments on commit 2e86acd

Please sign in to comment.