 <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/enrgise-html.tld" prefix="enrgise" %>


<html:html>
<html:base />
<head>
  <TITLE><bean:message  key="hrm.title" /></TITLE>
  <jsp:include page="GenIncludes.jsp" flush="true" />
</head>
<BODY  scroll=auto>

<html:form  action="HrmPrmKPARatingBaseAction" name="HrmPrmKPARatingForm" type="wenrgise.hrms.webtier.form.HrmPrmKPARatingForm">
<bean:define id="ParentForm" name="HrmPrmKPARatingForm" toScope="request" />
<jsp:include page="GenIconMenu.jsp" flush="true" />
<!--Top Most Blue Bar-->
<TABLE cellSpacing=0 bgColor=#bdd0ef>
    <tr>
        <TD  colSpan=12 class=mainHeader ><bean:message  key="hrm.HrmPrmKPARating.heading" /></TD>
    </TR>
</TABLE>
<!--//  Display Errors -->
<enrgise:errors/>
<logic:messagesPresent message="true">
<Table>
    <html:messages id="message" message="true">
    <TR><TD>
      <bean:write name="message"/>
    </TD></TR>
    </html:messages>      
</Table>
</logic:messagesPresent>
<!--//  Display Errors --> 
<TABLE cellSpacing=0 cellPadding=0 border=0 >
    <TR>
        <TD>
        
        <TABLE cellSpacing=0 cellPadding=0 >
        <!--Header Starts -->
            <TR>
                  <TD class=subHeader colspan=6><bean:message  key="hrm.HrmPrmKPARating.header" /></TD>
            </TR>
            <TR>
                  <TD colspan=6 bgColor=#4682b4><IMG height=1 src="../includes/images/pixel.gif" width=1 border=0></TD>
            </TR>
            
            
            <TR> 
                  <td class=labelText><bean:message key="hrm.HrmPrmKPARating.gradeCode" /></td>
                  <td colspan=2 ><html:text  property="gradeCode"  maxlength="15" size="23" styleClass="required" onchange="doChangeHeader();" readonly="true" /><enrgise:img src="../includes/images/lov.jpg" height="16" align="center" property="butGrade" name="HrmPrmKPARatingForm" onclick="ShowGrade();" /><html:text  property="gradeDesc" altKey="hrm.HrmPrmKPARating.gradeDesc" maxlength="255" size="40" styleClass="locked" onchange="doChangeHeader();" readonly="true" /></td> 
                  
                  
                  <td class="labelText"><bean:message key="hrm.HrmPrmKPARating.rating" /></td>
                  <td><html:text  property="ratingNo" altKey="hrm.HrmPrmKPARating.rating" maxlength="10"  readonly="true" size="23" styleClass="required" /><enrgise:img height="16" align="center" src="../includes/images/lov.jpg"   property="butRatingNo" name="HrmPrmKPARatingForm" onclick="ShowRatingNo()" /> </td>
            </TR>
            
            <TR> 
                  <td class=labelText><bean:message key="hrm.HrmPrmKPARating.desigCode" /></td>
                  <td colspan=2 ><html:text  property="desigCode"  maxlength="15" size="23" styleClass="optional" onchange="doChangeHeader();" readonly="true" /><enrgise:img src="../includes/images/lov.jpg" height="16" align="center" property="butDesig" name="HrmPrmKPARatingForm" onclick="ShowDesignation();" /><html:text  property="desigDesc" altKey="hrm.HrmPrmKPARating.desigDesc" maxlength="255" size="40" styleClass="locked" onchange="doChangeHeader();" readonly="true" /></td> 
            </TR>
            
            
             <TR>
                  <TD class=subHeader colspan=6><bean:message  key="hrm.HrmPrmKPARating.finalHeader" /></TD>
            </TR>
            <TR>
                  <TD colspan=6 bgColor=#4682b4><IMG height=1 src="../includes/images/pixel.gif" width=1 border=0></TD>
            </TR>
            
            
            <TR> 
                 <td class="labelText"><bean:message key="hrm.HrmPrmKPARating.maxRating" /></td>
                 <td><html:text  property="maxRating" altKey="hrm.HrmPrmKPARating.maxRating" maxlength="10" readonly="true" size="26" styleClass="optional"  /></td>
                  <td class="labelText"><bean:message key="hrm.HrmPrmKPARating.minRating" /></td>
                 <td><html:text  property="minRating" altKey="hrm.HrmPrmKPARating.minRating" maxlength="10" readonly="true" size="26" styleClass="optional"  /></td>
            </TR>
            
              
          
            <tr height=10>
                 <td colspan=6></td>
            </tr>
         </table>
        
                      
         <table cellspacing=0 cellpadding=0 border=0>
          <!-- Detail Information Row starts -->
          <TR>
            <TD colspan=6>
            <!-- Tab Table Starts -->
            <TABLE cellSpacing=0 cellPadding=0 >
            <tr>                                             
                          <td bgcolor="#76A2C7" width="10"><img src="../includes/images/pixel.gif" width="10" height="1" border="0"></td>
                          <td bgcolor="#76A2C7" nowrap class=disTabText onclick="doGetTab('HrmPrmKPARating','HrmPrmKPARatingFGetTabAction.do')"><bean:message key="hrm.HrmPrmKPARating.detail" /><img src="../includes/images/pixel.gif" width="10" height="1" border="0"></td>
                          <td><img src="../includes/images/formtab_lb.gif" width="10" height="21" border="0"></td>
                          <td bgcolor="#4682B4" width="10"><img src="../includes/images/pixel.gif" width="10" height="1" border="0"></td>
                          <td bgcolor="#4682B4" nowrap class=actTabText ><bean:message key="hrm.HrmPrmFinalRating.detail" /><img src="../includes/images/pixel.gif" width="10" height="1" border="0"></td>
                          <TD><IMG height=21 src="../includes/images/formtab_r.gif" width=10  border=0></TD>                              
                          <TD width="100%" background="../includes/images/line_t.gif">&nbsp;</TD>
                          <TD background="../includes/images/line_t.gif"><IMG height=1 src="../includes/images/pixel.gif" width=10 border=0></TD>
            </tr>
            <TR>
              
            <!-- Detail table Container starts -->
              <TD colSpan=8>
              <TABLE cellSpacing=0 cellPadding=0 border=0>
                <TBODY>
                 <TR>
                  <TD >
                  <DIV id=divDtlTable style="height:200px">
                    <TABLE  border="0" cellSpacing=0 cellPadding=0>
                     <TBODY>
                          <tr>
                              <TD class=tableHeader width="1%"><input type="checkbox" name="selectAll"  onclick="toggleCheckBox('checked')"  /></td>
                              <TD class=tableHeader width="5%"><bean:message key="hrm.HrmPrmKPARating.txtFromRating" /></td>   
                              <TD class=tableHeader width="5%"><bean:message key="hrm.HrmPrmKPARating.txtToRating" /></td>                                
                              <TD class=tableHeader width="5%"><bean:message key="hrm.HrmPrmKPARating.txtPoints" /></td>                                
                         
                          </tr>   
                          
                         <!--Insert Logic Iterate Here-->    
                          <logic:iterate id="HrmPrmKPARating" name="HrmPrmKPARatingForm" property="arylstFinalRate" type="wenrgise.hrms.bean.HrmPrmKPAFinalDtlBean" indexId="idx" >
                        
                         <logic:notEqual name="HrmPrmKPARating" property="status" value="D">
                         <tr>
                              <TD class=tableText width="1%"><html:checkbox property="checked"  name="HrmPrmKPARatingForm" alt="<%=idx.toString()%>" onclick="boxClicked(this.alt);" /></td>
                                <html:hidden property="status"  name="HrmPrmKPARating" />
                                <html:hidden property="itemChecked"  name="HrmPrmKPARating" />
                                <html:hidden property="detailId"  name="HrmPrmKPARating" />
                                <html:hidden property="txtPromKPARatingHdrFId" name="HrmPrmKPARating" />
                              </TD>
                              
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="startField"  styleClass="required"  maxlength="8" onkeydown="isFloat(event)" style="width:90%" size="14" alt="A" onchange='<%="doChangeDetail("+idx.toString()+")"%>' /> </td>
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="endField" styleClass="required"  maxlength="8" onkeydown="isFloat(event)" style="width:100%" size="14" alt="A" onchange='<%="doChangeDetail("+idx.toString()+")"%>' /> </td>
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="txtPoints" styleClass="required" maxlength="8"  onkeydown="isFloat(event)" style="width:100%" size="14" alt="A" onchange='<%="doChangeDetail("+idx.toString()+")"%>' /> </td>
                         
                          </tr>
                          </logic:notEqual>
                          
                          
                         <logic:equal name="HrmPrmKPARating" property="status" value="D">
                         <tr>
                              <TD class=tableText width="1%"><html:checkbox property="checked" value="check" disabled="true"   alt="<%=idx.toString()%>" onclick="boxClicked(this.alt);" /></td>
                                <html:hidden property="status"  name="HrmPrmKPARating" /><html:hidden property="itemChecked"  name="HrmPrmKPARating" /><html:hidden property="detailId"  name="HrmPrmKPARating" />                                <html:hidden property="txtPromKPARatingHdrFId" name="HrmPrmKPARating" />

                                
                              </TD>
                              
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="startField"  maxlength="8" onkeydown="isFloat(event)" style="width:90%" styleClass="deletedRow"  size="14" alt="A" readonly="true" onchange='<%="doChangeDetail("+idx.toString()+")"%>'  /> </td>
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="endField"  maxlength="8" onkeydown="isFloat(event)" style="width:100%" styleClass="deletedRow" size="14" alt="A" onchange='<%="doChangeDetail("+idx.toString()+")"%>' readonly="true" /> </td>
                              <TD class=tableText ><html:text name="HrmPrmKPARating" property="txtPoints"  maxlength="8" onkeydown="isFloat(event)" style="width:100%" styleClass="deletedRow" size="14" alt="A" onchange='<%="doChangeDetail("+idx.toString()+")"%>' readonly="true" /> </td>
                         
                          </tr>
                          </logic:equal>
                        </logic:iterate>
                                   
                          
                      
                      </TBODY>
                      </TABLE>
                      </DIV>
                      </TD>
                    </TR>
               <tr>
                <td>	
                <jsp:include page="GenDetailMenu.jsp" flush="true" />
		            </TD>
		            <td> </td>
               </tr>
        </TABLE>
      </td>
     </tr>
      <TR>
        <TD background="../includes/images/line_r.gif"><IMG src="../includes/images/pixel.gif" border=0></TD>
      </TR>
      
  </TABLE>
