⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 lessonadd.jsp

📁 培训考试系统代码
💻 JSP
📖 第 1 页 / 共 2 页
字号:

        <input name ="endhm" type="text" class="input1-1"  maxlength="5">(HH:mm)
        </td>
         </tr>
      </table>
      </td>
    </tr>


    <tr>

      <td width="16%" align="center" class="td-cs1"><div id="md3">开始日期</div></td>
      <td width="38%" class="td-cs2">
      <div id="md1">
        <input name ="startymd" type="text" class="input1" onClick="javascript:calDate(this);" onKeyPress="javascript:calDate(this);">
      </div>
        </td>
      <td width="15%" align="center" class="td-cs1"><div id="md4">结束日期</div></td>
      <td width="40" class="td-cs2">
      <div id="md2">
        <input name ="endymd" type="text" class="input1" onClick="javascript:calDate(this);" onKeyPress="javascript:calDate(this);">
      </div>  </td>

    </tr>


    <tr>

     <td  align="center" class="td-cs1">地点</td>
      <td colspan="3" class="td-cs2">
        <input name ="site" type="text" class="input2" maxlength="50"></td>
    </tr>
 </table>
  <table width="539" border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td height="35">
<table width="52%" height="24" border="0" align="center" cellpadding="0" cellspacing="0">
                            <tr align="center">
                              <td width="89"><input name="save" type="image" onclick="mysubmit('0');return false;" src="/agt/public/images/save.gif" width="82" height="22" border="0" onmouseover="this.src='/agt/public/images/'+ this.name + '_2.gif';" onmouseout="this.src='/agt/public/images/'+ this.name + '.gif'"></td>
                              <td width="89"><input name="submit" type="image" onclick="mysubmit('1');return false;" src="/agt/public/images/submit.gif" width="82" height="22" border="0" onmouseover="this.src='/agt/public/images/'+ this.name + '_2.gif';" onmouseout="this.src='/agt/public/images/'+ this.name + '.gif'"></td>
                              <td width="89"><input name="reset" type="image" onclick="Lessonform.reset();changeScope('0');changeScope('1');return false;" src="/agt/public/images/reset.gif" width="82" height="22" border="0" onmouseover="this.src='/agt/public/images/'+ this.name + '_2.gif';" onmouseout="this.src='/agt/public/images/'+ this.name + '.gif'"></td>
                            </tr>
                          </table>
      </td>
    </tr>
  </table>
</form>
                  <script>
function mysubmit(state)
{
   if(lessonCheck())
   {
     var type = document.all.type;
     if(type.value == "0")
     {
        document.all.schoolTime.value =  document.all.schoolTime0.value;
     }
     else if(type.value == "2")
     {
        document.all.schoolTime.value =  document.all.schoolTime2.value;
     }
     else if(type.value == "3")
     {
        document.all.schoolTime.value =  document.all.schoolTime3.value;
     }
    
     var handleid =  document.Lessonform.handleid;
    
     if(handleid.value.indexOf(",") != -1)
     {
        alert("只能输入一个审查人的工号!");
        handleid.focus();
        return false;     
     }
     
     var checkRs = CheckInputNo("<%=GetStaffAction.getLessonChecker()%>",handleid.value);
     if(checkRs != "")
     {
        alert("所输入审查人工号" + checkRs + "不存在或者不具有审查课程的权限!");
        handleid.focus();
        return false;
     }  
     
     var scope = document.Lessonform.scope;
     if(scope.value == "1")
     {
        var staffIds =  document.Lessonform.staffIds;
        var groupIds =  document.Lessonform.groupIds;
    
        var checkStaffNoRs = CheckInputNo("<%=GetStaffAction.getStaffNoStr()%>",staffIds.value);
        if(checkStaffNoRs != "")
        {
            alert("所输入参与人员中工号" + checkStaffNoRs + "不存在!");
            staffIds.focus();
            return false;
        } 
        
        var checkGroupRs =  CheckInputNo("<%=GetStaffAction.getGroupStr()%>",groupIds.value);
        if(checkGroupRs != "")
        {
            alert("所输入参与班组中组号" + checkGroupRs + "不存在!");
            groupIds.focus();
            return false;
        }
        
        ///:huangyuyuan add 2004-06-22
        //对参与人员进行检查,如果输入重复工号,返回错误
        var staffs = staffIds.value.split(",");
        if(staffs.length > 1)
        {
            for(var i = 0; i < staffs.length-1; i++){
                for(var j = i+1; j < staffs.length; j++){
                    if(staffs[i] == staffs[j])
                    {
                        alert("参与人员中包含有重复的工号,请去掉重复的工号!");
                        return false;
                    }
                }
            }
        }
        ///:~
     }
     
     document.forms[0].state.value = state;
     document.forms[0].submit();
   }
}



