环境是struts2
业务中store加载的时候不一定都是把整个form提交过去,有时候也不用创建一个动态的form来提交表单。
手动加入参数即可,在action里面有get set就可以获取了。
代码示例:
var conditionstr = document.getElementById("inputcondition").value;
store.on('beforeload', function (store, options){
var params = {sthecstr:conditionstr};
Ext.apply(options.params, params);
});
sthecstr就是action里面的属性名称,要有getSthecstr()和setSthecstr()函数即可