</td>
</tr>
              <!-- Tab Table Ends -->

      <!-- Bottom Blue Bar -->
       <TR>
            <td>
              <TABLE  cellspacing="0" cellpadding="0" border=0>
                    <tr>
                        <td width=40% align=center bgColor=#4682b4></td>
                        <td  bgColor=#4682b4></td>
                        <td  bgColor=#4682b4></td>                
                        <td bgColor=#4682b4></td>
                        <td align=right bgColor=#4682b4><img src="../includes/images/man.jpg"></td>
                   </TR>
                </table>
            </td>
          </tr>
	
<!-- Container Table Ending Columns Starts-->
    
</TBODY>
</TABLE>



<!-- Container Table Ends -->
<!-- These four hidden fields must be present in pages where there is a detail part -->
<html:hidden name="HrmPrmKPARatingForm" property="screenName" value="HrmPrmKPARatingF" />
<html:hidden name="HrmPrmKPARatingForm" property="forwardedPage" />
<html:hidden name="HrmPrmKPARatingForm" property="positionRequested"  />
<html:hidden name="HrmPrmKPARatingForm" property="screenMode"  />
<html:hidden name="HrmPrmKPARatingForm" property="firstLoad"  />
<html:hidden property="headerPrimaryKey" name="HrmPrmKPARatingForm"  />
<html:hidden property="txtSearchFields" name="HrmPrmKPARatingForm"  />
<html:hidden property="txtDisplayFields" name="HrmPrmKPARatingForm"  />
<html:hidden property="txtIndex" name="HrmPrmKPARatingForm"  />
<html:hidden property="userPageRequested" />
<html:hidden property="userPositionRequested"  />
<html:hidden property="pageRequested" />
<html:hidden property="lovKey" name="HrmPrmKPARatingForm"  />
<html:hidden property="detailDataChanged" name="HrmPrmKPARatingForm" />
<html:hidden property="headerDataChanged" name="HrmPrmKPARatingForm" />
<html:hidden property="addIncrValue" name="HrmPrmKPARatingForm" value="0.01" />
<!-- Hidden fields for Header LOV -->
<html:hidden property="gradeId" name="HrmPrmKPARatingForm" />
<html:hidden property="desigId" name="HrmPrmKPARatingForm" />
<html:hidden property="ratingId" name="HrmPrmKPARatingForm" />
<html:hidden property="firstLoad" name="HrmPrmKPARatingForm"  />
<!-- Hidden fields for Detail LOV -->

