/beta/AR/Orders.asp

http://github.com/khaneh/Orders · ASP · 91 lines · 80 code · 7 blank · 4 comment · 8 complexity · fb3a7f58e7659a835d45d7886edbb558 MD5 · raw file

  1. <%@LANGUAGE="VBSCRIPT" CODEPAGE="1256"%><%
  2. Response.CacheControl="no-cache"
  3. Response.AddHeader "pragma", "no-cache"
  4. Server.ScriptTimeout = 600
  5. Response.Expires= -1
  6. if (session("ID")="") then
  7. session.abandon
  8. response.redirect "/default.asp?err=session expired"
  9. end if
  10. 'conStr="DRIVER={SQL Server};SERVER=(local);DATABASE=sefareshat;UID=sefadmin; PWD=5tgb;"
  11. 'conStr = "Provider=SQLNCLI10.1;Persist Security Info=False;User ID=sefadmin;Initial Catalog=jame;Data Source=.\sqlexpress;PWD=5tgb;"
  12. 'Set conn = Server.CreateObject("ADODB.Connection")
  13. 'conn.open conStr
  14. %>
  15. <!--#include File="../config.asp"-->
  16. <%
  17. function Link2Trace(OrderNo)
  18. Link2Trace="<A HREF='../order/orderEdit.asp?e=n&radif="& OrderNo & "' target='_balnk'>"& OrderNo & "</A>"
  19. end function
  20. %>
  21. <HTML>
  22. <HEAD>
  23. <meta http-equiv="Content-Type" content="text/html; charset=windows-1256">
  24. <meta http-equiv="Content-Language" content="fa">
  25. <style>
  26. Table { font-size: 9pt;}
  27. Input { font-family:tahoma; font-size: 9pt;}
  28. </style>
  29. <TITLE> </TITLE>
  30. </HEAD>
  31. <BODY>
  32. <font face="tahoma">
  33. <%
  34. if request("act")="select" then
  35. if request("customer") <> "" then
  36. SO_Customer=request("customer")
  37. SO_Action="return selectOperations();"
  38. SO_StepText="" '" : "
  39. if request("order") <> "" then
  40. thisOrder = " OR ID = " & request("thisorder")
  41. else
  42. thisOrder = ""
  43. end if
  44. %>
  45. <FORM METHOD=POST ACTION="">
  46. <!--#include File="include_SelectOrder.asp"-->
  47. </FORM>
  48. <%
  49. end if
  50. end if
  51. conn.Close
  52. %>
  53. </font>
  54. </BODY>
  55. </HTML>
  56. <script language="JavaScript">
  57. <!--
  58. function documentKeyDown() {
  59. var theKey = event.keyCode;
  60. if (theKey == 27) { // Esc
  61. // event.keyCode=0
  62. window.dialogArguments.value="[Esc]"
  63. window.close();
  64. }
  65. }
  66. document.onkeydown = documentKeyDown;
  67. function selectOperations(){
  68. var Arguments = new Array;
  69. argCounter=0
  70. for (i=0;i<document.getElementsByName("selectedOrders").length;i++){
  71. if(document.getElementsByName("selectedOrders")[i].checked){
  72. argCounter++;
  73. Arguments[argCounter]=document.getElementsByName("selectedOrders")[i].value;
  74. }
  75. }
  76. Arguments[0]=argCounter;
  77. myString=Arguments.join("#");
  78. // alert(myString)
  79. window.dialogArguments.value=myString
  80. window.close();
  81. return false;
  82. }
  83. //-->
  84. </script>