主页面通过showmodaldialog打开窗口
function a(id,affair_id,affair_name){
var url="<%=root%>/swsp/getAffairs"
var bizParams = {id:id,affair_id:affair_id,affair_name:affair_name};
$G.showmodaldialog("事务审批",url,840,640,bizParams,function(action){
grid.reload();
});
}
子页面代码
<form id="form1" action="xxx" method="post" target="upload_from_return">
</form>
<iframe name="upload_from_return" id="upload_from_return" display="none"> </iframe>
前台方法可以 renderHtml("<script>parent.callback(\"1\");</script>");
js方法
<script type="text/javascript">
var form = $G.get("form1");
form.submit();
function callback(msg){
$G.closemodaldialog("ok");
}
</script>