// ==UserScript== // @name 云端学习(自动评估) // @namespace http://tampermonkey.net/ // @version 1.3.1 // @description 自动评估 // @author Feng // @match https://tech.21tb.com/els/html/studyCourse/studyCourse.enterCourse.do* // @match https://tech.21tb.com/els/html/studyCourse/studyCourse.viewEvaluatePage.do* // @grant none // @downloadURL https://update.greasyfork.icu/scripts/429171/%E4%BA%91%E7%AB%AF%E5%AD%A6%E4%B9%A0%28%E8%87%AA%E5%8A%A8%E8%AF%84%E4%BC%B0%29.user.js // @updateURL https://update.greasyfork.icu/scripts/429171/%E4%BA%91%E7%AB%AF%E5%AD%A6%E4%B9%A0%28%E8%87%AA%E5%8A%A8%E8%AF%84%E4%BC%B0%29.meta.js // ==/UserScript== var a=document.getElementsByClassName("cs-menu-link").length; var b=document.getElementsByClassName("cs-item-active")[0].getElementsByClassName("cs-menu-link")[0].title; var e=document.getElementsByClassName("cs-evaluate-tip"); if(a==2&&b=="课程评估"&&e[0].innerText=="恭喜您已经完成课程学习,请完成课程评估。") {c();} else if(a>=3&&b=="课程评估"&&e[0].innerText=="恭喜您已经完成课程学习,请完成课程评估。") {d();} else if(e[0].innerText=="恭喜您已完成课程评估。") {document.getElementsByClassName("cs-close-btn pull-right cs-btn-head")[0].click(); sleep(); var myVar2 = setInterval(function(){ Submit2() }, 1000);} function c(){ var x=document.getElementsByClassName("cs-input-star"); x[4].click(); var y=document.getElementsByClassName("cs-radio-checked"); var i; for (i = 4; i