routingTable_editList.jsp 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174
  1. <%@ include file="../common/header.jsp"%>
  2. <script type="text/javascript" language="javascript">
  3. <!--
  4. function doUpdateRoutingTable(){
  5. var x = window.confirm("<bean:message key="confirm.edit"/>");
  6. if(x){
  7. document.forms.routingTable.action.value = "edit_ok";
  8. document.forms.routingTable.post.value = "true";
  9. document.forms.routingTable.submit();
  10. }
  11. }
  12. function doInactive(id,status){
  13. var x = window.confirm(" Are you sure inactivate this record?")
  14. if (x) {
  15. document.forms.routingTable.id.value=id;
  16. document.forms.routingTable.status.value=status;
  17. document.forms.routingTable.action.value="update_status";
  18. document.forms.routingTable.submit();
  19. }
  20. }
  21. function doActive(id,status){
  22. var x = window.confirm(" Are you sure activate this record?")
  23. if (x) {
  24. document.forms.routingTable.id.value=id;
  25. document.forms.routingTable.status.value=status;
  26. document.forms.routingTable.action.value="update_status";
  27. document.forms.routingTable.submit();
  28. }
  29. }
  30. function doBack(){
  31. document.forms.routingTable.action.value="edit";
  32. document.forms.routingTable.submit();
  33. doDisable(document.forms.routingTable, "button");
  34. }
  35. -->
  36. </script>
  37. <!-- CONTENT -->
  38. <form name="routingTable" method="post" action="routingTable.do">
  39. <input type="hidden" name="action" value ="">
  40. <html:hidden name="routingTable" property="id"/>
  41. <input type="hidden" name="post">
  42. <input type="hidden" name="status" value ="">
  43. <!--td width="80%" valign="top"-->
  44. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  45. <tr>
  46. <td class="titleHeader"><bean:message key="project.routingTable.key"/> - EDIT</td>
  47. </tr>
  48. </table>
  49. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  50. <tr><td colspan="7"><html:errors/></td></tr>
  51. <tr>
  52. <td align="center">
  53. <table width="100%" border="0" cellspacing="1" cellpadding="2">
  54. <tr>
  55. <td width="15%"><b><bean:message key="routingTable.codeStart.key"/> <font color="#FF0000">*</font></b></td>
  56. <td width="1%">:</td>
  57. <td width="84%" colspan="4" align="left">
  58. <html:text name="routingTable" property="codeStart"/>
  59. </td>
  60. </tr>
  61. <tr>
  62. <td width="15%"><b><bean:message key="routingTable.codeEnd.key"/><font color="#FF0000">*</font></b></td>
  63. <td width="1%">:</td>
  64. <td width="84%" colspan="4" align="left">
  65. <html:text name="routingTable" property="codeEnd"/>
  66. </td>
  67. </tr>
  68. <tr>
  69. <td width="15%"><b><bean:message key="routingTable.channel.key"/><font color="#FF0000">*</font></b></td>
  70. <td width="1%">:</td>
  71. <td width="84%" colspan="4" align="left">
  72. <html:text name="routingTable" property="channel"/>
  73. </td>
  74. </tr>
  75. <tr>
  76. <td width="15%"><b><bean:message key="routingTable.subcodex.key"/></b></td>
  77. <td width="1%">:</td>
  78. <td width="84%" colspan="4" align="left">
  79. <%/*<select name="subcodex">
  80. <option value="">-- Pilih Salah Satu --</option>
  81. <logic:notEmpty name="codexList">
  82. <logic:iterate id="codexElement" name="codexList">
  83. <option value="<bean:write name="codexElement" property="id"/>"
  84. <logic:notEmpty name="routingTable" property="subcodex">
  85. <logic:equal name="routingTable" property="subcodex.id" value="${codexElement.id}">
  86. SELECTED
  87. </logic:equal>
  88. </logic:notEmpty>
  89. >
  90. <bean:write name="codexElement" property="id"/></option>
  91. </logic:iterate>
  92. </logic:notEmpty>
  93. </select>*/%>
  94. <html:text name="routingTable" property="subcodex" size="30"/>
  95. </td>
  96. </tr>
  97. <tr>
  98. <td width="15%" align="left" valign="top"><b><bean:message key="routingTable.startDate.key"/><font color="#FF0000">*</font></b></td>
  99. <td width="1%" align="left" valign="top">:</td>
  100. <td width="84%" colspan="4" align="left" valign="top">
  101. <input type="text" name="startDate" value="<logic:notEmpty name="routingTable" property="startDate"><bean:write name="routingTable" property="startDate.time" format="dd/MM/yyyy" /></logic:notEmpty>" size="15" maxlength="10" >
  102. <a href="javascript:cal_startDate.popup();"><img src="./images/cal.gif" width="16" height="16" border="0" alt=""></a>
  103. <script type="text/javascript" language="javascript">
  104. var cal_startDate = new calendar1(document.forms['routingTable'].elements['startDate']);
  105. </script>
  106. </td>
  107. </tr>
  108. <tr>
  109. <td width="15%" align="left" valign="top"><b><bean:message key="routingTable.endDate.key"/></b></td>
  110. <td width="1%" align="left" valign="top">:</td>
  111. <td width="84%" colspan="4" align="left" valign="top">
  112. <input type="text" name="endDate" value="<logic:notEmpty name="routingTable" property="endDate"><bean:write name="routingTable" property="endDate.time" format="dd/MM/yyyy" /></logic:notEmpty>" size="15" maxlength="10" >
  113. <a href="javascript:cal_endDate.popup();"><img src="./images/cal.gif" width="16" height="16" border="0" alt=""></a>
  114. <script type="text/javascript" language="javascript">
  115. var cal_endDate = new calendar1(document.forms['routingTable'].elements['endDate']);
  116. </script>
  117. </td>
  118. </tr>
  119. <tr>
  120. <td width="15%"><b><bean:message key="routingTable.queue.key"/><font color="#FF0000">*</font></b></td>
  121. <td width="1%">:</td>
  122. <td width="84%" colspan="4" align="left">
  123. <html:text name="routingTable" property="queue"/>
  124. </td>
  125. </tr>
  126. <tr>
  127. <td width="15%"><b><bean:message key="routingTable.status.key"/><font color="#FF0000">*</font></b></td>
  128. <td width="1%">:</td>
  129. <td width="84%" colspan="4" align="left">
  130. <bean:write name="routingTable" property="status"/>
  131. </td>
  132. </tr>
  133. <tr>
  134. <td width="15%"></td>
  135. <td width="1%"></td>
  136. <td width="84%" colspan="4" align="left">
  137. <logic:notEmpty name="routingTable" property="codeStart">
  138. <input type="button" value="<bean:message key="button.back"/>" onclick="javascript:doBack();">
  139. &nbsp;
  140. <logic:equal name="routingTable" property="status" value="ACTIVE">
  141. <input type="button" value="<bean:message key="button.inactive"/>" onclick="doInactive('<bean:write name="routingTable" property="id"/>','INACTIVE');">
  142. </logic:equal>
  143. <logic:equal name="routingTable" property="status" value="INACTIVE">
  144. <input type="button" value="<bean:message key="button.active"/>" onclick="doActive('<bean:write name="routingTable" property="id"/>','ACTIVE');">
  145. </logic:equal>
  146. &nbsp;
  147. <input type="button" value="<bean:message key="button.submit"/>" onclick="doUpdateRoutingTable();">
  148. </logic:notEmpty>
  149. </td>
  150. </tr>
  151. </table>
  152. </td>
  153. </tr>
  154. <tr>
  155. <td>&nbsp;</td>
  156. </tr>
  157. </table>
  158. </form>
  159. <!-- END CONTENT -->
  160. <%@ include file="../common/footer.jsp"%>