dbConnection_list.jsp 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231
  1. <%@ include file="../common/header.jsp"%>
  2. <%
  3. if (seq==0){
  4. seq = (Integer) request.getAttribute("databaseConnection_start");
  5. }
  6. %>
  7. <script type="text/javascript" language="javascript">
  8. <!--
  9. function page(start, count){
  10. document.forms.databaseConnection.start.value=start;
  11. document.forms.databaseConnection.count.value=count;
  12. document.forms.databaseConnection.action.value="list";
  13. document.forms.databaseConnection.submit();
  14. doDisable(document.forms.databaseConnection, "button");
  15. }
  16. function doChangePage(count){
  17. document.forms.databaseConnection.start.value= (document.forms.databaseConnection.startx.value-1)*20;
  18. if(document.forms.databaseConnection.start.value=="NaN") document.forms.databaseConnection.start.value = 0;
  19. document.forms.databaseConnection.count.value=count;
  20. document.forms.databaseConnection.action.value="list";
  21. document.forms.databaseConnection.submit();
  22. doDisable(document.forms.databaseConnection, "button");
  23. }
  24. function doCreate(){
  25. document.forms.databaseConnection.action.value="create";
  26. document.forms.databaseConnection.submit();
  27. doDisable(document.forms.databaseConnection, "button");
  28. }
  29. function fillIndex(val){
  30. document.forms.databaseConnection.startx.value = val.value;
  31. }
  32. function doDetail(dbconnectionPk){
  33. document.forms.databaseConnection.dbconnectionPk.value=dbconnectionPk;
  34. document.forms.databaseConnection.action.value="detail";
  35. document.forms.databaseConnection.submit();
  36. }
  37. function doFilter(){
  38. document.forms.databaseConnection.action.value="list";
  39. document.forms.databaseConnection.submit();
  40. doDisable(document.forms.databaseConnection, "button");
  41. }
  42. function doReset(){
  43. document.forms.databaseConnection.databaseConnection_dsn_filter.value="";
  44. document.forms.databaseConnection.databaseConnection_jdbcDriver_filter.value="";
  45. document.forms.databaseConnection.databaseConnection_jdbcUrl_filter.value="";
  46. document.forms.databaseConnection.clear.value="true";
  47. document.forms.databaseConnection.action.value="list";
  48. document.forms.databaseConnection.submit();
  49. doDisable(document.forms.databaseConnection, "button");
  50. }
  51. function doOrder(field, type){
  52. document.forms.databaseConnection.databaseConnection_fieldOrder.value=field;
  53. document.forms.databaseConnection.databaseConnection_orderType.value=type;
  54. document.forms.databaseConnection.action.value="list";
  55. document.forms.databaseConnection.submit();
  56. doDisable(document.forms.status, "button");
  57. }
  58. -->
  59. </script>
  60. <!-- CONTENT -->
  61. <form name="databaseConnection" method="post" action="databaseConnection.do">
  62. <input type="hidden" name="start" value="">
  63. <input type="hidden" name="startx" value="">
  64. <input type="hidden" name="action" value="">
  65. <input type="hidden" name="count" value="">
  66. <input type="hidden" name="clear" value="">
  67. <input type="hidden" name="dbconnectionPk" value="">
  68. <input type="hidden" name="databaseConnection_fieldOrder" value="<bean:write name="databaseConnection_fieldOrder"/>">
  69. <input type="hidden" name="databaseConnection_orderType" value="<bean:write name="databaseConnection_orderType"/>">
  70. <input type="hidden" name="focus_field" value=""/>
  71. <!--td width="80%" valign="top"-->
  72. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  73. <tr>
  74. <td class="titleHeader"><bean:message key="project.databaseConnection.key"/> - LIST</td>
  75. </tr>
  76. <tr>
  77. <td><%@ include file="../common/paging.jsp"%>
  78. </td>
  79. </tr>
  80. </table>
  81. <table width="100%" border="0" cellspacing="1" cellpadding="1">
  82. <tr>
  83. <td width="5%" class="titleField"><div align="center">#</div></td>
  84. <td align="left" height="10" valign="top" class="titleField"><bean:message key="databaseConnection.dsn.key" />
  85. <logic:equal name="databaseConnection_fieldOrder" value="dsn">
  86. <logic:equal name="databaseConnection_orderType" value="ASC">
  87. <a href="#" onclick="doOrder('dsn', 'DESC');"><img src="./images/arrow_down.gif" border="0"></a>
  88. </logic:equal>
  89. <logic:equal name="databaseConnection_orderType" value="DESC">
  90. <a href="#" onclick="doOrder('dsn', 'ASC');"><img src="./images/arrow_up.gif" border="0"></a>
  91. </logic:equal>
  92. </logic:equal>
  93. <logic:notEqual name="databaseConnection_fieldOrder" value="dsn">
  94. <a href="#" onclick="doOrder('dsn', 'ASC');"><img src="./images/arrow.gif" border="0"></a>
  95. </logic:notEqual>
  96. </td>
  97. <td align="left" height="10" valign="top" class="titleField"><bean:message key="databaseConnection.jdbcdriver.key" />
  98. <logic:equal name="databaseConnection_fieldOrder" value="jdbcDriver">
  99. <logic:equal name="databaseConnection_orderType" value="ASC">
  100. <a href="#" onclick="doOrder('jdbcDriver', 'DESC');"><img src="./images/arrow_down.gif" border="0"></a>
  101. </logic:equal>
  102. <logic:equal name="databaseConnection_orderType" value="DESC">
  103. <a href="#" onclick="doOrder('jdbcDriver', 'ASC');"><img src="./images/arrow_up.gif" border="0"></a>
  104. </logic:equal>
  105. </logic:equal>
  106. <logic:notEqual name="databaseConnection_fieldOrder" value="jdbcDriver">
  107. <a href="#" onclick="doOrder('jdbcDriver', 'ASC');"><img src="./images/arrow.gif" border="0"></a>
  108. </logic:notEqual>
  109. </td>
  110. <td align="left" height="10" valign="top" class="titleField"><bean:message key="databaseConnection.jdbcurl.key" />
  111. <logic:equal name="databaseConnection_fieldOrder" value="jdbcUrl">
  112. <logic:equal name="databaseConnection_orderType" value="ASC">
  113. <a href="#" onclick="doOrder('jdbcUrl', 'DESC');"><img src="./images/arrow_down.gif" border="0"></a>
  114. </logic:equal>
  115. <logic:equal name="databaseConnection_orderType" value="DESC">
  116. <a href="#" onclick="doOrder('jdbcUrl', 'ASC');"><img src="./images/arrow_up.gif" border="0"></a>
  117. </logic:equal>
  118. </logic:equal>
  119. <logic:notEqual name="databaseConnection_fieldOrder" value="jdbcUrl">
  120. <a href="#" onclick="doOrder('jdbcUrl', 'ASC');"><img src="./images/arrow.gif" border="0"></a>
  121. </logic:notEqual>
  122. </td>
  123. <td width="5%" class="titleField">&nbsp;</td>
  124. </tr>
  125. <logic:notEmpty name="databaseConnectionList">
  126. <logic:iterate id="element" name="databaseConnectionList" scope="request" indexId="index">
  127. <%
  128. sequence++;
  129. String bgcolor = "FFFFFF";
  130. if(sequence%2 == 0){
  131. bgcolor = "EDEDE8";
  132. }
  133. %>
  134. <tr bgcolor="<% out.print(bgcolor); %>" onmouseover="mOvr(this);" onmouseout="mOut(this, '<% out.print(bgcolor); %>');">
  135. <td align="center" class="celBorder"><%=++seq%>&nbsp;</td>
  136. <td align="left" class="celBorder">
  137. &nbsp;<bean:write name="element" property="dsn"/>
  138. </td>
  139. <td align="left" class="celBorder">
  140. &nbsp;<bean:write name="element" property="jdbcDriver"/>
  141. </td>
  142. <td align="left" class="celBorder">
  143. &nbsp;<bean:write name="element" property="jdbcUrl"/>
  144. </td>
  145. <td align="center" class="celBorder" ><a href="#" ><img src="./images/detail.gif" border="0" onclick="doDetail('<bean:write name="element" property="dbconnectionPk"/>');" alt="see detail"/></a>
  146. </td>
  147. </tr>
  148. </logic:iterate>
  149. </logic:notEmpty>
  150. </TABLE>
  151. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  152. <tr>
  153. <td class="search"><bean:message key="project.search.key" /></td>
  154. </tr>
  155. </table>
  156. <table width="100%" border="0" cellspacing="1" cellpadding="2">
  157. <tr>
  158. <td width="20%"><b><bean:message key="databaseConnection.dsn.key"/></b></td>
  159. <td width="1%">:</td>
  160. <td width="29%">
  161. <label>
  162. <input type="text" name="databaseConnection_dsn_filter" value="<logic:notEmpty name="databaseConnection_dsn_filter"><bean:write name="databaseConnection_dsn_filter"/></logic:notEmpty>">
  163. </label>
  164. </td>
  165. </tr>
  166. <tr>
  167. <td width="20%"><b><bean:message key="databaseConnection.jdbcdriver.key"/></b></td>
  168. <td width="1%">:</td>
  169. <td width="29%">
  170. <label>
  171. <input type="text" name="databaseConnection_jdbcDriver_filter" value="<logic:notEmpty name="databaseConnection_jdbcDriver_filter"><bean:write name="databaseConnection_jdbcDriver_filter"/></logic:notEmpty>">
  172. </label>
  173. </td>
  174. </tr>
  175. <tr>
  176. <td width="20%"><b><bean:message key="databaseConnection.jdbcurl.key"/></b></td>
  177. <td width="1%">:</td>
  178. <td width="29%">
  179. <label>
  180. <input type="text" name="databaseConnection_jdbcUrl_filter" value="<logic:notEmpty name="databaseConnection_jdbcUrl_filter"><bean:write name="databaseConnection_jdbcUrl_filter"/></logic:notEmpty>">
  181. </label>
  182. </td>
  183. </tr>
  184. <tr>
  185. <tr>
  186. <td>&nbsp;</td>
  187. <td>&nbsp;</td>
  188. <td>&nbsp;</td>
  189. <td>&nbsp;</td>
  190. <td>&nbsp;</td>
  191. <td>&nbsp;</td>
  192. </tr>
  193. <tr>
  194. <td>&nbsp;</td>
  195. <td>&nbsp;</td>
  196. <td colspan="3" align="left">
  197. <input type="button" size="50" maxlength="25" value="<bean:message key="button.reset"/>" onclick="doReset();"/>
  198. &nbsp;&nbsp;
  199. <input type="button" value="<bean:message key="button.search"/>" onclick="doFilter();"/>
  200. </td>
  201. <td>&nbsp;</td>
  202. <td>&nbsp;</td>
  203. <td>&nbsp;</td>
  204. </tr>
  205. </table>
  206. </td>
  207. </form>
  208. <!-- END CONTENT -->
  209. <logic:notEmpty name="focus"><bean:write name="focus" filter="false"/></logic:notEmpty>
  210. <%@ include file="../common/footer.jsp"%>