|
楼主 |
发表于 2016-12-6 11:08:01
|
显示全部楼层
我加了参数,然后把list加载baasdata数据源的操作防到moadload里,想在页面刚打开的时候就能显示,但是发现参数没能传过去,控制台报的得到的参数是null
Baas.sendRequest({
"url" : "/gems/operation",
"action" : "getcardinfo",
"params" : {
begintime : this.getElementByXid('input9').value,
endtime:this.getElementByXid('input10').value,
},
"success" :function(result) { if (result.state) {
mainData.loadData(result.response); mainData.first();
mainData.refreshData(); } }
后台java写的是:
public static JSONObject getcardinfo(JSONObject params, ActionContext context) throws SQLException, NamingException {
Connection conn = context.getConnection(DATASOURCE_jiudian);
String begintime = params.getString("begintime");
String endtime = params.getString("endtime");
String xm = params.getString("xm");
String sfz = params.getString("sfz");
String dm = params.getString("dm");
……
}
提示begintime为null
|
|