1
0

parser_create.jsp 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194
  1. <%@ include file="../common/header.jsp" %>
  2. <script type="text/javascript" language="javascript">
  3. <!--
  4. function doCreateParser(){
  5. var x = window.confirm("<bean:message key="confirm.create"/>")
  6. if (x) {
  7. document.forms.parser.action.value="create_ok";
  8. document.forms.parser.post.value = "true";
  9. document.forms.parser.submit();
  10. }
  11. }
  12. function doBack(){
  13. document.forms.parser.action.value="list";
  14. document.forms.parser.clear.value="true";
  15. document.forms.parser.submit();
  16. }
  17. function doAddParserCodex(){
  18. document.forms.parser.addParserCodexBtn.disabled=true;
  19. document.forms.parser.action.value="add_parserCodex";
  20. document.forms.parser.submit();
  21. }
  22. function doEditParserCodex(sequence){
  23. document.forms.parser.action.value="edit_parserCodex";
  24. document.forms.parser.sequence.value=sequence;
  25. document.forms.parser.submit();
  26. }
  27. function doDeleteParserCodex(sequence){
  28. var x = window.confirm("<bean:message key="confirm.delete"/>");
  29. if(x){
  30. document.forms.parser.action.value="delete_parserCodex";
  31. document.forms.parser.sequence.value=sequence;
  32. document.forms.parser.submit();
  33. }
  34. }
  35. -->
  36. </script>
  37. <!-- CONTENT -->
  38. <form name="parser" method="post" action="parser.do">
  39. <input type="hidden" name="action">
  40. <input type="hidden" name="clear">
  41. <input type="hidden" name="sequence">
  42. <input type="hidden" name="post">
  43. <logic:notEmpty name="idx"><input type="hidden" name="idx" value="<bean:write name="idx"/>"></logic:notEmpty>
  44. <input type="hidden" name="ts" value="<logic:notEmpty name="ts"><bean:write name="ts" /></logic:notEmpty>">
  45. <input type="hidden" name="redirect" value="create">
  46. <!--td width="80%" valign="top"-->
  47. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  48. <tr>
  49. <td class="titleHeader" align="left"><bean:message key="project.parser.key"/> CREATE</td>
  50. </tr>
  51. </table>
  52. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  53. <tr><td colspan="7"><html:errors/></td></tr>
  54. <tr>
  55. <td align="center">
  56. <table width="100%" border="0" cellspacing="1" cellpadding="2">
  57. <tr>
  58. <td width="15%"><b><bean:message key="parser.id.key"/> <font color="#FF0000">*</font></b></td>
  59. <td width="1%">:</td>
  60. <td width="84%" colspan="5" align="left">
  61. <html:text name="parser_${ts}" property="id"/>
  62. </td>
  63. </tr>
  64. <%/*<tr>
  65. <td width="15%"><b><bean:message key="parser.type.key"/> <font color="#FF0000">*</font></b></td>
  66. <td width="1%">:</td>
  67. <td width="84%" colspan="5" align="left">
  68. <html:text name="parser_${ts}" property="type"/>
  69. </td>
  70. </tr>*/%>
  71. <tr>
  72. <td width="15%"></td>
  73. <td width="10"></td>
  74. <td width="30%">
  75. <input type="button" value="<bean:message key="button.back"/>" onclick="javascript:doBack();">
  76. &nbsp;
  77. <input type="button" value="<bean:message key="button.submit"/>" onclick="javascript:doCreateParser();"></td>
  78. <td colspan="4">&nbsp;</td>
  79. </tr>
  80. <tr>
  81. <td width="15%"></td>
  82. <td width="10"></td>
  83. <td width="30%"></td>
  84. <td width="45%" colspan="4"></td>
  85. </tr>
  86. </table>
  87. </td>
  88. </tr>
  89. <tr>
  90. <td>&nbsp;</td>
  91. </tr>
  92. <tr>
  93. <td>&nbsp;</td>
  94. </tr>
  95. <tr>
  96. <td class="titleHeader" align="left"><b><bean:message key="project.parserCodex.key"/></b></td>
  97. </tr>
  98. <!-- LIST ADD ADAPTOR CODEX -->
  99. <tr>
  100. <td>
  101. <table width="100%" border="0" cellspacing="1" cellpadding="1">
  102. <tr>
  103. <td class="titleField" height="22" width="5%" align="center"><bean:message key="parserCodex.no.key"/></td>
  104. <td nowrap="nowrap" class="titleField" width="30%"><bean:message key="parserCodex.id.key"/></td>
  105. <td class="titleField" width="55%"><bean:message key="parserCodex.codex.key"/></td>
  106. <td class="titleField" width="10%">&nbsp;</td>
  107. </tr>
  108. <!-- START ADAPTOR CODEX -->
  109. <logic:notEmpty name="parser_${ts}" property="parserCodexes">
  110. <% int index = 0; %>
  111. <logic:iterate id="element_parserCodexes" name="parser_${ts}" property="parserCodexes">
  112. <tr bgcolor="<%= index%2 == 0 ? "FFFFFF" : "EDEDE8" %>" >
  113. <td align="center"><%=++seq2%>&nbsp;</td>
  114. <td align="left">&nbsp;<bean:write name="element_parserCodexes" property="id.id"/></td>
  115. <td align="left">&nbsp;<bean:write name="element_parserCodexes" property="codexId.id"/></td>
  116. <td align="center">
  117. <a href="#" ><img src="./images/edit.gif" border="0" onclick="javascript:doEditParserCodex(<%=index%>);" alt="edit"></a>
  118. <a href="#" ><img src="./images/trash.gif" border="0" onclick="javascript:doDeleteParserCodex(<%=index%>);" alt="remove"></a>
  119. </td>
  120. </tr>
  121. <% index++; %>
  122. </logic:iterate>
  123. </logic:notEmpty>
  124. </table>
  125. </td>
  126. </tr>
  127. <!-- END LIST ADD ADAPTOR CODEX -->
  128. <!-- ADD ANAK ADAPTOR CODEX-->
  129. <tr>
  130. <td><table width="100%" border="0" cellspacing="1" cellpadding="2">
  131. <tr>
  132. <td width="20%" align="left" valign="top"><b><bean:message key="parserCodex.id.key"/></b> <font color="#FF0000">*</font></td>
  133. <td width="1%" align="left" valign="top">:</td>
  134. <td width="29%" align="left" valign="top">
  135. <input type="text" name="idParserCodexes" value="<logic:notEmpty name="parserCodexes_${ts}" property="id"><bean:write name="parserCodexes_${ts}" property="id.id"/></logic:notEmpty>">
  136. </td>
  137. </tr>
  138. <tr>
  139. <td width="20%" align="left" valign="top"><b><bean:message key="parserCodex.codex.key"/></b> <font color="#FF0000">*</font></td>
  140. <td width="1%" align="left" valign="top">:</td>
  141. <td width="29%" align="left" valign="top">
  142. <select name="codex">
  143. <option value="">-- Pilih Salah Satu --</option>
  144. <logic:notEmpty name="codexList">
  145. <logic:iterate id="codexElement" name="codexList">
  146. <option value="<bean:write name="codexElement" property="id"/>"
  147. <logic:notEmpty name="parserCodexes_${ts}" property="codexId">
  148. <logic:equal name="parserCodexes_${ts}" property="codexId.id" value="${codexElement.id}">
  149. SELECTED
  150. </logic:equal>
  151. </logic:notEmpty>
  152. >
  153. <bean:write name="codexElement" property="id"/></option>
  154. </logic:iterate>
  155. </logic:notEmpty>
  156. </select>
  157. </td>
  158. </tr>
  159. <tr>
  160. <td align="left" valign="top">&nbsp;</td>
  161. <td align="left" valign="top">&nbsp;</td>
  162. <td align="left" valign="top">
  163. <br><input type="button" name="addParserCodexBtn" value="<bean:message key="button.add"/>" onclick="javascript:doAddParserCodex();">
  164. </td>
  165. </tr>
  166. <tr>
  167. <td>&nbsp;</td>
  168. <td>&nbsp;</td>
  169. <td>&nbsp;</td>
  170. <td>&nbsp;</td>
  171. <td>&nbsp;</td>
  172. <td>&nbsp;</td>
  173. </tr>
  174. </table></td>
  175. </tr>
  176. <!-- END ANAK ADAPTOR CODEX-->
  177. </table>
  178. </form>
  179. <!-- END CONTENT -->
  180. <%@ include file="../common/footer.jsp"%>