<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@page contentType="text/html; charset=UTF-8"%>
<%@page import="com.csc.library.entry.*,com.csc.library.system.*,com.csc.library.session.*"%>
<jsp:useBean id="APS_CONFIG" class="com.csc.library.system.Task" scope="page" />
<%APS_CONFIG.setChannel(request, response);
//APS_CONFIG.setKeepCache(false);
UIManager screen = (UIManager) APS_CONFIG.process("SingleEntry", "APS_CONFIG");
%>

<html>
<head>
<title>Tax Deductable&Exemptible Allowances</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="../CSS/MENU.css" rel="stylesheet" type="text/css">
<link href="../CSS/TISCO.css" rel="stylesheet" type="text/css">
<script  language="JavaScript" src="../JS/SCREEN.js"></script>
<script language="JavaScript" src="../JS/VIEWCALENDAR.js"></script>
<script type='text/javascript' src='../JS/ICONSMENU.js'></script>
<script language='javascript' src='../JS/HOTKEY.js'></script>
<script language='javascript'>setLang('<%=screen.getUProfile().get("lang")%>');</script>
<script language="JavaScript" type="text/JavaScript">
<!--
function checkCF() {checkConfirm();}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

//-----------> start copy to screen ----------------->

function Trim(szStr) {
	return TrimLeft(TrimRight(szStr));
}

function TrimLeft(szStr) {
	for(var i=0; i<szStr.length; i++) {
		if(szStr.charAt(i) == ' ')
			szStr = szStr.substring(i-- + 1, szStr.length);
		else
			break;
	}
	return szStr;
}

function TrimRight(szStr) {
	for(var i=szStr.length-1; i>=0; i--) {
		if(szStr.charAt(i) == ' ')
			szStr = szStr.substring(0, i);
		else
			break;
	}
	return szStr;
}

function  nullField(idx){
 with(document.cscform){
		var fieldName = new Array();
		var returnV=false;
		if(__notNull.value != ""){fieldName= __notNull.value.split(",");}
	  }
	    for(i=0;i<fieldName.length;i++){
			    tempValue="__mconfig$"+fieldName[i];
			    //alert(tempValue);
				if(tempValue ==document.cscform.elements[idx].name){
					     returnV=true;					
		   	        }
		}
    return returnV;
}
function nullCheck(){
	for (var i=0;i<document.cscform.length;i++){
			if(nullField(i)){
				if((document.cscform.elements[i].value==null)||(document.cscform.elements[i].value=="")){
		             alert(MyCode[0]);  
					 document.cscform.elements[i].focus();
					 return false;
 	                }
		//	}
		}//else{
			
  //}
  }
  return true;
}
//------------------------------ cscform NULL check ----------------------------------------------->

function saveData(){
	if(nullCheck()){
		with(document.cscform){		
			var oldValue = Trim(__effectiveid.value);
			var newValue = __mconfig$effectiveid.value;		
			//newValue= Trim(newValue.substring(0,newValue.indexOf(" ")));		
			//alert("OLD= "+oldValue);
			//alert("NEW="+newValue);
	
			if (oldValue!=newValue){
				aCon=confirm(MyCode[1]);
				if (aCon==true)	{
					save();
				}			
			}
			else{
				alert(MyCode[2]);
			}	
		}//End with
	}
}

function updateData(){
	if(nullCheck()){
		with(document.cscform){
		
			var oldValue = Trim(__effectiveid.value);
			var newValue = __mconfig$effectiveid.value;				
			//newValue= Trim(newValue.substring(0,newValue.indexOf(" ")));	
			//alert("OLD="+oldValue);
			//alert("NEW="+newValue);

			if (oldValue!=newValue){
				alert(MyCode[9]);			
			}
			else{
				aCon=confirm(MyCode[1]);
				if (aCon==true)	{
					__cmd.value="save";
					submit();
				}		
			}	
		}//End with
	}	
	
}

function GoSave(){ confirmSave(); }
function GoDelete(){ edelete(); }
function GoSearch(){ search(); }
function GoUpdate(){
  update();
 }

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>

</head>
<body leftmargin="0" topmargin="0" onLoad="MM_preloadImages('../IMAGES/BUTTON/SWAP/CALENDAR_SWAP20.gif')">

<div id="toolTipLayer" style="position:absolute; visibility: hidden"></div>
<script language="javascript">initToolTips();</script>
<div class="centered">
<form name="cscform" method="post" >


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

<%=screen.InitialVariable()%>

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

<input name="__cmd" type="hidden" value=""> 
	<input name="__screen" type="hidden" value="APS_CONFIG"> 
	<input name="__help" type="hidden" value=""> 
	<input type="hidden" name="__calendar">
	<input type="hidden" name="__notNull" value="<%=screen.getRequire()%>">
  <script language="javascript">getInputFormatDate();</script>
  <input type="hidden" name="__language" value ="<%=screen.getUProfile().get("lang")%>"> 
	<input type="hidden" name="__companyid" value='<%=screen.getUProfile().get("companyid")%>'> 
	<input name="__effectiveid" type="hidden" value="<%=screen.getDataLabel("mconfig$effectiveid")%>">	
	<input type="hidden" name="__user" value="<%=screen.getUProfile().getUserId()%>">
  <script language="javascript">
		 var titlename=swap2String('System config');
		 document.write(Icons("APS_CONFIG,"+titlename));
	 </script>
	<br>
	<br>
	<br>
  <div align="center">
    <table>
<tr > 
        <td class="header">APS_CONFIG, <script language='javascript'>swapLang('System config');</script>&nbsp; </td>
      </tr>
      <tr > 
        <td > 
            <table cellpadding="0" cellspacing="0" class="inner">
            <tr> 
              <td class="blankspace" colspan="3"></td>
            </tr>
			<tr> 
              <td nowrap BGCOLOR="#EFEFEF" CLASS="columnlabelwidth"><%=screen.getLabel("mconfig$YEAR_360")%></td>
              <td  colspan="2"><%=screen.getInput("mconfig$YEAR_360")%></td>
           </tr>
		   <tr> 
              <td nowrap BGCOLOR="#EFEFEF" CLASS="columnlabelwidth"><%=screen.getLabel("mconfig$SEQUENCE_360")%></td>
              <td  colspan="2"><%=screen.getInput("mconfig$SEQUENCE_360")%></td>
           </tr> 
            <tr> 
              <td colspan="3" class="blankspace">&nbsp;</td>
            </tr>
			<tr> 
              <td colspan="3">
			  <table cellpadding="0" cellspacing="0">
                  <tr > 
                    <td  class="columnlabel">&nbsp;</td>
                    <td >
					 <script language="javascript">printEditCheck('<%=screen.getDataLabel("mconfig$edit_by")%>','<%=screen.getDataLabel("mconfig$edit_date")%>','<%=screen.getDataLabel("mconfig$edit_time")%>','<%=screen.getDataLabel("mconfig$approve")%>');
						</script>&nbsp;
					</td>
                  </tr>
                </table>
			  </td>
            </tr>
            <tr> 
              <td class="blankspace" colspan="3"></td>
            </tr>
        </table>	    </td>
      </tr>
      <tr> 
        <td class="bottom" >
        </td>
      </tr>
    </table>
  </div>


<!----------BEGIN CSC ENDING ZONE ------------------------>

<%=screen.endJSP()%>

<!----------END CSC ENDING ZONE -------------------------->

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

