<!--#INCLUDE FILE="../HXINCLUDE/HXINCLUDEHEAD.ASP"-->
<%ColumnName="":Tablename="HX_SchEduleMain":Tablename1="HX_SchEduleAdd"
if request("yy")="" then yy=cint(year(now())) else  yy=cint(request("yy"))
if request("mm")="" then mm=cint(month(now())) else  mm=cint(request("mm"))
if request("dd")="" then dd=cint(day(now())) else  dd=cint(request("dd"))
today=dateserial(yy,mm,dd)
l=weekday(today,"2")
do while l<>1
today=dateadd("d",-1,today)
l=weekday(today,"2")
loop 
response.write "<head><meta http-equiv='Content-Type' content='text/html; charset=gb2312'><title>按周查看</title><link rel=stylesheet type=text/css href='../HXinclude/HX_Style.css'><script src='../HXinclude/HX_Function.js'></script></head><body topmargin='20' leftmargin='0' bottommargin='0'><table width='700'  border='0' cellspacing='1' cellpadding='0' align=center bgcolor='#613c25'><tr><td colspan='2' bgcolor=FFFBE8 background='../hximages/titlelinebg.gif'><table width='580'  border='0' cellspacing='0' cellpadding='0'><tr><td height='25' background='../hximages/titleline.gif'><font class='fontmenu'>按周查看</font>　　　　　　　"&msg&"</td></tr></table><table width='100%'  border='0' cellspacing='1' cellpadding='3' bgcolor=FFFBE8><tr><td height='20' colspan='2' align='center'><a href='?yy="&yy&"&mm="&mm&"&dd="&dd-7&"'><font color='#431E07'>上一周</font></a> "&year(today)&"年"&month(today)&"月[<font color='#FF3300'>日程安排</font>] <a href='?yy="&yy&"&mm="&mm&"&dd="&dd+7&"'><font color='#431E07'>下一周</font></a></td></tr><tr bgcolor='#BF9B73' class='td4'><td colspan='2' height='2'></td></tr>"
for i=1 to 7
 k=i-weekday(today,"2")
 Orderby=" where WS_SchEduleMainman="&loginuid&" and (year(WS_SchEduleMainFirstTime)<"&year(dateadd("d",k,today))&" or (year(WS_SchEduleMainFirstTime)="&year(dateadd("d",k,today))&" and month(WS_SchEduleMainFirstTime)<"&month(dateadd("d",k,today))&") or (year(WS_SchEduleMainFirstTime)="&year(dateadd("d",k,today))&" and month(WS_SchEduleMainFirstTime)="&month(dateadd("d",k,today))&" and day(WS_SchEduleMainFirstTime)<="&day(dateadd("d",k,today))&")) and (year(WS_SchEduleMainLastTime)>"&year(dateadd("d",k,today))&" or (year(WS_SchEduleMainLastTime)="&year(dateadd("d",k,today))&" and month(WS_SchEduleMainLastTime)>"&month(dateadd("d",k,today))&") or (year(WS_SchEduleMainLastTime)="&year(dateadd("d",k,today))&" and month(WS_SchEduleMainLastTime)="&month(dateadd("d",k,today))&" and day(WS_SchEduleMainLastTime)>="&day(dateadd("d",k,today))&")) order by WS_SchEduleMainFirstTime desc"
 set rs=WS_S.HX_SetRSD(ColumnName,Tablename,Orderby)
 response.write "<tr bgcolor='#FFFBE8' onmouseover=javascript:this.bgColor='#F9F8F2' onmouseout=javascript:this.bgColor='#FFFBE8'><td height='23'>"&weekdayname(i,false,2)&"("&dateadd("d",k,today)&")</td><td width='67%' height='23'><table width='100%'  border='0' cellspacing='0' cellpadding='0'>"
 if rs.recordcount>0 then
  do until rs.eof
   response.write "<tr><td><font title='内容预览："&left(rs("WS_SchEduleMainMemo"),100)&"' >&nbsp;<a href='SchEduleModify.asp?WS_SMID="&rs("WS_SMID")&"'><font color='#431E07'>"&left(rs("WS_SchEduleMainTitle"),30)&"</font></a></font>"
	Orderby=" where WS_SMID="&rs("WS_SMID")
      set prs=WS_S.HX_SetRSD(ColumnName,Tablename1,Orderby)
         if prs.recordcount>0 then
		 response.Write "<img src='../HXimages/add.gif' width='9' height='9' alt='有追加内容'>" 
          end if
				  response.write "<font color=red>("&rs("WS_SchEduleMainSituation")&")</font><font color='#000000'>所属："
				  Call WS_S.HX_OutUserInfo(rs("WS_SchEduleMainman")):response.Write OutName
				  response.write "</font></td></tr>"
    rs.movenext
	loop
	end if
	response.write "</table></div></td></tr>"
    today=dateadd("d",1,today)   
    next
call WS_S.HX_RSClose(prs):call WS_S.HX_RSClose(rs)
response.write "</table></td></tr></table>"%>