<input type=hidden name=scaleId >

<input type="hidden" name="queryParam" >
<input type="hidden" name="multipleFlag" >

<!-- Hidden fields end -->




</html:form>
</body>
</html:html>







<script>


function doQueryMode()
{

  return "HrmPrmKPARatingFQueryModeAction.do";
}


function doInsertMode()
{

  return "HrmPrmKPARatingFNewModeAction.do";
}


function doExecute()
{
  return "HrmPrmKPARatingFGetHeaderAction.do";
}

function doSave()
{

  return "HrmPrmKPARatingFSaveAction.do";
  
}

function doDelete()
{

  return "HrmPrmKPARatingFDeleteAction.do";
  
}

function doRefresh()
{

  return "HrmPrmKPARatingFRefreshAction.do";
  
}
function doExit()
{

  return "HrmPrmKPARatingFExitAction.do";
  
}

function doPrevHeader()
{
  return "HrmPrmKPARatingFGetNextHeaderAction.do"; 
}

function doNextHeader()
{
  return "HrmPrmKPARatingFGetNextHeaderAction.do"; 
}

function doJumpHeader()
{
  return "HrmPrmKPARatingFGetNextHeaderAction.do"; 
}

function doGetDetail()
{

  return "HrmPrmKPARatingFGetDetailAction.do";
}

