UIPELauncher.htm 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. <!--
  2. Licensed Materials - Property of IBM
  3. IBM Cognos Products: uipe
  4. (C) Copyright IBM Corp. 2014
  5. US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  6. -->
  7. <html>
  8. <head>
  9. <meta http-equiv="x-ua-compatible" content="IE=5" >
  10. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
  11. <meta http-equiv="MSThemeCompatible" content="no"/>
  12. <meta http-equiv="imagetoolbar" content="no"/>
  13. <title>UIPE Launcher</title>
  14. <style>
  15. BODY
  16. {
  17. background-color: threedface;
  18. }
  19. BODY,
  20. INPUT,
  21. TABLE,
  22. SELECT
  23. {
  24. font-family: Arial;
  25. font-size: 10pt;
  26. }
  27. </style>
  28. <script>
  29. function CreateUIPEParameters()
  30. {
  31. var o = {};
  32. var v_sUIProfileStoreId = document.getElementById( "txtUIProfileStoreId" ).value;
  33. if ( v_sUIProfileStoreId )
  34. {
  35. o["uipe_UIProfileStoreID"] = v_sUIProfileStoreId;
  36. }
  37. var v_sUIProfileName = document.getElementById( "selUIProfile" ).options.item( document.getElementById( "selUIProfile" ).selectedIndex ).value;
  38. if ( v_sUIProfileName )
  39. {
  40. o["uipe_UIProfileName"] = v_sUIProfileName;
  41. }
  42. var v_sProductLocale = document.getElementById( "selProductLocale" ).options.item( document.getElementById( "selProductLocale" ).selectedIndex ).value;
  43. if ( v_sProductLocale )
  44. {
  45. o["uipe_productLocale"] = v_sProductLocale;
  46. }
  47. var v_sSkin = document.getElementById( "selSkin" ).options.item( document.getElementById( "selSkin" ).selectedIndex ).value;
  48. if ( v_sSkin )
  49. {
  50. o["uipe_skin"] = v_sSkin;
  51. }
  52. var sGateway = document.getElementById( "txtGateway" ).value;
  53. if ( sGateway )
  54. {
  55. o["ui.gateway"] = sGateway;
  56. }
  57. return o;
  58. }
  59. function GenerateQueryString()
  60. {
  61. var sURL = "?";
  62. var i = 0;
  63. for ( var s in UIPEParameters )
  64. {
  65. sURL += ( i++ > 0 ? "&" : "" ) + s + "=" + encodeURIComponent( UIPEParameters[s] );
  66. }
  67. return sURL;
  68. }
  69. function GenerateAppURL()
  70. {
  71. return document.getElementById( "txtUIPEPath" ).value;
  72. }
  73. function OnCopyClick()
  74. {
  75. UIPEParameters = CreateUIPEParameters();
  76. clipboardData.setData( "Text", GenerateAppURL() + GenerateQueryString() );
  77. }
  78. function OnLaunchClick()
  79. {
  80. UIPEParameters = CreateUIPEParameters();
  81. var sURL = GenerateAppURL();
  82. if ( !document.getElementById( "chkUseParameters" ).checked )
  83. {
  84. sURL += GenerateQueryString();
  85. delete UIPEParameters;
  86. }
  87. window.open( sURL, "_blank", "status=yes,toolbar=no,menubar=no,location=no,status=no" );
  88. }
  89. function OnLoad()
  90. {
  91. document.getElementById( "txtUIPEPath" ).value = document.location.href.replace(/UIPELauncher/gi, "uipe");
  92. }
  93. </script>
  94. <head>
  95. <body style="overflow:auto" onload="OnLoad()">
  96. <div style="margin-bottom:7px">
  97. <button onclick="OnCopyClick()" style="width:1.5in"><img src="../hal/images/btn_copy.gif" style="vertical-align:middle"/>&nbsp;Copy URL</button>
  98. <button onclick="OnLaunchClick()" style="margin-left:7px; width:1.5in"><img src="../pat/images/RunReportHTML.gif" style="vertical-align:middle"/>&nbsp;Launch</button>
  99. <label for="chkUseParameters">
  100. <input id="chkUseParameters" type="checkbox" checked="true"/>Use parameters
  101. </label>
  102. </div>
  103. <hr/>
  104. <table>
  105. <tr>
  106. <td style="padding-right: 40px; vertical-align:top">
  107. <div style="padding-top:2mm">UIPE URL:</div>
  108. <input id="txtUIPEPath" type="text" value="localhost" style="width:3in"/>
  109. <div style="padding-top:5mm">Gateway:</div>
  110. <div>
  111. <input id="txtGateway" type="text" value="" style="width:3in"/>
  112. </div>
  113. <div>
  114. <select id="selGateway" style="width:3in" size="2" onclick="document.getElementById( 'txtGateway' ).value=this.value">
  115. <option value="http://localhost/cognos/cgi-bin/cognos.cgi">http://localhost/cognos/cgi-bin/cognos.cgi</option>
  116. <option value="http://localhost/cognos/cgi-bin/cognosisapi.dll">http://localhost/cognos/cgi-bin/cognosisapi.dll</option>
  117. </select>
  118. </div>
  119. <div style="padding-top:5mm">Profile Store Id:</div>
  120. <div>
  121. <input id="txtUIProfileStoreId" type="text" value="" style="width:3in"/>
  122. </div>
  123. <div style="padding-top:5mm">UI Profile Name:</div>
  124. <div>
  125. <select id="selUIProfile" style="width:3in">
  126. <option value="Report Studio Professional">Report Studio Professional</option>
  127. <option value="Cognos Workspace Advanced">Cognos Workspace Advanced</option>
  128. <option value="Cognos Workspace Do More">Cognos Workspace Do More</option>
  129. </select>
  130. </div>
  131. <div>
  132. </td>
  133. <td style="vertical-align:top">
  134. <div style="padding-top:2mm">Skin:</div>
  135. <div>
  136. <select id="selSkin" style="width:2in">
  137. <option value=""></option>
  138. <option value="business">Business</option>
  139. <option value="classic">Classic</option>
  140. <option value="contemporary">Contemporary</option>
  141. <option value="corporate" selected>Corporate</option>
  142. <option value="modern">Modern</option>
  143. <option value="presentation">Presentation</option>
  144. </select>
  145. </div>
  146. <div style="padding-top:5mm">Product&nbsp;Locale:</div>
  147. <div>
  148. <select id="selProductLocale" style="width:1in">
  149. <option value=""></option>
  150. <option value="en" selected>en</option>
  151. <option value="fr">fr</option>
  152. <option value="de">de</option>
  153. <option value="ja">ja</option>
  154. <option value="ru">ru</option>
  155. </select>
  156. </div>
  157. </td>
  158. </tr>
  159. <tr>
  160. </tr>
  161. </table>
  162. </body>
  163. </html>