<%@ page import="com.csc.library.entry.*,com.csc.library.utilities.*,com.csc.library.session.*,com.csc.library.database.*,java.util.*"  contentType="text/html;charset=UTF-8"%>
<jsp:useBean id="APS200_1" scope="page" class="com.csc.library.system.Task"/>
<%
	APS200_1.setChannel(request ,response);
	UIManager screen=(UIManager)APS200_1.process("ChildEntry","MGRADEHISTORY");
	
%>
<html ng-app="myHR">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" >
<link href="../CSS/TISCO.css" rel="stylesheet" type="text/css">
<link href="../CSS/bootstrap.css" rel="stylesheet"  type="text/css">
<link href="../CSS/bootstrap_csc_backend.css" rel="stylesheet"  type="text/css">
<script type="text/javascript" src="../JS/jquery-2.1.3.min.js"></script>
<script type='text/javascript' src="../JS/bootstrap.js"></script>
<script type='text/javascript' src='../JS/SCREEN.js'></script>
<script src="../JS/angular-1.3.15/angular.js" type="text/javascript"></script>
<script src="../JS/ANGULAR/SCREEN_ANGULAR.js" type="text/javascript"></script>
<script language='javascript'>setLang('<%=screen.getUProfile().get("lang")%>');</script>
<script language="JavaScript" src="../JS/VIEWCALENDAR.js"></script>
<script language="JavaScript" src="../JS/HOTKEY.js"></script>
<script  language="JavaScript" src="../JS/DATEINPUT.js"></script>
<script language="javascript">getTitleName();</script>
<script language="JavaScript" type="text/JavaScript">

function linkHelp_Return(help,input){
	with(document.cscform){
		if (__fixCon.value!="")
			__fixCon.value=__fixCon.value 
		var param="PRU084.jsp?__helpName="+help+"&__helpReturn="+input+"&__pageCall="+__screen.value+"&__fixCon="+__fixCon.value+"&__checkVerify=off&__langOn=false";
		window.open(param,"Help","left=150,top=150,width=600,height=400,toolbar=no,status=yes,scrollbars=yes,resizable=yes");
	}
}

  /* function  saveChild(){
		with(document.cscform){
       		bCon=confirm(MyCode[1]);
	      	if (bCon==true)	{
					__cmdchild.value="save";
      	 	}
			submit();
		}
	} */

	function  saveChild(){
		with(document.cscform){
			__cmdchild.value="save";
			submit();
		}
	}

function back(){
		with(window.opener.document.cscform){
			__cmd.value = 'ack';
	    	submit();	    
		}
	}
</script>
</head>
<body leftmargin="0" topmargin="0"  onLoad="MM_preloadImages('../IMAGES/BUTTON/SWAP/SEARCH_SWAP24.gif','../IMAGES/BUTTON/SWAP/EXIT_SWAP24.gif','../IMAGES/BUTTON/SWAP/HELP_SWAP24.gif','../IMAGES/BUTTON/SWAP/NEW_SWAP24.gif','../IMAGES/BUTTON/SWAP/EDIT_SWAP24.gif','../IMAGES/BUTTON/SWAP/DEL_SWAP24.gif','../IMAGES/BUTTON/SWAP/PROCESS_SWAP24.gif','../IMAGES/BUTTON/SWAP/SEARCH_SWAP20.gif');">
<div id="toolTipLayer" style="position:absolute; visibility: hidden"></div>
<script language="javascript">initToolTips();</script>
<form name="cscform" method="post" action="APS200_1.jsp">


<!----------BEGIN CSC INITIAL ZONE ------------------------>

<%=screen.InitialVariable()%>

<!----------END CSC INITIAL ZONE -------------------------->

