Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

203 lines
6.0 KiB

  1. <%@LANGUAGE=javascript%>
  2. <!--#INCLUDE FILE='Global_DBUtils.asp' -->
  3. <!--#include file='global_serverutils.asp'-->
  4. <%
  5. if ( Session("Authenticated") != "Yes" )
  6. Response.Redirect("privacy/authentication.asp?../DBGPortal_Main.asp?" + Request.QueryString() )
  7. %>
  8. <head>
  9. <link rel="stylesheet" TYPE="text/css" HREF="/main.css">
  10. <link rel="stylesheet" TYPE="text/css" HREF="/CustomStyles.css">
  11. </head>
  12. <body bgcolor='#ffffff' topmargin='0' leftmargin='0' marginheight='0' marginwidth='0' tabindex='0'>
  13. <table id='tblNoFollowup' style='display:none'>
  14. <tr>
  15. <td>
  16. <p class='clsPTitle'>Display Follow-Up Data</p>
  17. <p>
  18. You currently do not have any followup selected. Please select a followup by clicking
  19. the link on the left nav bar for the followup that you would like to view data for.
  20. </p>
  21. </td>
  22. </tr>
  23. </table>
  24. <%
  25. // Response.Write( Request.QueryString() )
  26. var MaxFrames = 40
  27. for ( var i = 0 ; i < MaxFrames ; i++ )
  28. {
  29. Response.Write("<a name='biFrame" + i + "'></a>\n" )
  30. //Response.Write("<a id='aframe1' href='#top' class='clsALinkNormal' style='display:none'>Back to top</a>\n" )
  31. //Response.Write("<a id='aframe1' href='#top' class='clsALinkNormal' style='display:none'></a>\n" )
  32. //Response.Write("<a name='aframe1' id='aframe1' class='clsALinkNormal' style='display:none'></a>\n" )
  33. //sponse.Write("<a id='aframe1' class='clsALinkNormal' style='display:none'></a>\n" )
  34. Response.Write("<a id='aFollowup" + i + "' class='clsALinkNormal' style='display:none'></a>\n" )
  35. Response.Write("<div id='divFrame' name='divFrame' style='display:none'></div>\n" )
  36. Response.Write("<iframe id='iframe1' frameborder='0' scrolling='no' width='99%' height='0%' src='' style='border-top:1px solid blue;display:none'></iframe>\n")
  37. }
  38. %>
  39. <script>
  40. var aliasList = window.parent.frames("sepLeftNav").fnGetSelectedFollowUps( "tblSelectedFollowups" )
  41. var groupList = window.parent.frames("sepLeftNav").fnGetSelectedFollowUps( "tblSelectedGroups" )
  42. //for ( element in groupList )
  43. //alert( groupList[element] )
  44. var UsedFrames = new Array()
  45. var UsedFrameCounter = 0
  46. var FrameList = new Array()
  47. var UsedFrameList = new Array()
  48. var UsedFrameType = new Array()
  49. fnCreateViews( aliasList, "0" )
  50. fnCreateViews( groupList, "1" )
  51. fnDisplayFrame()
  52. if ( UsedFrameList.length == 0 )
  53. document.all.tblNoFollowup.style.display='block'
  54. function fnCreateViews( AliasList, GroupFlag )
  55. {
  56. var AliasAlreadyUsed = false
  57. for( i in AliasList )
  58. {
  59. for( j in UsedFrameList )
  60. {
  61. if ( UsedFrameList[j] == AliasList[i] )
  62. AliasAlreadyUsed = true
  63. }
  64. if ( AliasAlreadyUsed == false )
  65. {
  66. UsedFrameList.push( AliasList[i] )
  67. UsedFrameType.push( GroupFlag )
  68. }
  69. AliasAlreadyUsed == false
  70. }
  71. }
  72. function fnDisplayFrame ()
  73. {
  74. var linkString = ""
  75. for( i in UsedFrameList )
  76. {
  77. linkString += "<a class='clsALinkNormal' href='#aFollowup" + i + "'>" + UsedFrameList[i] + "</a>&nbsp;&nbsp;"
  78. //linkString += "<a class='clsALinkNormal' href='#" + UsedFrameList[i] + "'>" + UsedFrameList[i] + "</a>&nbsp;&nbsp;"
  79. //linkString += "<a class='clsALinkNormal' href='#aframe1[" + i + "]'>" + UsedFrameList[i] + "</a>&nbsp;&nbsp;"
  80. }
  81. //alert ( linkString )
  82. for ( i in UsedFrameList )
  83. {
  84. if ( UsedFrameList[i].toString() == "All FollowUps" )
  85. {
  86. document.all.iframe1[i].src="DBGPortal_DisplayQuery.asp?<%=Request.QueryString()%>" + "&FrameID=" + i
  87. document.all.iframe1[i].style.height='2200px'
  88. //document.all.aframe1[i].innerText = UsedFrameList.toString()
  89. //document.all.aframe1[i].name=UsedFrameList[i]
  90. document.all.divFrame[i].innerHTML = linkString
  91. }
  92. else
  93. {
  94. document.all.iframe1[i].src="DBGPortal_Main.asp?Alias=" + UsedFrameList[i] + "&<%=Request.QueryString()%>&GroupFlag=" + UsedFrameType[i] + "&FrameID=" + i
  95. document.all.iframe1[i].style.height='1500px'
  96. //document.all.aframe1[i].innerText = UsedFrameList.toString()
  97. //document.all.aframe1[i].innerText = UsedFrameList.toString()
  98. //document.all.aframe1[i].href="#" + UsedFrameList[i]
  99. //document.all.aframe1[i].
  100. //document.all.aframe1[i].name=UsedFrameList[i]
  101. document.all.divFrame[i].innerHTML = linkString
  102. }
  103. document.all.iframe1[i].style.display='block'
  104. //document.all.aframe1[i].style.display='block'
  105. document.all.divFrame[i].style.display='block'
  106. }
  107. }
  108. function fnCreateViews2( AliasList, GroupFlag )
  109. {
  110. //clear the framelist, this is so we will remove unwanted frames.
  111. for ( var i=0 ; i < AliasList.length ; i ++ )
  112. {
  113. //if ( AliasList[i].checked == true )
  114. {
  115. FrameList[i] = AliasList[i].toString()
  116. }
  117. }
  118. //for ( element in FrameList)
  119. //alert( FrameList[element] )
  120. //Check our currently used frame list for any dupes, this way we won't reopen the same one.
  121. for ( i in UsedFrames )
  122. {
  123. var FrameInUse = false
  124. for ( j in FrameList )
  125. {
  126. if ( UsedFrames[i] == FrameList[j] )
  127. {
  128. FrameInUse = true
  129. FrameList[j] = ""
  130. }
  131. }
  132. if ( FrameInUse == false )
  133. {
  134. document.all.iframe1[i].style.display='none'
  135. document.all.aframe1[i].style.display='none'
  136. UsedFrames[i] = ""
  137. }
  138. }
  139. for ( i in FrameList )
  140. {
  141. alert( "Used frames: " + FrameList[i] )
  142. var AddedFrame = false
  143. for ( var j = 0 ; j < <%=MaxFrames%> ; j++ )
  144. {
  145. if ( (UsedFrames[j] == "" || typeof( UsedFrames[j] ) == "undefined") && AddedFrame == false && FrameList[i] != "" )
  146. {
  147. if ( FrameList[i].toString() == "All FollowUps" )
  148. document.all.iframe1[j].src="DBGPortal_DisplayQuery.asp?<%=Request.QueryString()%>"
  149. else
  150. document.all.iframe1[j].src="DBGPortal_Main.asp?Alias=" + FrameList[i] + "&<%=Request.QueryString()%>&GroupFlag=" + GroupFlag
  151. document.all.iframe1[j].style.height='100%'
  152. document.all.iframe1[j].style.display='block'
  153. document.all.aframe1[j].style.display='block'
  154. UsedFrames[j] = FrameList[i]
  155. AddedFrame = true
  156. }
  157. }
  158. }
  159. }
  160. </script>
  161. </body>