function doAddRow()
{

  return "HrmPrmKPARatingFAddRowAction.do"; 
}

function doDelRow()
{
 return "HrmPrmKPARatingFDeleteRowAction.do";  
}

function doGetDetailTableName()
{
  return "tableName";
}

function doPrevDetail()
{

  return "HrmPrmKPARatingFGetDetailPageAction.do";  
}

function doNextDetail()
{

  return "HrmPrmKPARatingFGetDetailPageAction.do";
}

function doJumpDetail()
{
  return  "HrmPrmKPARatingFGetDetailPageAction.do"; 
}



function doOnLoad()
{
 
}



function ShowPosNo()
{
        document.forms[0].lovKey.value = "PrmKPAPosNo" + "HrmPrmKPARatingForm" + document.forms[0].screenMode.value;
        document.forms[0].txtSearchFields.value = "hrm.HrmPrmKPARating.positionCode";
        document.forms[0].txtDisplayFields.value = "headerPrimaryKey,positionCode,desc,hierarchy,designation,scaleId,scale";
        document.forms[0].multipleFlag.value = "false";
        showLov('<html:rewrite page="/hrms/jsp/CommonSearchScreen.jsp" />','HrmPrmKPARatingForm');
        return true;
}

function ShowRatingNo()
{
        document.forms[0].lovKey.value = "PrmKPARatNo" + "HrmPrmKPARatingForm" + document.forms[0].screenMode.value;
        document.forms[0].txtSearchFields.value = "hrm.HrmPrmKPARating.rating";
        document.forms[0].txtDisplayFields.value = "ratingId,ratingNo,maxRating,minRating";
        showLov('<html:rewrite page="/hrms/jsp/CommonSearchScreen.jsp" />','HrmPrmKPARatingForm');
        return true;
}

function ShowGrade()
{
        document.forms[0].lovKey.value = "PrmKPAGrade" + "HrmPrmKPARatingForm" + document.forms[0].screenMode.value;
        document.forms[0].txtSearchFields.value = "hrm.HrmPrmKPARating.gradeCode,hrm.HrmPrmKPARating.gradeDesc";
        document.forms[0].txtDisplayFields.value = "gradeId,gradeCode,gradeDesc";
        showLov('<html:rewrite page="/hrms/jsp/CommonSearchScreen.jsp" />','HrmPrmKPARatingForm');
        return true;
}

function ShowDesignation()
{
        document.forms[0].lovKey.value = "PrmKPADesig" + "HrmPrmKPARatingForm" + document.forms[0].screenMode.value;
        document.forms[0].txtSearchFields.value = "hrm.HrmPrmKPARating.desigCode,hrm.HrmPrmKPARating.desigDesc";
        document.forms[0].txtDisplayFields.value = "desigId,desigCode,desigDesc";
        showLov('<html:rewrite page="/hrms/jsp/CommonSearchScreen.jsp" />','HrmPrmKPARatingForm');
        return true;
}


function ShowKPAGrpNo(i)
{
        document.forms[0].lovKey.value = "PrmKPAGrpNo" + "HrmPrmKPARatingForm" + document.forms[0].screenMode.value;
        document.forms[0].txtSearchFields.value = "hrm.HrmPrmKPARating.txtKPAGroupCode";
        document.forms[0].txtIndex.value=i;
        document.forms[0].txtDisplayFields.value = "txtKPAGroupId,txtKPAGroupCode,txtKPAGroupDesc";
        showLov('<html:rewrite page="/hrms/jsp/CommonSearchScreen.jsp" />','HrmPrmKPARatingForm');
        return true;
}



function boxClicked(val)
{    
    if(document.getElementsByName("checked")[val].checked)
    {      
      document.getElementsByName("itemChecked")[val].value = "Y";      
    }
    else
    {     
      document.getElementsByName("itemChecked")[val].value = "N";     
    }      
}
</script>
