try to take over the world!
// ==UserScript==
// @name 博学谷一键提交反馈
// @namespace https://github.com/deargx
// @version 0.1
// @description try to take over the world!
// @author You
// @match http://tlias-stu.boxuegu.com/
// @match http://ntlias-stu.boxuegu.com/
// @grant none
// ==/UserScript==
(function() {
var a = document.createElement('a');
a.style.position = 'fixed';
a.style.right = '50px';
a.style.bottom = '50px'
a.style.display = 'block';
a.style.width = '80px';
a.style.height = '40px';
a.style.textAlign = 'center';
a.style.lineHeight = '40px';
a.style.color = '#fff';
a.style.backgroundColor = 'skyblue';
a.style.textDecoration = 'none'
a.href = '#';
a.innerText = '一键选B';
a.className = 'guanxiao'
document.querySelector('body').appendChild(a);
var guanxiao = document.querySelector('.guanxiao');
guanxiao.onclick = function () {
var timu = document.getElementsByClassName('el-radio-group');
if (timu.length == 0) {
alert('请在反馈页面提交')
} else {
for (let i = 0; i < timu.length; i++) {
// 全选B
timu[i].children[1].children[0].click()
// timu[i].children[0].children[0].click() A
// timu[i].children[2].children[0].click() C
// timu[i].children[3].children[0].click() D
}
document.querySelector('.sub').click();
}
}
})();