1、填报表自动提交;2、提交后可支持跳转到其他页面。
针对问题 1:可以定义 js 定时器,结合润乾填报表的提交函数,由系统完成提交动作。具体为:
<%
longcurrent_time=System.currentTimeMillis();
longend_time=0;
longtime=1800000;
%>
针对问题 2:对提交后保存成功的动作监听, 可以通过重写 js 方法的方式来实现,具体方式为:
<scriptlanguage=“JavaScript”>
// 固定的方法,当填报表保存成功后回调
var inputApi = {};
inputApi.saveSuccess= function(){
alert(“保存成功!”);
// 调用自己的方法处理自己的需求,如此处是关闭当前页,并兼容所有浏览器。如果要实现到其他地址的跳转,直接通过 js 实现即可。
closeWebPage();
}
function closeWebPage(){
if(navigator.userAgent.indexOf(“MSIE”) > 0) {//close IE
if(navigator.userAgent.indexOf(“MSIE 6.0”) > 0) {
window.opener = null;
window.close();
}else {
window.open('', ‘_top’);
window.top.close();
}
}
elseif (navigator.userAgent.indexOf(“Firefox”) > 0) {//closefirefox
window.location.href = ’about:blank ’;
}else if(navigator.userAgent.indexOf(“Chrome”) > 0) {//close chrome
window.location.href = ‘about:blank ‘;
}else {//close chrome;It is effective when it is only one.
window.opener = null;
window.open(’’, ‘_self’);
window.close();
}
}
**粗体** _斜体_ [链接](http://example.com) `代码` - 列表 > 引用
。你还可以使用@
来通知其他用户。