employee_salary_manage.jsp
上传用户:guhaomin
上传日期:2007-06-10
资源大小:23203k
文件大小:7k
源码类别:

电子政务应用

开发平台:

Java

  1. <%
  2. /**
  3.  * $RCSfile: employee_salary_manage.jsp,v $
  4.  * $Revision: 1.0 $
  5.  * $Date: 2001/05/17 20:57:46 $
  6.  * /mainctrl/intranet/hr/employee_salary_manage
  7.  */
  8. %>
  9. <%@ page errorPage="/vnex/ErrorPage.jsp" %>
  10. <%@ page import="com.vnex.intranet.hr.employer_info.value.*"%>
  11. <%@ page import="com.vnex.intranet.hr.employer_info.process.*"%>
  12. <%@ page import="com.vnex.intranet.hr.util.*"%>
  13. <%@ page import="java.util.*" %>
  14. <jsp:useBean id="salaryProxyBean" class="com.vnex.intranet.hr.employer_info.proxy.SalaryProxyBean" scope="application" />
  15. <%
  16.     int emp_id = Integer.parseInt( request.getParameter("emp_id") );
  17.     String emp_name = request.getParameter("emp_name");
  18.     Collection pageColl = new ArrayList();
  19.     Collection pageSetColl = new ArrayList();
  20.     if ( request.getParameter("doSave") != null && request.getParameterValues("emp_id") != null && request.getParameterValues("component_id") != null )
  21.     {
  22.         String[] comId = request.getParameterValues("component_id");
  23.         hrProxyBean.salaryRemove( emp_id, MemberDbTable.SALARY_TYPE );
  24.         for ( int i=0; i<comId.length; i++ )
  25.         {
  26.             SalaryCountBean ms = new SalaryCountBean();
  27.             ms.setComId( Integer.parseInt( comId[i] ) );
  28.             ms.setEmpId( emp_id );
  29.             ms.setComType( MemberDbTable.SALARY_TYPE );
  30.             salaryProxyBean.salaryCreate( ms );
  31.         }
  32.         response.sendRedirect("/mainctrl/intranet/hr/salary_set?emp_id="+emp_id+"&emp_name="+emp_name);
  33.     }
  34.     if ( emp_id >0 )
  35.     {
  36.         pageSetColl = salaryProxyBean.salaryFindAll( emp_id, MemberDbTable.SALARY_TYPE );
  37.         pageColl = salaryProxyBean.comFindAll( MemberDbTable.SALARY_TYPE );
  38.     }
  39. %>
  40. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
  41. <HTML>
  42. <jsp:include page="/vnex/page/FORM_HEAD.jsp" />
  43. <BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff 
  44. topMargin=0 leftmargin="0" marginwidth="0" marginheight="0">
  45. <script language="JavaScript" src="/vnex/validate.js"></script>
  46. <script language="JavaScript" src="/vnex/menu/menu.js">
  47. /*
  48. Static Top Menu Script
  49. By ChunyiYang
  50. */
  51. </script>
  52. <script language="JavaScript" src="/vnex/menu/menucontext.js"></script>
  53. <script language="JavaScript">
  54. showToolbar();
  55. </script>
  56. <script language="JavaScript">
  57. function UpdateIt(){
  58. if (document.all){
  59. document.all["MainTable"].style.top = document.body.scrollTop;
  60. setTimeout("UpdateIt()", 200);
  61. }
  62. }
  63. UpdateIt();
  64. </script>
  65. <DIV align=center>
  66. <form name="form1" method="post" action="/mainctrl/intranet/hr/employee_salary_manage?emp_id=<%= emp_id %>&emp_name=<%= emp_name %>">
  67.   <TABLE class=outter cellSpacing=0 cellPadding=0 width=600 border=0>
  68.     <TBODY>
  69.     <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
  70.     <TR> 
  71.         <TD colSpan=3 align="center"> 
  72.           <br>
  73.           <table width="400" border="0">
  74.             <tr> 
  75.               <td align="center"><font class=strong>工资管理</font></td>
  76.             </tr>
  77.           </table>
  78.           <table width="350" border="0">
  79.             <tr> 
  80.               <td align="right"> 
  81.                 <input type="button" value="工资管理" name="B32" onClick="location='/mainctrl/intranet/hr/employee_salary_manage?emp_id=<%= emp_id %>&emp_name=<%= emp_name %>'" class=text>
  82.                   
  83.                 <input type="button" value="福利管理" name="B4" onClick="location='/mainctrl/intranet/hr/employee_welfare_manage?emp_id=<%= emp_id %>&emp_name=<%= emp_name %>'" class=text>
  84.                   
  85.                 <input type="button" value="保险管理" name="B5" onClick="location='/mainctrl/intranet/hr/employee_insurance_manage?emp_id=<%= emp_id %>&emp_name=<%= emp_name %>'" class=text>
  86.               </td>
  87.             </tr>
  88.           </table>
  89.           <span class=iframestyle 
  90.             style="OVERFLOW: visible; HEIGHT: 100%"> 
  91.           <table class=title cellspacing=1 cellpadding=2 width="350" border=0>
  92.             <tr> 
  93.               <td bgcolor="#e0e0e0" width="34%" align="center"><font class=strong>姓名:</font></td>
  94.               <td bgcolor="#e0e0e0" colspan="2"><%= emp_name %></td>
  95.             </tr>
  96.             <tr>
  97.             </tr>
  98.             <tr> 
  99.               <td bgcolor="#e0e0e0" width="32%" align="center"><font class=strong>工资组成</font></td>
  100.               <td bgcolor="#e0e0e0" width="48%">状态</td>
  101.               <td bgcolor="#e0e0e0" width="20%">选择</td>
  102.             </tr>
  103.     <%
  104.         Iterator iter = pageColl.iterator();
  105.         while ( iter.hasNext() )
  106.         {
  107.             SalaryComponent sc = (SalaryComponent)iter.next();
  108.     %>
  109.             <tr> 
  110.               <td bgcolor="#fafafa" width="32%" align="center"><font class=strong><%= sc.getName() %>:</font></td>
  111.               <td bgcolor="#fafafa" width="48%"><% if ( sc.getState() == MemberDbTable.COMPONENT_USE ) out.print("正在使用"); else out.print("暂停使用"); %>
  112.                 </td>
  113.               <td bgcolor="#fafafa" width="20%"> 
  114.                 <input type="checkbox" name="component_id" value="<%= sc.getId() %>" checked <% if (sc.getState()==MemberDbTable.COMPONENT_UNUSE ) out.print("disabled"); %> >
  115.               </td>
  116.             </tr>
  117.     <%
  118.         }
  119.     %>
  120.           </table>
  121.           </span> 
  122.           <br><br>
  123.             <input type="submit" value="提交" name="B3" class=button>
  124.           <input type="hidden" value="1" name="doSave" class=button>
  125.             <input type="button" value="取消" name="B2" class=button onclick="location='/mainctrl/intranet/hr/salary_set?emp_id=<%= emp_id %>&emp_name=<%= emp_name %>'">
  126.           <br><br>
  127.           <table class=title cellspacing=1 cellpadding=2 width="350" border=0>
  128.             <tr> 
  129.               <td bgcolor="#e0e0e0" width="50%" align="center"><font class=strong>职员当前设置</font></td>
  130.               <td bgcolor="#e0e0e0" width="50%">金额</td>
  131.             </tr>
  132.     <%
  133.         Iterator iter1 = pageSetColl.iterator();
  134.         while ( iter1.hasNext() )
  135.         {
  136.             MemberSalary ms = (MemberSalary)iter1.next();
  137.     %>
  138.             <tr> 
  139.               <td bgcolor="#fafafa" width="50%" align="left"><font class=strong><%= ms.getComponent().getName() %></font></td>
  140.               <td bgcolor="#fafafa" width="50%"><%= ms.getCount() %></td>
  141.             </tr>
  142.     <%
  143.         }
  144.     %>
  145.           </table>
  146.           <jsp:include page="/vnex/page/TTOA_HELP.jsp" />
  147.         </TD>
  148.     </TR>
  149.      <jsp:include page="/vnex/page/TTOA_TABLE_BOTTOM.jsp" />
  150.     </TBODY> 
  151.     </TABLE>
  152.   <BR>
  153.   <jsp:include page="/vnex/page/TTOA_PRODUCER_LOGO.jsp" />
  154.   </form></DIV>
  155. </BODY></HTML>