rem: if(end_hy1!="/"||end_hy2!="/"){ alert(pbc0409); form.END.focus(); return false; } if(smon>12||sdy>31||smon<=0||sdy<=0||(isNaN(smon)==true)||(isNaN(sdy)==true)||(isNaN(syr)==true)){ alert(pbc0409); form.STD.focus(); return false; } if(emon>12||edy>31||emon<=0||edy<=0||(isNaN(emon)==true)||(isNaN(edy)==true)||(isNaN(eyr)==true)){ alert(pbc0409); form.END.focus(); return false; } if(((smon==1||smon==3||smon==5||smon==7||smon==8||smon==10||smon==12)&&sdy>31)||(syr%4==0&&smon==2&&sdy>29)||(syr%4!=0&&smon==2&&sdy>28)||((smon==4||smon==6||smon==9||smon==11)&&sdy>30)){ alert(pbc0409); form.STD.focus(); return false; } if(((emon==1||emon==3||emon==5||emon==7||emon==8||emon==10||emon==12)&&edy>31)||(eyr%4==0&&emon==2&&edy>29)||(eyr%4!=0&&emon==2&&edy>28)||((emon==4||emon==6||emon==9||emon==11)&&edy>30)){ alert(pbc0409); form.END.focus(); return false; } if ((eyr==nextYear)&&(syr==year)) { if ((emon>1)||(edy >31)) { alert(pbc0401); form.END.focus(); return false; } } else { if ((syr<year-1) || (syr>year)) { alert(pbc0407); form.STD.focus(); return false; } if((eyr!=year)&&(eyr!=year-1)){ alert(pbc0405); form.END.focus(); return false; } if(smon>emon||(smon==emon&&sdy>=edy)){ alert(pbc0403); form.STD.focus(); return false; } } if((status>2&&status<5)||(status>=5&&status<9&&ism=="YES")||(status==12&&ism=="YES")){ if(!vdt(form.IRD1)){return false;} if(!vdt(form.IRD2)){return false;} if(!vdt(form.IRD3)){	return false;	} ird1=form.IRD1.value; ird2=form.IRD2.value; ird3=form.IRD3.value; if(((ird1==ird2)&&(!ird1.match(/^\s*$/)))||((ird1==ird3)&&(!ird1.match(/^\s*$/)))){ alert(pbc0417); form.IRD1.focus(); return false; } else if((ird2==ird3)&&(!ird2.match(/^\s*$/))){ alert(pbc0417); form.IRD2.focus(); return false; } if(!vdt(form.FRD1)){return false;} if(ism=="YES"){ if(!vdt(form.FRD1)){return false;} } } if((status==5||status==6)&&ism=="YES"){ rating=""; for(i=0;i<form.RCD.length;i++){ if(form.RCD[i].checked==true)rating=form.RCD[i].value; } isnh=""; for(i=0; i<form.INH.length; i++){ if(form.INH[i].checked==true){ isnh=form.INH[i].value; } } if(isnh=="Y"){ beh=""; for(i=0; i<form.NHB.length;i++){ if(form.NHB[i].checked==true){ beh=form.NHB[i].value; } } skl=""; for(i=0; i<form.NHS.length;i++){ if(form.NHS[i].checked==true){ skl=form.NHS[i].value; } } if((beh=="N"||skl=="N")&&rating!=""){ if(form.RCD[3].checked==false){ if(confirm(pbc0455))srdb(form.RCD,"4"); else { form.NHB[0].focus(); return false; } } } if(!vdt(form.SID)){	return false;} } } if((status==2||status==4 || status==8 || status==5 || status==6 || status==10)&&ism=='YES') { if(!confirm(pbc0436)){	return false;} if(form.OBJECTIVE_CHANGED.value=='Y') { if(confirm(pbc0452+" "+pbc0453+" "+pbc0454)){form.MRQ.value=4; } else { form.MRQ.value=0; } }else if (( status==5 || status==6 || status==10) && (form.RESULTS_CHANGED.value=='Y')) { if(confirm(pbc0470+" "+pbc0453+" "+pbc0454)){form.MRQ.value=8; } else { form.MRQ.value=0; } } } sact(action); if(status>=9&&status<=11){ snul(); } form.submit(); return true; } 
context: function vsav(form,status,ism,action) {if(!vol()){ return false; }adt1=form.STD;adt2=form.END;stdt=adt1.value;etdt=adt2.value;syr=stdt.substring(0,4);start_hy1=stdt.charAt(4);smon=stdt.substring(5,7);start_hy2=stdt.charAt(7);sdy=stdt.substring(8,10);eyr=etdt.substring(0,4);end_hy1=etdt.charAt(4);emon=etdt.substring(5,7);end_hy2=etdt.charAt(7);edy=etdt.substring(8,10);today=new Date();date=today.getDate();month=today.getMonth()+1;if(today.getYear()<2000) year=today.getYear()+1900; else year=today.getYear();nextYear=year+1;if(!vnull(form.STD)) return false;if(!vnull(form.END)) return false;if(start_hy1!="/"||start_hy2!="/"){alert(pbc0409);form.STD.focus();return false;}if(end_hy1!="/"||end_hy2!="/"){alert(pbc0409);form.END.focus();return false;}if(smon>12||sdy>31||smon<=0||sdy<=0||(isNaN(smon)==true)||(isNaN(sdy)==true)||(isNaN(syr)==true)){alert(pbc0409);form.STD.focus();return false;}if(emon>12||edy>31||emon<=0||edy<=0||(isNaN(emon)==true)||(isNaN(edy)==true)||(isNaN(eyr)==true)){alert(pbc0409);form.END.focus();return false;}if(((smon==1||smon==3||smon==5||smon==7||smon==8||smon==10||smon==12)&&sdy>31)||(syr%4==0&&smon==2&&sdy>29)||(syr%4!=0&&smon==2&&sdy>28)||((smon==4||smon==6||smon==9||smon==11)&&sdy>30)){alert(pbc0409);form.STD.focus();return false;}if(((emon==1||emon==3||emon==5||emon==7||emon==8||emon==10||emon==12)&&edy>31)||(eyr%4==0&&emon==2&&edy>29)||(eyr%4!=0&&emon==2&&edy>28)||((emon==4||emon==6||emon==9||emon==11)&&edy>30)){alert(pbc0409);form.END.focus();return false;}if ((eyr==nextYear)&&(syr==year)) {if ((emon>1)||(edy >31)) {alert(pbc0401);form.END.focus();return false;}} else {if ((syr<year-1) || (syr>year)) {alert(pbc0407);form.STD.focus();return false;}if((eyr!=year)&&(eyr!=year-1)){alert(pbc0405);form.END.focus();return false;}if(smon>emon||(smon==emon&&sdy>=edy)){alert(pbc0403);form.STD.focus();return false;}}if((status>2&&status<5)||(status>=5&&status<9&&ism=="YES")||(status==12&&ism=="YES")){if(!vdt(form.IRD1)){return false;}if(!vdt(form.IRD2)){return false;}if(!vdt(form.IRD3)){	return false;	}ird1=form.IRD1.value;ird2=form.IRD2.value;ird3=form.IRD3.value;if(((ird1==ird2)&&(!ird1.match(/^\s*$/)))||((ird1==ird3)&&(!ird1.match(/^\s*$/)))){alert(pbc0417);form.IRD1.focus();return false;}else if((ird2==ird3)&&(!ird2.match(/^\s*$/))){alert(pbc0417);form.IRD2.focus();return false;}if(!vdt(form.FRD1)){return false;}if(ism=="YES"){if(!vdt(form.FRD1)){return false;}}}if((status==5||status==6)&&ism=="YES"){rating="";for(i=0;i<form.RCD.length;i++){if(form.RCD[i].checked==true)rating=form.RCD[i].value;}isnh="";for(i=0; i<form.INH.length; i++){if(form.INH[i].checked==true){isnh=form.INH[i].value;}}if(isnh=="Y"){beh="";for(i=0; i<form.NHB.length;i++){if(form.NHB[i].checked==true){beh=form.NHB[i].value;}}skl="";for(i=0; i<form.NHS.length;i++){if(form.NHS[i].checked==true){skl=form.NHS[i].value;}}if((beh=="N"||skl=="N")&&rating!=""){if(form.RCD[3].checked==false){if(confirm(pbc0455))srdb(form.RCD,"4");else {form.NHB[0].focus();return false;}}}if(!vdt(form.SID)){	return false;}}}if((status==2||status==4 || status==8 || status==5 || status==6 || status==10)&&ism=='YES'){if(!confirm(pbc0436)){	return false;}if(form.OBJECTIVE_CHANGED.value=='Y') {    if(confirm(pbc0452+" "+pbc0453+" "+pbc0454)){form.MRQ.value=4; } else { form.MRQ.value=0; }}else if (( status==5 || status==6 || status==10) && (form.RESULTS_CHANGED.value=='Y')) {   if(confirm(pbc0470+" "+pbc0453+" "+pbc0454)){form.MRQ.value=8; } else { form.MRQ.value=0; }}}sact(action);if(status>=9&&status<=11){snul();}form.submit();return true;}
meta: 8395	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/8395/3703c3c05f398a63e55992f7687ef65273b26d6a/regress-216320.js/clean/js/tests/js1_5/Regress/regress-216320.js