慕课作业一键互评

自动进行30次作业互评,默认满分(平时分赛高)

当前为 2024-10-21 提交的版本,查看 最新版本

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         慕课作业一键互评
// @namespace    西电飞舞
// @version      1.0
// @description  自动进行30次作业互评,默认满分(平时分赛高)
// @author       LUOFENGYA
// @match        http://*/*
// @icon         data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant        none
// @include      /https://www.icourse163.org/learn/.*/
// @license      AGPL-3.0
// ==/UserScript==

(function() {
    'use strict';
     const div = document.createElement('div')
    document.body.appendChild(div)
    div.style.cssText = "width:30px;height:30px;background-color: pink; position: absolute;top:200px;left:0px;"
    const button = document.createElement('button')
    button.innerText = '开始'
    div.appendChild(button)
    button.addEventListener('click', function () {
      function timer1(j) {
        setTimeout(function () {
          const select = document.querySelectorAll('.d')
          // console.log(select)
          for (let i = 0; i < select.length; i++) {
            select[i].children[0].checked = true
          }
          const dianpin = document.querySelectorAll('textarea')
          for (let i = 0; i < dianpin.length; i++) {
            dianpin[i].value = "nice"
          }
          // console.log(dianpin)

          const click = document.querySelector('.u-btn-default')
          // console.log(click)
          click.click()
        }
          , j * 5000);
      }
      function timer2(j) {
        setTimeout(function () {
          const next = document.querySelector('.j-gotonext')
          // console.log(next)
          next.click()
        }
          , j * 10000);
      }

      for (let j = 1; j < 31; j++) {
        timer1(j)
        timer2(j)
      }

    })
    // Your code here...
})();