ADM2041.js 1.7 KB
//文字コードはEUCで保存すること

function data_chk(seq,mode){
	if(document.frm.gyoumu_name.value == ""){
		alert("業務名称を入力してください");
		return false;
	}

	if (document.frm.gyoumu_money.value != ""){
			if (suchi_chk("受注額",document.frm.gyoumu_money.value)==false) {
					return false;
			}
	}
	if (document.frm.gyoumu_st_term.value != ""){
			if (date_chk("工期(開始日)",document.frm.gyoumu_st_term.value)==false) {
					return false;
			}
	}
	if (document.frm.gyoumu_ed_term.value != ""){
			if (date_chk("工期(終了日)",document.frm.gyoumu_ed_term.value)==false) {
					return false;
			}
	}

//	var chkflg = "";
//	if(document.getElementsByName("gyousya[]")){
//		for(i=0; i<document.getElementsByName("gyousya[]").length; i++ ){
//			if (document.getElementsByName("gyousya[]")[i].checked == true){
//				var chkflg = "1";
//			}	
//		}
//	}

//	if (hissu_chk("取引先業者",chkflg)==false) {
//		return false;
//	}

	document.frm.action = "ADM2042.php?mode="+mode+"&seq="+seq;
	document.frm.method="POST";
	document.frm.submit();
}

//カレンダー表示
function cal_get(strDate, divid){
		if(divid == "calid2"){
				document.frm.gyoumu_st_term.value = strDate;
		}
		if(divid == "calid3"){
				document.frm.gyoumu_ed_term.value = strDate;
		}

		cal2 = new JKL.Calendar("calid2","frm","colname2");
		cal3 = new JKL.Calendar("calid3","frm","colname3");
}


document.onclick=function(){
		if(document.getElementById("calid2") != null){
				//document.getElementById("calid2").style.display="none";
				//document.getElementById("calid2").innerHTML="";
		}
		if(document.getElementById("calid3") != null){
				//document.getElementById("calid3").style.display="none";
				//document.getElementById("calid3").innerHTML="";
		}
}