一个用java编写的功能强大的OA系统

源代码在线查看: scheduler_add.jsp

软件大小: 32919 K
上传用户: l550253832
关键词: java OA系统 编写
下载地址: 免注册下载 普通下载 VIP

相关代码

				
												 java.text.*,
								 cn.js.fan.util.*,
								 com.redmoon.oa.flow.*,
								 cn.js.fan.cache.jcs.*,
								 cn.js.fan.web.*,
								 com.redmoon.oa.pvg.*,
								 com.redmoon.oa.kernel.*,
								 com.redmoon.oa.job.*,
								 com.cloudwebsoft.framework.base.*"
				%>
				
				
				
				
				
				function findObj(theObj, theDoc)
				{
				  var p, i, foundObj;
				  
				  if(!theDoc) theDoc = document;
				  if( (p = theObj.indexOf("?")) > 0 && parent.frames.length)
				  {
				    theDoc = parent.frames[theObj.substring(p+1)].document;
				    theObj = theObj.substring(0,p);
				  }
				  if(!(foundObj = theDoc[theObj]) && theDoc.all) foundObj = theDoc.all[theObj];
				  for (i=0; !foundObj && i < theDoc.forms.length; i++) 
				    foundObj = theDoc.forms[i][theObj];
				  for(i=0; !foundObj && theDoc.layers && i < theDoc.layers.length; i++) 
				    foundObj = findObj(theObj,theDoc.layers[i].document);
				  if(!foundObj && document.getElementById) foundObj = document.getElementById(theObj);
				  
				  return foundObj;
				}
				
				function SelectDateTime(objName) {
					var dt = showModalDialog("../util/calendar/time.htm", "" ,"dialogWidth:266px;dialogHeight:185px;status:no;help:no;");
					if (dt!=null)
						findObj(objName).value = dt;
				}
				
				function form1_onsubmit() {
					var t = form1.time.value;
					var ary = t.split(":");
					var weekDay = getCheckboxValue("weekDay");
					var dayOfMonth = form1.month_day.value;
					if (weekDay=="" && dayOfMonth=="") {
						alert("请填写每月几号或者星期几!");
						return false;
					}
					if (weekDay=="")
						weekDay = "?";
					if (ary[2].indexOf("0")==0 && ary[2].length>1)
						ary[2] = ary[2].substring(1, ary[2].length);
					if (ary[1].indexOf("0")==0 && ary[1].length>1)
						ary[1] = ary[1].substring(1, ary[1].length);
					if (ary[0].indexOf("0")==0 && ary[0].length>1)
						ary[0] = ary[0].substring(1, ary[0].length);
					if (dayOfMonth=="")
						dayOfMonth = "?";
					var cron = ary[2] + " " + ary[1] + " " + ary[0] + " " + dayOfMonth + " * " + weekDay;
					form1.cron.value = cron;
					if (form1.flowCode.value=="not") {
						alert("请选择流程!");
						return false;
					}
					form1.data_map.value = form1.flowCode.value;
				}
				
				function trimOptionText(strValue) 
				{
					// 注意option中有全角的空格,所以不直接用trim
					var r = strValue.replace(/^ *|\s*|\s*$/g,"");
					return r;
				}
				
				
								String priv="admin";
				if (!privilege.isUserPrivValid(request,priv)) {
				    out.print(cn.js.fan.web.SkinUtil.makeErrMsg(request, cn.js.fan.web.SkinUtil.LoadString(request, "pvg_invalid")));
					return;
				}
				
				String op = ParamUtil.get(request, "op");
				
				if (op.equals("add")) {
					QObjectMgr qom = new QObjectMgr();
					JobUnitDb ju = new JobUnitDb();
					try {
					if (qom.create(request, ju, "scheduler_add"))
						out.print(StrUtil.Alert_Redirect(SkinUtil.LoadString(request, "info_op_success"), "scheduler_list.jsp"));
					else
						out.print(StrUtil.Alert_Back(SkinUtil.LoadString(request, "info_op_fail")));
					}
					catch (ErrMsgException e) {
						out.print(StrUtil.Alert_Back(e.getMessage()));
					}
				}
				%>
				
				  
				    
				      添加调度  调度中心
				    
				  
				
				
								style="BORDER-RIGHT: #a6a398 1px solid; BORDER-TOP: #a6a398 1px solid; BORDER-LEFT: #a6a398 1px solid; BORDER-BOTTOM: #a6a398 1px solid" 
				cellSpacing=0 cellPadding=3 width="95%" align=center>
				  
				  
				    
				       
				    
				    
				      
					             
				        
						
				          
				            调度流程
				          
				          
				            选择流程:
				              
				              									Leaf lf = new Leaf();
									lf = lf.getLeaf("root");
									DirectoryView dv = new DirectoryView(lf);
									dv.ShowDirectoryAsOptions(request, out, lf, 1);
								  %>
				            
							
							名称:
							
							 每月:
							号
				          
				          
				            
				开始时间
				
				  
				在
				
				星期日
				
				星期一
				
				星期二
				
				星期三
				
				星期四
				
				星期五
				
				星期六 
				
				
				
				
				          
				        
				        
				      
				    
				    
				       
				    
				  
				
							

相关资源