function changeType(type)
{

   if(type == "0")
   {
        document.all.md1.style.display = "none";
        document.all.md2.style.display = "none";
        document.all.md3.style.display = "none";
        document.all.md4.style.display = "none";
   }
   else
   {
       document.all.md1.style.display =   "inline";
       document.all.md2.style.display =   "inline";
       document.all.md3.style.display =   "inline";
       document.all.md4.style.display =  "inline";
   }
   document.all.type0.style.display = "none";
   document.all.type2.style.display = "none";
   document.all.type3.style.display = "none";

   if(type == "0")
   {
      document.all.type0.style.display = "inline";
   }
   else if(type == "2")
   {
      document.all.type2.style.display =  "inline";
   }
   else if(type == "3")
   {
      document.all.type3.style.display =  "inline";
   }

}

changeType("0");

function changeScope(scope)
{
  var tableRow = document.all.scopeTable.rows;
  if(scope == "0" && tableRow != null && tableRow.length != 0)
  {
       document.all.scopeTable.deleteRow(0);
       document.all.scopeTable.deleteRow(0);
  }
  if(scope == "1")
  {
        var row = document.all.scopeTable.insertRow();
        var cell1=row.insertCell();
        cell1.className = "td-cs1";
        cell1.align = "center";
        cell1.width = "13%";
        
        cell1.innerHTML='参与人员';
        
        var cell2=row.insertCell();
        cell2.className = "td-cs2";
        cell2.width = "87%";
        var ihtml= '<table width="89%" border="0" cellspacing="0" cellpadding="0">';
        ihtml  = ihtml + ' <tr> <td width="63%" > <input name="staffIds" type="text" class="input2" size="40">';
        ihtml  = ihtml + ' </td> <td width="37%"> ';
        
        ihtml  = ihtml + '  <input name="choise" type="image" onClick="openStaffNoW();return false;" src="/agt/public/images/choise.gif" width="48" height="25" border="0">';


        ihtml  = ihtml + ' </td> </tr> </table>';     
        cell2.innerHTML = ihtml;
        
        row = document.all.scopeTable.insertRow();
        cell1=row.insertCell();
        cell1.className = "td-cs1";
        cell1.align = "center";
        cell1.width = "16%";
        
        cell1.innerHTML='参与班组';
        
        cell2=row.insertCell();
        cell2.className = "td-cs2";
        cell2.width = "84%";
        var ihtml= '<table width="89%" border="0" cellspacing="0" cellpadding="0">';
        ihtml  = ihtml + ' <tr> <td width="63%" > <input name="groupIds" type="text" class="input2" size="40" >';
        ihtml  = ihtml + ' </td> <td width="37%"> ';
        
        ihtml  = ihtml + '  <input name="choise" type="image" onClick="openGroupW();return false;" src="/agt/public/images/choise.gif" width="48" height="25" border="0">';


        ihtml  = ihtml + ' </td> </tr> </table>';     
        cell2.innerHTML = ihtml;        
  }
  
}


function openStaffNoW()
{
   window.showModalDialog('/GetStaff.do?opeType=<%=OperatorFlagCode.GET_STAFFNO%>',document.forms[0],'dialogWidth:460px; dialogHeight:380px; toolbar:no; status:no; location:no; scrolling:no; resize:no;');
}

function openGroupW()
{
   
   window.showModalDialog('/GetStaff.do?opeType=<%=OperatorFlagCode.GET_GROUP%>',document.forms[0],'dialogWidth:460px; dialogHeight:380px; toolbar:no; status:no; location:no; scrolling:no; resize:no;'); 
}


</script>
<%@ include file="/agt/public/jsp/bot.jsp" %>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -