<!--#include file="../checkLogin.asp"-->
<!--#include file="../SQLconn.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"/>
</head>

<% cid=request("cid")
   dtondate=request("dtondate")
   CAL_HOUR=request("CAL_HOUR")
   CAL_MIN=request("CAL_MIN")
    
  
   title=request("title")
   CONTENT=request("CONTENT")
   
   
   
   set RsPlan=server.createobject("adodb.recordset")
   
       if cid="" then 
          RsPlansql="select * from CalendarPlan where (cid is null)" 
          RsPlan.open RsPlansql,conn,1,3
          RsPlan.addnew
	   else
	      set RsPlan=server.createobject("adodb.recordset")
          RsPlansql="select * from CalendarPlan where   cid='"&cID&"'"
          RsPlan.open RsPlansql,conn,1,3  
	   end if 

       RsPlan("curDate")=dtondate
	  
	   RsPlan("beginTime")=CAL_HOUR&":"&CAL_MIN
	
	  
	   RsPlan("PlanType")="个人事务"
	   RsPlan("title")=title
	   RsPlan("planValue")=CONTENT
	   RsPlan("planMan")=request.cookies("tname")
	   RsPlan("username")=request.cookies("tname")
	   RsPlan("begindatetime")=dtondate&" "&CAL_HOUR&":"&CAL_MIN&":00"

       RsPlan.update
       RsPlan.close
	  
  
	   set RsPlan=nothing  
	   conn.close
	   set conn=nothing
	  response.redirect   "manage.asp?dtondate="&dtondate
%>
<script language="Jscript">{   //刷新母窗口
       window.opener.location.reload();} 
 </script>
 

<div align="center" title="提示信息框">
<span style="BACKGROUND:#EEEEFF;COLOR:#FF6633;margin: 10px;border:1px dotted #FF6633;font-weight:bold;padding:8px;width=140">
保存成功</span>
</div>
<br><center>
  <p>&nbsp;</p>
  <p>
    <input type="button" class="topanniu" value="继续新建" onClick="location='newplan.asp?dtondate=<%=dtondate%>'">
    &nbsp;&nbsp;
    <input type="button" class="topanniu" value="关闭" onClick="window.close();">
  </p>
</center><br>

</body>
</html>