Reorganization.asp
上传用户:apresys
上传日期:2021-03-30
资源大小:813k
文件大小:7k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

DOS

  1. <!--#include file="conn.asp"-->
  2. <!--#include file="checkuser.asp"-->
  3. <html>
  4. <head>
  5. <title>∷汽车4S店配件仓储管理系统:.</title>
  6. <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
  7. <link href="css/main.css" rel="stylesheet" type="text/css">
  8. <SCRIPT language=JavaScript src="css/User_Info_Modify.js"></SCRIPT>
  9. <style type="text/css">
  10. <!--
  11. td {  font-family: "宋体"; font-size: 9pt}
  12. body {  font-family: "宋体"; font-size: 9pt}
  13. select {  font-family: "宋体"; font-size: 9pt}
  14. A {text-decoration: none; color: #336699; font-family: "宋体"; font-size: 9pt}
  15. A:hover {text-decoration: underline; color: #FF0000; font-family: "宋体"; font-size: 9pt} 
  16. -->
  17. </style>
  18. <SCRIPT LANGUAGE=javascript>
  19. <!--
  20. function Juge(powersearch)
  21. {
  22. if (powersearch.pinming.value == "")
  23. {
  24. alert("名称不能为空!");
  25. powersearch.pinming.focus();
  26. return (false);
  27. }
  28. }
  29. function SelectAll() {
  30. for (var i=0;i<document.selform.selBigClass.length;i++) {
  31. var e=document.selform.selBigClass[i];
  32. e.checked=!e.checked;
  33. }
  34. }
  35. //-->
  36. </script>
  37. </HEAD>
  38. <BODY topMargin=0 rightMargin=0 leftMargin=0>       
  39. <!--#include file="top.asp"-->
  40. <%
  41.   select case request("action")
  42.   case "add"
  43.        call SaveAdd()
  44.   case "modify"
  45.        call SaveModify()
  46.   case "del"
  47.        call delCate()
  48.   case "edit"
  49.        isEdit=True
  50.        call myform(isEdit)
  51.   case else
  52.        isEdit=False
  53.        call myform(isEdit) 
  54.   end select
  55.  
  56. sub delCate()
  57. conn.execute("delete from Reorganization where id in ("&Request.Form("selBigClass")&")")
  58. response.Write "<script language=javascript>alert('删除成功!');</script>"
  59. response.write "<meta http-equiv=""refresh"" content=""0;url=baosun.asp"">"
  60. response.end
  61.   end sub
  62.   %> <% sub myform(isEdit) %>    
  63. <TABLE width=800 align=center border="1" cellspacing="0" bordercolor="#D6D3CE">
  64.   <TBODY> 
  65.   <TR> 
  66.     <td align="center" valign="top"> 
  67.       <TABLE cellSpacing=1 cellPadding=0 width="100%" border=0 >
  68.         <TR>
  69.           <TD height="25" align="center">调拨信息</TD>
  70.               </TR>
  71.             </TABLE>
  72. <form action="Reorganization.asp" method="post" name="selform" >
  73.   <table width="100%"  border="1" cellpadding="0" cellspacing="0" bordercolor="#D4D0C8" align="center">
  74.     <tr> 
  75.       
  76.       <td width="100%" align="center" valign="top">
  77.   <fieldset style="width:100%">
  78.         <table width="100%" border="0" cellpadding="0" cellspacing="0" bordercolor="#D4D0C8">
  79.           <tr class="but"> 
  80. <td width="10%" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">调拨日期</td>
  81.             <td width="20%" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">配件名称 / 规格</td>
  82. <td width="10%" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">数 量</td>
  83. <td width="10%" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">调拨自</td>
  84. <td width="6%" height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">调拨到</td>
  85.           </tr>
  86.  <%
  87. PageShowSize = 10            '每页显示多少个页
  88. MyPageSize   = 20          '每页显示多少条
  89. If Not IsNumeric(Request("page")) Or IsEmpty(Request("page")) Or Request("page") <=0 Then
  90. MyPage=1
  91. Else
  92. MyPage=Int(Abs(Request("page")))
  93. End if
  94. set rs=server.CreateObject("ADODB.RecordSet") 
  95. rs.Source="select * from Reorganization order by -id"
  96. rs.Open rs.Source,conn,1,1
  97. if not rs.EOF then
  98. rs.PageSize     = MyPageSize
  99. MaxPages         = rs.PageCount
  100. rs.absolutepage = MyPage
  101. total            = rs.RecordCount
  102. for i=1 to rs.PageSize
  103. if not rs.EOF then
  104. %>
  105. <tr><td height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'"><input name="selBigClass" type="checkbox" id="selBigClass" value="<%=rs("ID")%>"><%=rs("uptime")%></td>
  106. <td height="18" align="center" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'"><%=getmaterial(rs("material_id"))%></td>
  107. <td height="18" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">&nbsp;<%=rs("num")%></td>
  108. <td height="18" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">&nbsp;<%=rs("from_storage")%></td>
  109. <td height="18" class="but" onMouseDown="this.className='tddown'" onMouseUp="this.className='but'" onMouseOut="this.className='but'">&nbsp;<%=rs("to_storage")%></td>
  110. </tr>
  111. <%
  112. rs.MoveNext
  113. end if
  114. next
  115. end if
  116. %>
  117. <tr><td align="right" colspan="10" height="22">
  118. 共 <%=total%> 条,当前第 <%=Mypage%>/<%=Maxpages%> 
  119.             页,每页 <%=MyPageSize%> 条 
  120.             <%
  121.             url="Reorganization.asp?"
  122. PageNextSize=int((MyPage-1)/PageShowSize)+1
  123. Pagetpage=int((total-1)/rs.PageSize)+1
  124. if PageNextSize >1 then
  125. PagePrev=PageShowSize*(PageNextSize-1)
  126. Response.write "<a class=black href='" & Url & "page=" & PagePrev & "' title='上" & PageShowSize & "页'>上一翻页</a> "
  127. Response.write "<a class=black href='" & Url & "page=1' title='第1页'>页首</a> "
  128. end if
  129. if MyPage-1 > 0 then
  130. Prev_Page = MyPage - 1
  131. Response.write "<a class=black href='" & Url & "page=" & Prev_Page & "' title='第" & Prev_Page & "页'>上一页</a> "
  132. end if
  133. if Maxpages>=PageNextSize*PageShowSize then
  134. PageSizeShow = PageShowSize
  135. Else
  136. PageSizeShow = Maxpages-PageShowSize*(PageNextSize-1)
  137. End if
  138. If PageSizeShow < 1 Then PageSizeShow = 1
  139. for PageCounterSize=1 to PageSizeShow
  140. PageLink = (PageCounterSize+PageNextSize*PageShowSize)-PageShowSize
  141. if PageLink <> MyPage Then
  142. Response.write "<a class=black href='" & Url & "page=" & PageLink & "'>[" & PageLink & "]</a> "
  143. else
  144. Response.Write "<B>["& PageLink &"]</B> "
  145. end if
  146. If PageLink = MaxPages Then Exit for
  147. Next
  148. if Mypage+1 <=Pagetpage  then
  149. Next_Page = MyPage + 1
  150. Response.write "<a class=black href='" & Url & "page=" & Next_Page & "' title='第" & Next_Page & "页'>下一页</A>"
  151. end if
  152. if MaxPages > PageShowSize*PageNextSize then
  153. PageNext = PageShowSize * PageNextSize + 1
  154. Response.write " <A class=black href='" & Url & "page=" & Pagetpage & "' title='第"& Pagetpage &"页'>页尾</A>"
  155. Response.write " <a class=black href='" & Url & "page=" & PageNext & "' title='下" & PageShowSize & "页'>下一翻页</a>"
  156. End if
  157. rs.Close
  158. set rs=nothing
  159. %>&nbsp;&nbsp;&nbsp;&nbsp;<%if oskey="supper" or oskey="admin" then%>
  160.         <input type="checkbox" name="checkbox" value="checkbox" onClick="javascript:SelectAll()"> 选择/反选
  161.               <input onClick="{if(confirm('此操作将删除该信息!nn确定要执行此项操作吗?')){this.document.selform.submit();return true;}return false;}" type=submit value=删除 name=action2> 
  162.               <input type="Hidden" name="action" value='del'><%end if%></td></tr>
  163.         </table>
  164. </fieldset>
  165.   
  166. </td>
  167.     </tr>
  168.   </table>
  169. </form>
  170.   </TBODY>
  171. </TABLE>
  172. <%end sub%>
  173. <P>
  174. <TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>
  175.   <TBODY>
  176.   <TR vAlign=center>
  177.     <TD align=middle width="100%"><!--#include file="footer.htm"--></TD>
  178.   </TR></TBODY></TABLE></P></BODY></HTML>