当前位置: 代码迷 >> 综合 >> 韩师正方教务管理系统自动评教
  详细解决方案

韩师正方教务管理系统自动评教

热度:0   发布时间:2024-01-19 00:33:59.0

自己改了一个脚本,可以实现同一门课有两个老师需要评课的情况。

使用方法:进入第一门评课界面,F12调出控制台,在console下粘贴下面这段js代码,回车即可运行

            var iframe = window.top.document.getElementById('iframeautoheight');var ifdocument = iframe.contentWindow.document; var subLength = ifdocument.getElementById("pjkc").length - 1;ifdocument.getElementById("TextBox1").value = - 1; function execution(){var iframe = window.top.document.getElementById('iframeautoheight');var ifdocument = iframe.contentWindow.document; var reg = /^DataGrid1__ctl\d+_JS1$/;   var reg2 = /^DataGrid1__ctl\d+_JS2$/;   var selections = ifdocument.getElementsByTagName("select");for(var i = 0 ; i< selections.length; i++){if(reg.test(selections[i].getAttribute("id"))){selections[i].value = "5(优秀)";}if(reg2.test(selections[i].getAttribute("id"))){selections[i].value = "5(优秀)";}}ifdocument.getElementById("Button1").click();}execution();iframe.onload = function(){if(subLength -- > 0){execution();}}

  相关解决方案