Last active
June 25, 2022 09:14
-
-
Save JedBeom/778ce846047ae850194aa5391f82a397 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name EBSi 기출문제 | |
// @namespace http://tampermonkey.net/ | |
// @version 1.0 | |
// @description EBSi의 뭣같은 기출문제 다운로드를 고칩니다 | |
// @author JedBeom | |
// @match https://www.ebsi.co.kr/* | |
// @icon https://www.google.com/s2/favicons?sz=64&domain=ebsi.co.kr | |
// @grant none | |
// @run-at document-end | |
// ==/UserScript== | |
function goDownLoadP(imgUrl, wl, irecord, catCd, arCnt, subjectId, isEvenNum,fileExt, paperId) { | |
window.open('https://wdown.ebsi.co.kr/W61001/01exam' + imgUrl, "_blank"); | |
} | |
function goDownLoadH(imgUrl, wl, irecord, catCd, arCnt, subjectId, isEvenNum, fileExt, paperId) { | |
window.open('https://wdown.ebsi.co.kr/W61001/01exam' + imgUrl, '_blank'); | |
} | |
function goDownLoadJ(imgUrl,wl, irecord, catCd, arCnt, subjectId,isEvenNum,fileExt,subjectNm, paperId){ | |
window.open('/ebs/xip/xipa/retrieveCorrectAnswerImagePop.ebs?imageSrc=' + imgUrl, '_blank'); | |
} | |
function goDownLoadJ2(imgUrl, wl, irecord, catCd, arCnt, subjectId,isEvenNum,fileExt) { | |
window.open('https://wdown.ebsi.co.kr/W61001/01exam' + imgUrl, "_blank"); | |
} | |
function goDownLoadR(imgUrl, wl, irecord, catCd, arCnt, subjectId,isEvenNum,fileExt) { | |
window.open('https://wdown.ebsi.co.kr/W61001/01exam' + imgUrl, "_blank"); | |
} | |
function goDownLoadD(imgUrl, wl, irecord, catCd, arCnt, subjectId,isEvenNum,fileExt) { | |
window.open('https://wdown.ebsi.co.kr/W61001/01exam' + imgUrl, "_blank"); | |
} | |
//연도선택시 월리스트조회 | |
function yearSel(){ | |
var bYear = $('#beginYear').val(); | |
var eYear = $('#endYear').val(); | |
// if(bYear > eYear){ | |
eYear = bYear; | |
$("#endYear").val(eYear); | |
// } | |
commonUtil.ajaxCall('/ebs/xip/xipc/previousPaperMonthGet.ajax', jQuery("form[name=paperListFrm]").serialize(), function (result) { | |
if(result.returnCode == 'SUCCESS'){ | |
/* | |
$('input:checkbox[name="monthAll"]').each(function() { | |
this.checked = false; | |
}); | |
$('input:checkbox[name="month"]').each(function() { | |
this.disabled = true; | |
this.checked = false; | |
}); | |
for(var i = 0; i < result.list.length; i++){ | |
$('#month'+result.list[i].month).attr("disabled", false); | |
} | |
*/ | |
} else { | |
alert(result.returnMessage); | |
} | |
$('#monthList').val(''); | |
// $("#monthAll").click(); | |
}); | |
} | |
addJS_Node(goDownLoadP); | |
addJS_Node(goDownLoadH); | |
addJS_Node(goDownLoadJ); | |
addJS_Node(goDownLoadJ2); | |
addJS_Node(goDownLoadR); | |
addJS_Node(goDownLoadD); | |
addJS_Node(yearSel); | |
document.querySelector(".form_split").hidden = 1; | |
document.querySelector("#endYear").hidden = 1; | |
function addJS_Node (text, s_URL, funcToRun, runOnLoad) { | |
var scriptNode = document.createElement ('script'); | |
if (runOnLoad) { | |
scriptNode.addEventListener ("load", runOnLoad, false); | |
} | |
scriptNode.type = "text/javascript"; | |
if (text) scriptNode.textContent = text; | |
if (s_URL) scriptNode.src = s_URL; | |
if (funcToRun) scriptNode.textContent = '(' + funcToRun.toString() + ')()'; | |
var targ = document.querySelector(".popupArea"); | |
targ.appendChild (scriptNode); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment