?? cailiao_in_compiles.asp
字號(hào):
<!--#include file="conn.asp"-->
<!--#include file="top.asp"-->
<!--#include file="checkuser.asp"-->
<head>
<style type="text/css">
<!--
.select {
color: #FFFFFF;
background-color: #08246b;
}
.offline {
filter: Gray;
}
-->
</style>
<title>∷企業(yè)生產(chǎn)管理信息系統(tǒng)::</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="css/main.css" rel="stylesheet" type="text/css">
<SCRIPT language=JavaScript src="css/User_Info_Modify.js"></SCRIPT>
</head>
<body >
<TABLE width=800 align=center border="0" cellspacing="0" cellpadding="0" bordercolor="#0055E6">
<tr><td align="center">
<%if request("action")<>"search" then%>
<table width="800" border="1" cellpadding="0" cellspacing="0" bordercolor="#0055E6" align="center">
<tr>
<td width="800" align="center" valign="top">
<table width="800" border="0" cellpadding="0" cellspacing="0" >
<tr >
<td height=26 background="images/background.gif">
<b><font color="#ffffff">詳細(xì)入庫信息查詢</font></b>
</td>
</tr>
</table>
<table width="800" border="0" cellpadding="0" cellspacing="0">
<form name="powersearch" method="post" action="cailiao_In_Compiles.asp?action=search" >
<tr><td width="20%" height="30" ><input type="checkbox" name="SeachModel" value=1>按分類</td><td>
<select name='fenlei' style='width:130'>
<option selected value="">請(qǐng)選擇類別</option>
<%
set rs1=server.createobject("adodb.recordset")
rs1.open "select * from fenlei",conn,1,1
if not rs1.eof then
do while not rs1.eof
%>
<option value="<%=rs1("fenleiname")%>"><%=rs1("fenleiname")%></option>
<%
rs1.movenext
loop
end if
rs1.close
set rs1=nothing
%></select></td><td width="20%"><input type="checkbox" name="SeachModel" value=2>按品名</td><td width="30%">
<input name="pinming" type="text" size="20">
</td>
</tr>
<tr>
<td><input type="checkbox" name=SeachModel value=4>按存儲(chǔ)倉庫</td>
<td><select name="Supplier" >
<%
set rs=server.createobject("adodb.recordset")
sql="select * from cailiaocangku"
rs.open sql,conn,1,1
if not rs.eof then
do while not rs.eof
%>
<option value="<%=rs("cangkuname")%>"><%=rs("cangkuname")%></option>
<%
rs.movenext
loop
rs.close
set rs=nothing
end if
%>
</select>
</td>
<td height="30" >
<input type="checkbox" name="SeachModel" value=3>按規(guī)格</td>
<td><input name="guige" type="text" size="20"></td>
</tr>
<tr><td height="30" ><input type="checkbox" name=SeachModel value=5>按入庫日期</td><td ><INPUT name="uptime" onFocus="show_cele_date(uptime,'','',uptime)" value="<%=year(now())%>-<%=month(now())%>-<%=day(now())%>" size="8"> 到 <INPUT name="uptime1" onFocus="show_cele_date(uptime1,'','',uptime1)" value="<%=year(now())%>-<%=month(now())%>-<%=day(now())%>" size="8"></td>
<td height="30" ><input type="checkbox" name=SeachModel value=6>按采購員</td>
<td><input name="caigouyuan" type="text" size="20"></td>
</tr>
<tr><td align="center" height="30" colspan="8"><input type="submit" name="Submit" value="查詢" style="font-size: 9pt; color: #000000; background-color: #EAEAF4; solid #EAEAF4" onMouseOver ="this.style.backgroundColor='#ffffff'" onMouseOut ="this.style.backgroundColor='#EAEAF4'" title="查詢"></td></tr>
</form>
</table>
</td>
</tr>
</table>
<br><br>
<TABLE width=800 align=center border="0" cellspacing="0" cellpadding="0" bordercolor="#0055E6">
<tr>
<td >
<table width="800" border="1" cellpadding="0" cellspacing="0" bordercolor="#0055E6" align="center">
<tr>
<td width="800" align="center" valign="top">
<table width="800" border="0" cellpadding="0" cellspacing="0" >
<tr >
<td height=26 background="images/background.gif">
<b><font color="#ffffff">單月入庫匯總查詢</font></b>
</td>
</tr>
</table>
<table width="90%" border="0" cellpadding="0" cellspacing="0" bordercolor="#D4D0C8">
<form name="powersearch" method="post" action="cailiao_In_Compiles.asp?action=search" >
<tr><td height="40" valign="middle" width="30%" align="center"><input type="checkbox" name=SeachModel value=7>選擇查詢?nèi)掌冢?個(gè)自然月) </td><td width="25%"> <INPUT name="uptime" onFocus="show_cele_date(uptime,'','',uptime)" value="<%=year(now())%>-<%=month(now())%>-<%=day(now())%>" size="8"> 到 <INPUT name="uptime1" onFocus="show_cele_date(uptime1,'','',uptime1)" value="<%=year(now())%>-<%=month(now())%>-<%=day(now())%>" size="8"></td><td height="30" width="50%"><input type="submit" name="Submit" value="查詢" style="font-size: 9pt; color: #000000; background-color: #EAEAF4; solid #EAEAF4" onMouseOver ="this.style.backgroundColor='#ffffff'" onMouseOut ="this.style.backgroundColor='#EAEAF4'" title="查詢"><font color=red>* 如:2007年10月則選擇2007-10-1到2007-10-31</font> </td></tr>
<tr ><td colspan="3" align=center></td></tr>
</form>
</table>
</td>
</tr>
</table>
<br><br>
<TABLE width=800 align=center border="0" cellspacing="0" cellpadding="0" bordercolor="#0055E6">
<tr>
<td >
<table width="800" border="1" cellpadding="0" cellspacing="0" bordercolor="#0055E6" align="center">
<tr>
<td width="800" align="center" valign="top">
<table width="800" border="0" cellpadding="0" cellspacing="0" >
<tr >
<td height=26 background="images/background.gif">
<b><font color="#ffffff">年度入庫匯總查詢</font></b>
</td>
</tr>
</table>
<table width="90%" border="0" cellpadding="0" cellspacing="0" bordercolor="#D4D0C8">
<form name="powersearch" method="post" action="cailiao_In_Compiles.asp?action=search" >
<tr><td height="40" valign="middle" width="30%" align="center"><input type="checkbox" name=SeachModel value=8>請(qǐng)輸入查詢年份 </td><td width="30%"> <INPUT name="nian" value="<%=year(now())%>" onKeyUp="value=value.replace(/[^\d\.]/g,'')" maxlength="4" size="6"> </td><td height="30" width="40%"><input type="submit" name="Submit" value="查詢" style="font-size: 9pt; color: #000000; background-color: #EAEAF4; solid #EAEAF4" onMouseOver ="this.style.backgroundColor='#ffffff'" onMouseOut ="this.style.backgroundColor='#EAEAF4'" title="查詢"></td></tr>
</form>
</table>
<%else%>
<%
dim SeachModel
SeachModel=request.form("SeachModel")
pinming=trim(request.form("pinming"))
Supplier=request.form("Supplier")
fenlei1=request.form("fenlei")
caigouyuan=request.form("caigouyuan")
guige=request.form("guige")
uptime=cstr(trim(request.form("uptime")))
uptime1=cstr(trim(request.form("uptime1")))
end_time=cstr(trim(request.form("end_time")))
end_time1=cstr(trim(request.form("end_time1")))
nian=cstr(trim(request.form("nian")))
'查詢代碼開始
names=Split(SeachModel,", ")
i=0
sql="select * from cailiao_In_Store where"
for each name in names
if names(i)="1" then
sql=sql+" and fenlei = '"&fenlei1&"'"
end if
if names(i)="5" then
sql=sql+" and uptime between #"&uptime&"# and #"&uptime1&"#"
end if
if names(i)="6" then
sql=sql+" and caigouyuan = '"&caigouyuan&"'"
end if
if names(i)="7" then
sql=sql+" and uptime between #"&uptime&"# and #"&uptime1&"#"
end if
if names(i)="8" then
sql=sql+" and year(uptime) = '"&nian&"'"
end if
if names(i)="2" then
sql=sql+" and pinming like '%"&pinming&"%'"
end if
if names(i)="4" then
sql=sql+" and Supplier = '"&Supplier&"'"
end if
if names(i)="3" then
sql=sql+" and guige = '"&guige&"'"
end if
i=i+1
next
sql=sql+" order by -id"
set rs=server.createobject("adodb.recordset")
sql=Replace(sql, "where and", "where")
%>
<table width="800" border="0" cellpadding="0" cellspacing="0" >
<tr >
<td height=26 background="images/background.gif">
<b><font color="#ffffff">查 詢 結(jié) 果 列 表</font></b>
</td>
</tr>
</table>
<table width="800" border="1" cellpadding="0" cellspacing="1" bordercolor="#EFEADD">
<tr class="but">
<td width="75" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">日期</td>
<td width="75" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">類 別</td>
<td width="100" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">品 名</td>
<td width="75" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">規(guī) 格</td>
<td width="50" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">單 位</td>
<td width="75" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">存儲(chǔ)倉庫</td>
<td width="125" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">購貨單位</td>
<td width="50" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">單價(jià)</td>
<td width="50" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">數(shù)量</td>
<td width="50" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">金額</td>
<td width="75" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">采購員</td>
</tr>
<tr valign="top">
<td colspan="12" align="center" class="iframe">
<table width="800" border="1" cellpadding="0" cellspacing="1" bordercolor="#EFEADD">
<%
dim i
i=0
use_num=0
use_Amount=0
rs.open sql,conn,1,1
if rs.eof and rs.bof then
response.write "<tr><td><br><br><center>還沒有符合條件的查詢!</center><br><br></td></tr>"
else
do while not rs.eof
i=i+1
%>
<tr onmouseover="this.bgColor='#73A475';" onmouseout="this.bgColor=''"">
<td height="18" width="75" align="center"><a href="cailiao_In_Store.Asp?id=<%=rs("ID")%>&action=edit"><%=rs("uptime")%></a></td>
<td width="75" align="center"><font color="#CC3300"><%=rs("fenlei")%></font><%if rs("fenlei")="" then%> <%end if%></td>
<td width="100" align="center"> <a href="cailiao_In_Store.Asp?id=<%=rs("ID")%>&action=edit"><font color="#000099"><%=rs("pinming")%></font></a></td>
<td width="75" align="center"> <%=rs("guige")%></td>
<td width="50" align="center"><font color="#009900"><%=rs("Unit")%></font><%if rs("Unit")="" then%> <%end if%></td>
<td width="75" align="center"> <font color="#666666"><%=rs("Supplier")%></font></td>
<td width="125" align="center"> <font color="#666666"><%=rs("gonghuodanwei")%></font></td>
<td width="50" align="center"><font color="#FF0000"><%=FormatCurrency(rs("use_price"),2,,,0)%></font><%if rs("use_price")="" then%> <%end if%></td>
<td width="50" align="center"><%=Formatnumber(rs("use_num"),2,-1,0,0)%></td>
<td width="50" align="center"><font color="#FF6600"><%=FormatCurrency(rs("use_Amount"),2,,,0)%></font> </td>
<td width="75" align="center"> <font color="#666666"><%=rs("caigouyuan")%></font></td>
</tr>
<%
use_num=use_num+rs("use_num")
use_Amount=use_Amount+rs("use_Amount")
rs.movenext
loop
end if
%>
<tr><td colspan="7" height="30"> 符合查詢條件的入庫記錄總共為 <font color="#cc0000"><%=i%></font> 條</td><td align="right">總計(jì):</td><td align="center"><font color="#cc0000">
<%=use_num%></font></td><td align="center"><font color="#cc0000"><%=use_Amount%></font></td><td> </td></tr>
</table>
</td>
</tr>
</table>
<br>
<table cellpadding="0">
<form name="search" method="post" action="cailiao_In_Detail.asp" target="_blank" >
<tr><td>
<input name="SeachModel" type="hidden" value="<%=SeachModel%>">
<input name="pinming" type="hidden" value="<%=pinming%>">
<input name="fenlei" type="hidden" value="<%=fenlei1%>">
<input name="guige" type="hidden" value="<%=guige%>">
<input name="Supplier" type="hidden" value="<%=Supplier%>">
<input name="caigouyuan" type="hidden" value="<%=caigouyuan%>">
<input name="uptime" type="hidden" value="<%=uptime%>">
<input name="uptime1" type="hidden" value="<%=uptime1%>">
<input name="end_time" type="hidden" value="<%=end_time%>">
<input name="end_time1" type="hidden" value="<%=end_time1%>">
<input name="nian" type="hidden" value="<%=nian%>">
<input type="submit" name="sub" value="生成明細(xì)表"></td></tr></form></table>
<%end if%>
</TD></TR>
</table>
</body>
</html>
<!--#include file="footer.htm"--></TD>
</BODY></HTML>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -