<!--#include file="../checkLogin.asp"-->
<!--#include file="../SQLconn.asp"-->
<!--#include file="nl.asp"--> 
<html>
<head>
<title>日程安排</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<link rel="stylesheet" type="text/css" href="../images/<%=request.cookies("imgdir")%>/css/style.css" media="all"/>
<script Language=JavaScript>
 
function inputshi(shi)
{
form1.CAL_HOUR.value=shi;	
		
}
function inputfen(fen)
{
form1.CAL_MIN.value=fen;	
		
}
function my_note(CAL_ID)
{
  window.open("Mynote.asp?ciD="+CAL_ID,'_blank',"height=250,width=250,status=0,toolbar=no,menubar=no,location=no,left=300,top=200,scrollbars=auto,resizable=no");
}
function form_check(){
   if(document.form1.CAL_HOUR.value.length<1){window.alert("请输入时间：点");document.form1.CAL_HOUR.focus();return (false);}
    if(document.form1.CAL_MIN.value.length<1){window.alert("请输入时间：分");document.form1.CAL_MIN.focus();return (false);}
    if(document.form1.title.value.length<1){window.alert("请输入标题");document.form1.title.focus();return (false);}
}



</script>
<style type="text/css">
<!--
.STYLE2 {font-size: 14}
-->
</style>
</head>
<body class="bodycolor" topmargin="5">
<%   
   dtondate=request("dtondate")
   cid=request("cid")
   username=request.cookies("tname")
   
 set RsPlan=server.createobject("adodb.recordset")
     RsPlansql="select * from CalendarPlan where cid='"&cID& "'"
     RsPlan.open RsPlansql,conn,1,1
     dim str1
     str1=split(RsPlan("begintime"),":",-1,1)
%>


<div align="center">
<br>
 <table width="95%" align="center" border="0" cellpadding="3"   cellspacing="0"  bordercolor="#6D8DD8"  >   
  <form action="saveplan.asp"  method="post" name="form1" onSubmit="return form_check();">
    <tr>
      <td height="24" colspan="4" nowrap class="STYLE1"><span class="Big">新建事务（<%=dtondate%>）
        <span class="STYLEDATE"><%=nl(dtondate)%></span></span>
        <!-------------- 时 ------------></td>
      </tr>
    <tr>
      <td width="4%" height="24" nowrap class="STYLE1"><div align="right">时&nbsp;&nbsp;针：</div></td>
      <td colspan="3" class="STYLE1">
	    <input name="CAL_HOUR" type="text" class="text"  id="CAL_HOUR" size="2" maxlength="2" onBlur='this.style.backgroundColor="#FFFFFF"' style="WIDTH: 30px"   onFocus='this.style.backgroundColor="#FFFADF"'  value=<%=str1(0)%>>
点
<% for i=0 to 23  %>
	    <span class="STYLEmian STYLE2"><a href="#" class="STYLE5" onClick="javascript:inputshi('<%=i%>');return false;"><%=i%></a></span>&nbsp;
	  <%next%>	 </td>
    </tr>
    <tr>
      <td height="24" nowrap class="STYLE1"><div align="right">分&nbsp;&nbsp;针：</div></td>
      <td colspan="3" class="STYLE1"><input name="CAL_MIN" type="text" class="text" id="CAL_MIN" style="WIDTH: 30px" 
      onFocus='this.style.backgroundColor="#FFFADF"' onBlur='this.style.backgroundColor="#FFFFFF"' size="2" maxlength="2"  value=<%=str1(1)%>>
分
   <span class="STYLEmian STYLE2"><a href="#" class="STYLE5" onClick="javascript:inputfen('00');return false;">00</a></span>&nbsp;
   <span class="STYLEmian STYLE2"><a href="#" class="STYLE5" onClick="javascript:inputfen('05');return false;">05</a></span>&nbsp;
  <% for i=10 to 55 step 5 %>
	    <span class="STYLEmian STYLE2"><a href="#" class="STYLE5" onClick="javascript:inputfen('<%=i%>');return false;"><%=i%></a></span>&nbsp; 
	  <%next%></td>
    </tr>
    <tr>
      <td height="24" nowrap class="STYLE1"><div align="right">提醒标题</div></td>
      <td width="22%" class="STYLE1"><label>
        <input name="title" type="text" class="text" id="title" size="10" maxlength="10" onBlur='this.style.backgroundColor="#FFFFFF"' style="WIDTH: 220px"   onFocus='this.style.backgroundColor="#FFFADF"'  value=<%=RsPlan("title")%>>
</label></td>
      <td colspan="2" class="STYLE1">&nbsp;</td>
    </tr>
    <tr>
      <td nowrap class="STYLE1"><div align="right">详细说明</div></td>
      <td class="STYLE1"><textarea name="CONTENT" cols="45" rows="3" class="text" onblur='this.style.backgroundColor="#FFFFFF"' style="WIDTH: 220px" 
      onfocus='this.style.backgroundColor="#FFFADF"'><%=RsPlan("planvalue")%></textarea>      </td>
      <td width="74%" class="STYLE1"><span class="mtdtl">
	     <%if cid="" then%>
           <input name="submit" type="submit" class="topanniu" value="新增保存">
		 <%else%>
		  <input name="submit" type="submit" class="topanniu" value="保存修改">
		 <%end if%>
		  
        <input type="hidden" name="dtondate" value=<%=dtondate%>>
		<input type="hidden" name="cid" value=<%=cid%>>
      </span></td>
    </tr>
  </form>
</table>
</div>

			

  <%   
   Set    MyOAASPObj = Server.CreateObject("YFSchoolOApro.YFSchoolDll")
  call    MyOAASPObj. CalerdarManage(dtondate,username,nl(dtondate))
      set MyOAASPObj=nothing   
  %>
                     
               
			   
 
    <div align="center">
<br>
<input type="button"  value="返回" class="topanniu" onClick="location='calendar.asp?currentDate=<%=dtondate%>';">
</div>
 
</body>
</html>