// ==UserScript== // @name FCQ网课通助手[全网题库][通用智能适配答题][刷课] // @namespace http://tampermonkey6.net // @version 1.0.45 // @description 支持【超星学习通】【智慧树】【职教云系列】【雨课堂】【考试星】【168网校】【u校园】【大学MOOC】【云班课】【优慕课】【继续教育类】【绎通云课堂】【九江系列】【柠檬文才】【亿学宝云】【优课学堂】【小鹅通】【安徽继续教育】 【上海开放大学】 【华侨大学自考网络助学平台】【良师在线】【和学在线】【人卫慕课】【国家开放大学】【山财培训网(继续教育)】【浙江省高等学校在线开放课程共享平台】【国地质大学远程与继续教育学院】【重庆大学网络教育学院】【浙江省高等教育自学考试网络助学平台】 【湖南高等学历继续教育】 【优学院】 【学起系列】【青书学堂】 【学堂在线】【英华学堂】【广开网络教学平台】等平台的测验考试,内置题库,如有疑问或无法使用加群:685523298 咨询 // @author button2 // @match *://*/* // @run-at document-start // @icon none // @grant GM_xmlhttpRequest // @grant GM_addStyle // @grant GM_getValue // @grant GM_setValue // @grant GM_listValues // @grant GM_deleteValue // @grant GM_getResourceText // @grant GM_getResourceURL // @grant GM_addValueChangeListener // @grant GM_removeValueChangeListener // @grant GM_info // @resource Table https://www.forestpolice.org/ttf/2.0/table.json // @require https://lib.baomitu.com/promise-polyfill/8.3.0/polyfill.min.js // @require https://lf3-cdn-tos.bytecdntp.com/cdn/expire-1-M/jquery/3.6.0/jquery.min.js // @require https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js // @require https://lib.baomitu.com/jquery/3.6.0/jquery.min.js // @require https://lf3-cdn-tos.bytecdntp.com/cdn/expire-1-M/fingerprintjs2/2.1.4/fingerprint2.min.js // @require https://cdn.jsdelivr.net/npm/fingerprintjs2@2.1.4/dist/fingerprint2.min.js // @connect gitee.com // @connect cdn.staticfile.org // @connect cdnjs.cloudflare.com // @connect cdn.bootcss.com // @connect cdn.bootcdn.net // @connect cdn.staticfile.org // @connect unpkg.com // @connect www.e-campus.top // @connect www.ncoa.org.cn // @connect bytecdntp.com // @connect icve.com.cn // @connect icodef.com // @connect muketool.com // @connect ouchn.cn // @connect xuetangx.com // @connect yuketang.cn // @connect jpush.cn // @connect unipus.cn // @connect www.kinglinkcrusher.com // @connect greasyfork.org // @connect smartedu.cn // @connect zhihuishu.com // @connect chaoxing.com // @connect gaoxiaobang.com // @connect njcedu.com // @connect jsou.cn // @connect ulearning.cn // @connect kaoshixing.com // @connect gaoxiaobang.com // @connect open.com.cn // @connect sflep.com // @connect teacher.com.cn // @connect chinaedu.net // @connect sccchina.net // @connect netinnet.cn // @connect learnin.com.cn // @connect ct-edu.com.cn // @connect ismartlearning.cn // @connect youshiyun.com.cn // @connect qdjxjy.com.cn // @connect icourse163.org // @connect webtrn.cn // @connect gxmzu.edu.cn // @connect learn.courshare.cn // @connect haipan.net // @connect xiguashuwang.com // @connect jiaoyu139.com // @connect ahjxjy.cn // @connect qingshuxuetang.com // @connect 168wangxiao.com // @connect xiaoe-tech.com // @connect shou.org.cn // @connect edu-xl.com // @connect hexuezx.cn // @connect pmphmooc.com // @connect lyck6.cn // @connect yinghuaonline.com // @connect aigcfun.com // @connect youdao.com // @connect youkexuetang.cn // @connect cx-online.net // @connect sxmaps.com // @connect eswonline.com // @connect ketangx.net // @connect weirenzheng.cn // @connect cqooc.com // @connect edu-edu.com.cn // @connect fjnu.cn // @connect yxbyun.com // @connect kaoshixing.com // @connect beeouc.com // @connect edu-edu.com // @connect bossyun.com // @connect reseayun.com // @connect sww.com.cn // @connect jinkex.com // @connect zikaoj.com // @connect ls365.net // @connect 91huayi.com // @connect shandong-energy.com // @connect ttcdw.cn // @connect wjx.top // @connect coursera.org // @connect ahjxjy.cn // @connect hbcjpt.com // @connect whu.edu.cn // @connect xjyxjyw.com // @connect yxlearning.com // @connect aqscpx.com // @connect dayoo.com // @connect ncme.org.cn // @connect tikuhai.com // @connect enncy.cn // @connect ocsjs.com // @connect mhtall.com // @connect ustcyun.cn // @connect 0991xl.com // @connect hbysw.org // @connect cj-edu.com // @connect gzbjyzjxjy.cn // @connect superchutou.com // @connect zaixiankaoshi.com // @connect ynjspx.cn // @connect zhifa315.com // @connect jxjypt.cn // @connect hnzkw.org.cn // @connect wentaionline.com // @connect chinahrt.com // @connect ha.cn // @connect tv168.cn // @connect 59iedu.com // @connect cdeledu.com // @connect cncecyy.com // @connect jste.net.cn // @connect ls365.net // @connect brjxjy.com // @connect dyhrsc.cn // @connect vmserver.cn // @connect qdu.edu.cn // @connect xidian.edu.cn // @connect swust.net.cn // @connect ggcjxjy.cn // @connect hebyunedu.com // @connect ncu.edu.cn // @connect jijiaool.com // @connect zikaosw.cn // @connect cmechina.net // @connect ewt360.com // @connect qlteacher.com // @connect mxdxedu.com // @connect ityxb.com // @connect uooc.net.cn // @connect scxfks.com // @connect tsinghuaelt.com // @connect enaea.edu.cn // @connect gzsrs.cn // @connect yanxiu.com // @connect zxhnzq.com // @connect chinaacc.com // @connect ncet.edu.cn // @connect tcmjy.org // @connect baidu.com // @connect xidian.edu.cn // @connect whut.edu.cn // @connect yooc.me // @connect cj-edu.com // @connect cncecyy.com // @connect cjnep.net // @connect zikao365.com // @connect enetedu.com // @connect xueyinonline.com // @connect kepeiol.com // @connect brjxjy.com // @connect ketangx.net // @connect chinamde.cn // @connect examcoo.com // @connect 345u.net // @connect zgzjzj.com // @connect twt.edu.cn // @connect jctnb.org.cn // @connect 21tb.com // @connect zj.gov.cn // @connect zikaosw.cn // @connect spicti.com // @connect haoyisheng.com // @connect enaea.edu.cn // @connect gzsrs.cn // @connect yanxiu.com // @connect ncet.edu.cn // @connect chinahrt.com // @connect zxhnzq.com // @connect ghlearning.com // @connect qlu.edu.cn // @connect baidu.com // @connect hii.cn // @connect hustsnde.com // @connect zgzjzj.com // @connect peishenjy.com // @connect axetk.cn // @connect ipmph.com // @connect hnscen.cn // @connect coursera.cn // @connect udemy.cn // @connect edx.cn // @connect wutp.com // @connect imu.edu.cn // @connect mhys.com.cn // @connect cumt.edu.cn // @connect scit-edu.cn // @connect smartchutou.com // @connect anpeiwang.com // @connect gdut.edu.cn // @connect dwzpzx.com // @connect gzucm.edu.cn // @connect jxuas.edu.cn // @connect 51sunshining.com // @connect hzau.edu.cn // @connect tisco.com.cn // @connect myunedu.com // @connect snnu.edu.cn // @connect hiaskc.com // @connect mynep.com // @connect sinotrans.com // @connect educoder.net // @connect eduwest.com // @connect 345u.net // @connect sclecb.cn // @connect jctnb.org.cn // @connect kuxiao.cn // @connect hsd-es.com // @connect caq.org.cn // @connect nwpu.edu.cn // @connect zhixueyun.com // @connect twt.edu.cn // @connect htsdedu.com // @connect zhongancloud.com // @connect taoke.com // @connect wuxiantiaozhan.com // @connect qutjxjy.cn // @connect yidiankai.net // @connect ncu.edu.cn // @connect gdhkmooc.com // @connect mxdxedu.com // @connect 21tb.com // @connect haoyisheng.com // @connect tencentcs.com // @connect jijiaox.com // @connect czpx.cn // @connect ntu.edu.cn // @connect zsbxx.cn // @connect xjcde.com // @connect e-megasafe.com // @connect 5any.com // @connect euibe.com // @connect whxunw.com // @connect geron-e.com // @connect gsjtpxzx.com // @connect zygbxxpt.com // @connect ibotok.com // @connect qhce.gov.cn // @connect pintia.cn // @connect jsut.edu.cn // @connect bjou.edu.cn // @connect gdsf.gov.cn // @connect qztc.edu.cn // @connect jiangnan.edu.cn // @connect wencaischool.net // @connect ctce.com.cn:8081 // @connect wjx.cn // @connect pbcexam.cn // @connect chnenergy.com.cn // @connect ynou.edu.cn // @connect mwr.gov.cn // @connect safecn.top // @connect yiban.cn // @connect bspapp.com // @connect qust.edu.cn // @connect lut.edu.cn // @connect whcp.edu.cn // @connect chinamobile.com // @connect whcp.edu.cn // @connect swufe-online.com // @connect gaoxiaokaoshi.com // @connect gdcxxy.net // @connect dyhgp.com.cn // @connect yunxuetang.cn // @connect oberyun.com // @connect wsglw.net // @connect zaixian100f.com // @connect njupt.edu.cn // @connect neuedu.com // @connect mynj.cn // @connect zikao.com.cn // @connect swpu.edu.cn // @connect nbut.edu.cn // @connect jmu.edu.cn // @connect ouchn.edu.cn // @connect hnzjpx.net // @connect 21train.cn // @connect ccccltd.cn // @connect faxuanyun.com // @connect ah.cn // @connect tk.icu // @connect ketangpai.com // @connect keyonedu.com // @connect stdu.edu.cn // @connect cloudwis.tech // @connect gdedu.gov.cn // @connect mianyang.cn // @connect ahhjsoft.com // @connect juchiedu.com // @connect jtzyzg.org.cn // @connect lyunedu.com // @connect rdyc.cn // @connect ynau.edu.cn // @connect xuexi.cn // @connect zzu.edu.cn // @connect mystuff.com.cn // @connect treewises.com // @connect hotmatrix.cn // @connect uu-ka.cn // @connect dbask.net // @connect thsk.me // @connect gochati.cn // @connect repl.co // @connect lemtk.xyz // @connect 985211.life // @connect jsdelivr.net // @connect cdnjs.net // @connect upai.com // @connect 121.37.181.234 // @connect 134.175.72.16 // @connect 119.6.233.156 // @connect 49.232.135.103 // @connect 121.4.44.3 // @connect 101.200.60.10 // @connect 173.82.206.140 // @connect 106.13.194.221 // @connect 101.35.141.127 // @connect 119.45.63.245 // @connect 101.42.4.139 // @connect 123.249.44.94 // @connect 163.197.213.153 // @connect 20.222.22.93 // @connect 8.217.54.192 // @connect tcloudbaseapp.com // @connect ylnu.edu.cn // @connect ynny.cn // @connect zjlll.net // @connect lovezhc.cn // @connect localhost // @connect 127.0.0.1 // @connect * // @antifeature payment // @antifeature referral-link // @license MIT // @downloadURL none // ==/UserScript== unsafeWindow.$_=$ if (window.location.href.indexOf("https://service.icourses.cn/") != -1) { const config = { pdf_time: 20 * 60 * 1000//30分鐘 } let ChapterList = [] function GetRessList(id) { return new Promise((resolve, reject) => { GM_xmlhttpRequest({ url: "https://service.icourses.cn/hep-company//sword/company/getRess", method: "POST", data: "sectionId=" + id, headers: { "Content-type": "application/x-www-form-urlencoded; charset=UTF-8" }, onload: function (xhr) { try { resolve(JSON.parse(xhr.responseText).model.listRes) } catch (err) { resolve([]) } } }); }) } function OpenOriginDialog(Content) { return new Promise((resolve, reject) => { unsafeWindow.require(["Play"], function (Play) { let courseId = unsafeWindow._courseId; let userId = unsafeWindow._userId; let companyCode = unsafeWindow._companyCode; const ListenMessage = (e) => { if (e.data === 'lhd_close') { unsafeWindow.removeEventListener('message', ListenMessage) document.querySelector('[id^=dialog-myModal]')?.remove() resolve() } } unsafeWindow.addEventListener('message', ListenMessage); Play.dialog({ //唯一ID id: "videoBox-link", data: { url: Content.fullResUrl, companyCode: companyCode,//三方公司id resId: Content.id, type: Content.mediaType, userId: userId, courseId: courseId, title: Content.title + '' }, //弹出框宽度 width: "auto", //弹出框高度 height: (screen.availHeight - 200) + "px", //是否开启打点功能 isTicker: true }); }) }) } async function ExecteContentMission(Contet) { return new Promise(async (resolve, reject) => { await OpenOriginDialog(Contet) //执行相关内容 resolve() }) } async function AutoExecteChaprterMission(ChapterList) { for (let index = 0; index < ChapterList.length; index++) { let CurrentChapert = ChapterList[index]//获取每个章 let ContentList = await GetRessList(CurrentChapert)//获取该章数据 for (let ContentIndex = 0; ContentIndex < ContentList.length; ContentIndex++) { let CurrentContent = ContentList[ContentIndex]//遍历内容数据列表 await ExecteContentMission(CurrentContent)//执行内容 } } } function InjectButtonToBody() { let btn = document.createElement("div"); btn.innerHTML = ''; btn.onclick = function () { ChapterList = [] ChapterList = ChapterList.concat(...document.querySelectorAll(".shareResources > .panel-group > li")) let ParentChapert = document.querySelectorAll(".shareResources > .panel-group > li:not(.noContent)") ParentChapert.forEach((item) => { ChapterList = ChapterList.concat(...item.querySelectorAll(".chapter-content [data-secid]")) }); ChapterList = ChapterList.map((item) => item.getAttribute("data-id") ?? item.getAttribute("data-secid")) AutoExecteChaprterMission(ChapterList) } document.body.append(btn); } function InjectVideoPage() { unsafeWindow.savevideojs = undefined Object.defineProperty(unsafeWindow, 'videojs', { get() { let result = unsafeWindow.savevideojs; return result }, set(vdobj) { vdobj.hook('beforesetup', function (videoEl, options) { options.muted = true; options.autoplay = true; return options; }); vdobj.hook('setup', function (player) { player.on("ended", function () { }); }); unsafeWindow.savevideojs = vdobj; } }) } function InjectPdfPage() { setTimeout(() => { }, config.pdf_time) } function MainBranch() { if (location.href.indexOf('/sword/rp/play/toPlay') !== -1) { InjectVideoPage() } else if (location.href.indexOf('/icourse/lib/pdfjs/web/') !== -1) { InjectPdfPage() } else { InjectButtonToBody() } } MainBranch() } if (window.location.href.indexOf("https://hzzh.chsi.com.cn/kc/xx/") != -1) { let rate = 2;//倍速 unsafeWindow.onload = function () { //在元素都加载完成后再监听video的播放时间,再进行倍速设置 unsafeWindow.document.querySelector('video').onplay = function () { unsafeWindow.document.querySelector('video').playbackRate = rate; } let hookSetInterval = unsafeWindow.setInterval; unsafeWindow.setInterval = function (a, b) { return hookSetInterval(a, b / rate); } unsafeWindow.document.querySelector('video').volume = 0 unsafeWindow.document.querySelector('video').play() var elevideo = document.querySelector("video"); elevideo.addEventListener('ended', function () { //结束 unsafeWindow.document.querySelector('video').play() }); } } if (window.location.href.indexOf("https://training.tisco.com.cn/front/command/LessonAction") != -1) { setTimeout(() => { // Your code here... setInterval(() => { // 判断当前视频有没有刷完,刷完的话就会暂停,我们就通过左下角是否变成了暂停来进行判断 // let pauseIcon = document.querySelector('.pausecenterchhulqiaoaix').style.display; let pauseIcon = document.querySelector("div[class^='pause']").style.display; console.log(pauseIcon) // 等于none的时候左下角为暂停,没有出现的时候就为block,出现了以后我们就跳到下一节 /* 这个网站右侧列表课程表当前播放的视频类名为cur_li,我们通过这个来判断,播放完成以后就播放它的下一个视频 */ if (pauseIcon == 'none') { // 直接拿到下一个视频的跳转连接 let nextHref = document.querySelector('.cur_li').nextElementSibling.children[0].href window.location.href = nextHref; } }, 3000) }, 5000) } if (window.location.href.indexOf("https://jiangxi.zhipeizaixian.com/study/") != -1) { var facejgt = true; var dtime = a_time / 5; window.setInterval(() => { let autonext = document.querySelector(".modal_mark___2vwrm"); let autoPlay = document.querySelector(".prism-big-play-btn"); let autoverify = document.querySelector(".ant-modal-confirm-btns"); let verifyhint = document.querySelector(".ant-modal-wrap"); let Playbutton = document.querySelector("#J_prismPlayer>video"); if (autonext != null) { setTimeout(function () { document.querySelector('.next_button___YGZWZ').click(); }, 2000); notifyhint('自动跳转', '已自动跳转下一节'); } if (autoPlay.style.display == 'block') { document.querySelector('.outter').click(); if (a_mute) { Playbutton.volume = 0; } } if (verifyhint != null) { if (autoverify == null) { if (facejgt) { notifyhint('人脸识别', '出来人脸识别啦!'); facejgt = false; } } } if (autoverify != null) { setTimeout(function () { document.querySelector('.ant-btn').click(); notifyhint('弹框验证', '已经继续观看'); }, 2000); } if (dtime <= 0) { dtime = a_time / 5; facejgt = true; } dtime--; }, 5000); notifyhint("启动成功", "已成功导入"); } let alllearning; let nolearning = []; let ns_player; let dbg = true; // 判断url是在课程首页 if (/https:\/\/lms.ouchn.cn\/course\/\d+\/ng#\//m.test(document.URL)) { nsd("当前在课程首页"); // 判断全部展开按钮 let cai = $(".expand-collapse-all-button>i"); if (cai.hasClass("font-toggle-all-collapsed")) { nsd("点击全部展开"); cai.click(); } // 加载所有课程 setInterval(function () { nsd("获取所有课程"); ns_nostudy(); }, 5000); } else if (/https:\/\/lms.ouchn.cn\/course\/\d+\/learning-activity\/full-screen#\/\d+/m.test(document.URL)) { nsd("在详情页"); // 处理详情 setTimeout(function () { // 2秒监控一次 setInterval(function () { ns_player = $(".vjs-tech")[0]; if (ns_player) { nsd("页面有视频") ns_playover(); ns_start(); } else { nsd("页面没视频") ns_todown(); } }, 5000); }, 15000); } // 上一页 function ns_pageback() { history.back(-1); } // 获取所有课程 function ns_nostudy() { alllearning = $(".learning-activity"); for (let i = 0; i < alllearning.length; i++) { let str = $(".learning-activity:eq(" + i + ") div.activity-operations-container .completeness").attr("tipsy-literal"); let zf = str.match(/^(\W+)<\/b>/)[1]; let type = str.match(/^\W+<\/b><\/br>(\W+)/)[1]; let typeEum = -1; if (type === "完成指标:查看页面") { typeEum = 1; } else if (type.indexOf("完成指标:需累积观看") > -1) { typeEum = 2; } else if (type.indexOf("访问线上链接") > -1) { typeEum = 3; } else if (type.indexOf("完成指标:参与发帖或回帖") > -1) { typeEum = 4; } else if (type.indexOf("完成指标:观看或下载所有参考资料附件") > -1) { typeEum = 5; } if (zf !== "已完成" && typeEum != -1) { $(".learning-activity:eq(" + i + ")>div").click(); break; // nolearning.push({ // type: typeEum, // id:$(".learning-activity:eq("+i+")").attr("id").replace("learning-activity-",""), // jq:$(".learning-activity:eq("+i+")") // }) } } } function ns_back(nb) { setTimeout(function () { ns_pageback(); }, nb ? nb : 5000); } var ns_pl = false; ; (function (_this) { function opeationUi(menu) { this.fcq_xm_answer = null; this.$ = $; this.menu = menu; this.xm_window=window this.initMenu(); this.config = {} this.qq_group="724809904" unsafeWindow.mainProcedure=this window.mainProcedure=this return this; } opeationUi.prototype.initData = async function () { //初始化 this.xm_ui.find("#token").val(GM_getValue("token")) } opeationUi.prototype.toLog = function (explain) { setInterval(() => { let fcq_xm_select = window.getSelection().toString(); if (fcq_xm_select) { this.xm_ui.find('#fcq_xm_search_text')[0].value = window.getSelection().toString() } }, 400) this.initData(); return this; } opeationUi.prototype.arrowMoveMenu = function (e) { let elW = e.currentTarget.offsetWidth let elH = e.currentTarget.offsetHeight let elL = e.currentTarget.parentNode.parentNode.offsetLeft let elT = e.currentTarget.parentNode.parentNode.offsetTop let x = e.clientX let y = e.clientY let w = window.innerWidth let h = window.innerHeight let moveX = x - elL let moveY = y - elT let el = e.currentTarget document.onmousemove = function (e) { el.parentNode.parentNode.style.left = e.clientX - moveX + 'px' el.parentNode.parentNode.style.top = e.clientY - moveY + 'px' } document.onmouseup = function (e) { document.onmousemove = null document.onmouseup = null } }; opeationUi.prototype.initMenu = function () { let $ = this.$, menu = this.menu; var element = $('
')[0] this.element=element var shadow = element.attachShadow({ mode: 'closed' }); this.xm_ui =$('
') unsafeWindow.fcq_search=true const styleTag = ` `; $(styleTag).appendTo(this.xm_ui); let $menu = $( `
FCQ网课助手
token:
获取(官网)
题目 :
使用前请先获取登录token后填入,选中文字点击搜索即可,更多功能请前往官网查阅,图标可拖动

`); var mask=$(`