| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194 |
- <%@ include file="../common/header.jsp"%>
-
- <script type="text/javascript" language="javascript">
- <!--
- function doUpdatePrivilege(){
- var x = window.confirm("<bean:message key="confirm.edit"/>");
- if(x){
- document.forms.privilege.action.value = "edit_ok";
- document.forms.privilege.post.value = "true";
- document.forms.privilege.submit();
- }
- }
- function doBack(){
- document.forms.privilege.action.value="detail";
- document.forms.privilege.submit();
- doDisable(document.forms.privilege, "button");
- }
-
- function doEditSearch(){
- document.forms.privilege.action.value="edit_search";
- document.forms.privilege.submit();
- doDisable(document.forms.privilege, "button");
- }
-
- function doInactive(id,status){
- var x = window.confirm(" Are you sure inactivate this record?")
- if (x) {
- document.forms.privilege.id.value=id;
- document.forms.privilege.status.value=status;
- document.forms.privilege.action.value="update_status";
- document.forms.privilege.submit();
- }
- }
-
- function doActive(id,status){
- var x = window.confirm(" Are you sure activate this record?")
- if (x) {
- document.forms.privilege.id.value=id;
- document.forms.privilege.status.value=status;
- document.forms.privilege.action.value="update_status";
- document.forms.privilege.submit();
- }
- }
- -->
- </script>
- <!-- CONTENT -->
- <form name="privilege" method="post" action="privilege.do">
- <input type="hidden" name="action" value ="">
- <input type="hidden" name="clear" value ="">
- <html:hidden name="privilege" property="id"/>
- <input type="hidden" name="post">
- <input type="hidden" name="status" value ="">
- <!--td width="80%" valign="top"-->
- <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
- <tr>
- <td class="titleHeader"><bean:message key="project.privilege.key"/> - EDIT</td>
- </tr>
- </table>
- <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
- <tr><td colspan="7"><html:errors/></td></tr>
- <tr>
- <td align="center">
- <table width="100%" border="0" cellspacing="1" cellpadding="2">
- <logic:empty name="privilege" property="id">
- <tr align = "left">
- <td width="15%"><b><bean:message key="privilege.id.key" /></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <input type="text" name="idSearch" value="">
- </td>
- </tr>
- <tr align = "left">
- <td width="15%"></td>
- <td width="1%"></td>
- <td width="84%" colspan="5">
- <input type="button" value="<bean:message key="button.edit" />" onclick="doEditSearch();">
- </td>
- </tr>
- </logic:empty>
- <logic:notEmpty name="privilege" property="id">
- <tr>
- <td width="15%"><b><bean:message key="privilege.id.key"/> <font color="#FF0000">*</font></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <bean:write name="privilege" property="id"/>
- </td>
- </tr>
- <tr>
- <td width="15%"><b><bean:message key="privilege.name.key"/><font color="#FF0000">*</font></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <html:text name="privilege" property="name"/>
- </td>
- </tr>
- <tr>
- <td width="15%"><b><bean:message key="privilege.type.key"/><font color="#FF0000">*</font></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <SELECT NAME="type">
- <option value="">Pilih Salah Satu</option>
- <option value="PRIV_TYPE_MENU"
- <logic:equal name="privilege" property="type" value="PRIV_TYPE_MENU">
- SELECTED
- </logic:equal>
- >PRIV_TYPE_MENU</option>
- <option value="PRIV_TYPE_ACTION"
- <logic:equal name="privilege" property="type" value="PRIV_TYPE_ACTION">
- SELECTED
- </logic:equal>
- >PRIV_TYPE_ACTION</option>
- </SELECT>
- </td>
- </tr>
- <tr>
- <td width="15%"><b><bean:message key="privilege.path.key"/><font color="#FF0000">*</font></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <html:text name="privilege" property="path"/>
- </td>
- </tr>
- <tr>
- <td width="15%"><b><bean:message key="privilege.parent.key"/></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <select name="parent">
- <option value="">-- Pilih Salah Satu --</option>
- <logic:notEmpty name="privilegeList">
- <logic:iterate id="privilegeElement" name="privilegeList">
- <option value="<bean:write name="privilegeElement" property="id"/>"
- <logic:equal name="privilegeElement" property="id" value="${privilege.parent.id}">
- SELECTED
- </logic:equal>>
- <bean:write name="privilegeElement" property="name"/></option>
- </logic:iterate>
- </logic:notEmpty>
- </select>
- </td>
- </tr>
- <tr>
- <td width="15%"><b><bean:message key="privilege.priority.key"/></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5">
- <html:text name="privilege" property="priority"/>
- </td>
- </tr>
- <tr align = "left">
- <td width="15%"><b><bean:message key="privilege.status.key"/></b></td>
- <td width="1%">:</td>
- <td width="84%" colspan="5"><bean:write name="privilege" property="status"/></td>
- </tr>
- <tr>
- <td width="15%"></td>
- <td width="1%"></td>
- <td width="84%" colspan="5">
- <input type="button" value="<bean:message key="button.back"/>" onclick="javascript:doBack();"/>
- <input type="button" value="<bean:message key="button.submit"/>" onclick="doUpdatePrivilege();"/>
- <logic:equal name="privilege" property="status" value="ACTIVE">
- <input type="button" value="<bean:message key="button.inactive"/>" onclick="doInactive('<bean:write name="privilege" property="id"/>','INACTIVE');">
- </logic:equal>
- <logic:equal name="privilege" property="status" value="INACTIVE">
- <input type="button" value="<bean:message key="button.active"/>" onclick="doActive('<bean:write name="privilege" property="id"/>','ACTIVE');">
- </logic:equal>
- </td>
- <td colspan="4"> </td>
- </tr>
- <tr>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- <td> </td>
- </tr>
- </logic:notEmpty>
- </table>
- </td>
- </tr>
- <tr>
- <td> </td>
- </tr>
- </table>
- </FORM>
- <!-- END CONTENT -->
- <%@ include file="../common/footer.jsp"%>
-
|