728x90
반응형
날짜/시간 자동 + 예매버튼 자동
var date = 0; // 날짜 (0부터 시작)
var time = 0; // 회차 (0부터 시작)
////////////////////////////////////////// 이하 수정 절대 금지
require(["js/app/performance/service/reservationService"], function(reservationService) {
var ready = false;
async function timer1() {
console.log('날짜 대기 중');
if(document.querySelectorAll('li.item_date')[date] != null ) {
await setting();
document.querySelectorAll('li.item_date')[date].click();
console.log('날짜 선택');
ready = true;
clearInterval(tt);
}
}
function timer2() {
console.log('시간 대기 중');
if(document.querySelectorAll('li.item_time')[time] != null && ready) {
document.querySelectorAll('li.item_time')[time].click();
console.log('시간 선택');
document.querySelector('.button.btColorGreen').click();
console.log('진입');
clearInterval(ss);
}
}
async function setting() {
return new Promise((resolve, reject) => {
$(document).off("click", "#ticketReservation_Btn").on("click", "#ticketReservation_Btn", function(ev) {
var $this = $(this);
var paramsObj = {};
paramsObj.prodId = $this.attr("data-prodid");
paramsObj.prodTypeCode = $this.attr("data-prodtypecode");
paramsObj.pocCode = commonCode.POC_CODE_PC;
paramsObj.btnType = "B";
paramsObj.autheTypeCode = $this.attr("data-autheTypeCode") != "" ? $this.attr("data-autheTypeCode") : $("#tciketProcessBox_preSaleAutheTypeCode").val();
paramsObj.authYn = $this.attr("data-authyn");
paramsObj.processType = commonCode.RESERVATION_CLASS_TYPE_DEFAULT;
reservationService.service.reservationInit(paramsObj);
});
console.log('버튼 세팅 완료');
resolve();
});
}
var tt = setInterval(timer1, 5);
var ss = setInterval(timer2, 100);
});
글로벌용 반자동 호출코드
- 날짜/시간 자동 + 예매버튼 수동
var tt = setInterval(function () {
console.log("날짜 타이머");
if (document.querySelectorAll("li.item_date")[0] != null) {
document.querySelectorAll("li.item_date")[0].click();
clearInterval(tt);
}
}, 5);
var ss = setInterval(function () {
console.log("시간 선택 타이머");
if (document.querySelectorAll("li.item_time")[0] != null) {
document.querySelectorAll("li.item_time")[0].click();
document.querySelector(".button.btColorGreen").click();
clearInterval(ss);
}
}, 100);
날짜 & 회차 1개만 있는 공연
var aa = setInterval(function () {
console.log("예매하기 버튼 타이머");
if (document.querySelectorAll(".button.btColorGreen")[0] != null) {
document.querySelector(".button.btColorGreen").click();
clearInterval(aa);
}
}, 100);
===
728x90
반응형
'티켓팅' 카테고리의 다른 글
| 서버 로그 & DHCP 사설 IP 할당 (0) | 2025.10.26 |
|---|---|
| 불법적인 접근 탐지 기법 (0) | 2025.10.25 |
| UTCk3 시각 동기 프로그램의 시간 근원 :: KRISS(한국표준과학연구원) (0) | 2025.10.24 |