728x90
반응형
function do_submit(cmd) {
var found = false;
var theform = document.signin2;
var error = ['데이타를 한개 이상 선택해 주십시오.',
' 잘못된 명령입니다.\n명령을 실행할 수 없습니다.'
];
var cmdtxt = ['', '처리할', '처리할', '처리할'];
//var action = ['delete', 'setflag', 'move', 'move'];
for (var i = 0; i < theform.elements.length; i++) {
if (theform.elements[i].name != 'staffId') continue;
if (theform.elements[i].checked == true) {
found = true;
break;
}
}
if (!found) {
switch (cmd) {
default:
break;
}
alert(cmdtxt[cmd] + error[0]);
//return false;
return;
}
if (cmd == '0') { //
var idStr = "";
var nmStr = "";
for (var i = 0; i < document.signin2.staffId.length; i++) {
if (document.signin2.staffId[i].checked == true) {
idStr += document.signin2.staffId[i].value + ",";
nmStr += document.signin2.name[i].value + ",";
}
}
//alert(idStr);
opener.document.signin.teachers.value = idStr.substring(0, idStr.length - 1);
opener.document.signin.teachersName.value = nmStr.substring(0, nmStr.length - 1);
//window.close();
self.close();
}
}
728x90
반응형