<input type="hidden" name="__cmd" value="">
<input type="hidden" name="__sysisedit" value="">
	<input type="hidden" name="__cmdchild">
	<input type="hidden" name="__ack" value="<%=request.getParameter("__ack")%>">
	<input type="hidden" name="__referPage" value="">
	<input type="hidden" name="__fixCon" value="">
	<input type="hidden" name="__help" value="">
	<input type="hidden" name="__notNull" value="<%=screen.getRequire()%>">	
	<input type="hidden" name="__screen" value="MGRADEHISTORY">
	<input type="hidden" name="__companyid"  value='<%=screen.getUProfile().get("companyid")%>'>
	<input type="hidden" name="__employeeid" value="<%=request.getParameter("__employeeid")%>">
	<input type="hidden" name="__language" value='<%=screen.getUProfile().get("lang")%>'>
	<input type="hidden" name="__lastrec" value="<%=request.getParameter("__lastrec")%>">
	<input type="hidden" name="__maxrec" value="<%=screen.getTable("MGRADEHISTORY").recCount()%>">
	<input type="hidden" name="__gorec" value="<%=request.getParameter("__gorec")%>">  
	<input type="hidden" name="__headMulti" value="<%=request.getParameter("__headMulti")%>">
	<script language="javascript">getInputFormatDate();</script>
    <input type="hidden" name="__calendar">
	<input type="hidden" name="__headMulti" value="<%=request.getParameter("__headMulti")%>">
	<input type="hidden" name="__Rec_No" value="<%=request.getParameter("__Rec_No")%>">

	<!-- fix ค่า weight ประการณ์ทำงาน เป็น 100 percent -->
	<input type="hidden" name="__exp_weight" value="100">
	<input type="hidden" name="__form" value="">

	<%
   int lineno=1;
   
 if((request.getParameter("__gorec")!=null)&&(!request.getParameter("__gorec").equals(""))){
     lineno= Integer.parseInt(request.getParameter("__gorec").toString());
  %>
  <% }else{
   if(screen.getTable("MGRADEHISTORY").recCount()==0){
     lineno=1;
  }else{
         screen.getTable("MGRADEHISTORY").last();
          String lastrec=screen.getTable("MGRADEHISTORY").getString("LINE_NO");
          lineno=Integer.parseInt(lastrec)+1;
     }
    }  
 %>
	<input type="hidden" name="__line_no" value="<%=lineno%>">
<br>
  <div align="center">     
    <table cellpadding="0" cellspacing="0">
      <tr > 
        <td class="header">APS200_1,<span swlang code="SW012687">Grade History Table</span>&nbsp; </td>
      </tr>
      <tr > 
        <td height="222" colspan="2"> 
          <div align="center"> 
            <center>
              <table  border="0" cellpadding="0" cellspacing="0">
                <tr> 
                  <td class="blankspace" colspan="2"></td>
                </tr>
                <tr> 
                  <td class="columnlabel"><%=screen.getLabel("year")%>&nbsp;</td>
                  <td ><%=screen.getInput("year")%></td>
                </tr>
                <tr> 
                  <td class="columnlabel"><%=screen.getLabel("grade")%>&nbsp;</td>
                  <td  ><%=screen.getInput("grade")%></td>
                </tr>
				<tr> 
                  <td  class="columnlabel"><%=screen.getLabel("score")%>&nbsp; 
                  </td>
                  <td > <%=screen.getInput("score")%></td>
                </tr>
                <tr> 
                  <td  class="columnlabel"><%=screen.getLabel("type")%>&nbsp; 
                  </td>
                  <td > <%=screen.getInput("type")%></td>
                </tr>
                  <td colspan="4" class="blankspace"></td>
                </tr>

                <tr>
                  <td  class="buttonline" colspan="7"><div align="center">
                    <button type="button" class="btn btn-primary width100" swlang code="SW013169" onClick="saveChild();">OK</button>&nbsp;
                    <button type="button" class="btn btn-primary width100" swlang code="SW013174" onClick="backhead();">BACK</button>
                  </div>
                  </td>
                </tr>
                <tr> 
                  <td colspan="4" class="blankspace"></td>
                </tr>
              </table>
            </center>
          </div></td>
      </tr>
      <tr bordercolor="0069B3"> 
        <td height="20" class="bottom"></td>
      </tr>
    </table>
    </center>
</div>
<% 
if((request.getParameter("__cmdchild")!=null)&&(!request.getParameter("__cmdchild").equals(""))){%>
<script language="javascript">back();</script>
<%}%>
</form>
<!--Start ERROR AND WARNING -->

  <!--END ERROR AND WARNING -->

</body>
</html>
