function addHiddenField(n,t,i){$("",{type:"hidden",name:t,value:i}).appendTo(n)}function makeQueryString(n){var i="",t;if(n)for(t in n)n[t]!=""&&n[t]!=undefined&&(i+="&"+t+"="+encodeURIComponent(n[t]));return i}function extractUrl(n){var t,i=n[0].tagName;if(i&&(i.toUpperCase()=="A"||i.toUpperCase()=="BUTTON")&&(t=n.attr("href")),!t&&($form=n.closest("form")).length>0&&(t=$form.attr("action")),!t)throw new Error("gmt.links::extractUrl() : does not link or not exist href value - "+n[0].tagName);return t}function getHttpMethod(n){if(!n)return"get";var t=n.toLowerCase();if($.inArray(t,["get","post"])!=-1)return t;throw new Error("gmt.links::getHttpMethod() : not suppport http method - "+t+', only use "get", "post"');}function showDialog(n,t){try{var u=getHttpMethod(n.attr("data-method")),e=n.attr("data-params"),i=extractUrl(n),r="",o=$("",{name:"showFrame",frameborder:"0",scrolling:"auto",width:"auto",height:"auto"});if(i=="/ActionTarget/NoticeList"||i=="/ActionTarget/MyPage"||i=="/ActionTarget/Faq"||i=="/ActionTarget/UserIO_Main"?r="TableBoard":i=="/ActionTarget/Join"?r="inputSetForm":i=="/ActionTarget/Login"?r="loginPop":i=="/ActionTarget/RequestI"?r="inputSetForm":i=="/ActionTarget/RequestO"?r="inputSetForm":i=="/ActionTarget/GmTransfer"?r="inputSetForm":i=="/ActionTarget/GetUserIO_MAIN"?r="TableBoard":i=="/ActionTarget/SlotList"||i=="/ActionTarget/CasinoList"||i=="/ActionTarget/HotelList"||i=="/ActionTarget/Loading"?r="BigTableBoard":(i=="/ActionTarget/Habanero"||i=="/ActionTarget/Mg"||i=="/ActionTarget/Qt"||i=="/ActionTarget/PP"||i=="/ActionTarget/AB"||i=="/ActionTarget/AG"||i=="/ActionTarget/BnG"||i=="/ActionTarget/CQ9"||i=="/ActionTarget/Playson"||i=="/ActionTarget/GameArt"||i=="/ActionTarget/PlayStar"||i=="/ActionTarget/DreamTech"||i=="/ActionTarget/EvoPlay"||i=="/ActionTarget/PlayNGo"||i=="/ActionTarget/HPP"||i=="/ActionTarget/HCQ9"||i=="/ActionTarget/HNETENT"||i=="/ActionTarget/HREDTIGER"||i=="/ActionTarget/HHABANERO"||i=="/ActionTarget/HBNG"||i=="/ActionTarget/HEVOPLAY"||i=="/ActionTarget/HWAZDAN"||i=="/ActionTarget/HPLAYSON"||i=="/ActionTarget/HPLAYSTAR"||i=="/ActionTarget/HRELAXGAMING"||i=="/ActionTarget/HTRIPLEPG"||i=="/ActionTarget/HGAMEART"||i=="/ActionTarget/HBLUEPRINT"||i=="/ActionTarget/HTHUNDERKICK"||i=="/ActionTarget/HNOLIMITCITY"||i=="/ActionTarget/HMOBILOTS"||i=="/ActionTarget/HPLAYPEARLS"||i=="/ActionTarget/HDRAGOONSOFT"||i=="/ActionTarget/H1X2GAMING"||i=="/ActionTarget/HPGSOFT"||i=="/ActionTarget/HMG"||i=="/ActionTarget/TPPragmaticPlay"||i=="/ActionTarget/TPHABANERO"||i=="/ActionTarget/TPMGDASHURTC"||i=="/ActionTarget/TPQUICKSPIN"||i=="/ActionTarget/TPBLUEPRINT"||i=="/ActionTarget/TPREDRAKE"||i=="/ActionTarget/TPRELAX"||i=="/ActionTarget/TPAG"||i=="/ActionTarget/TPCQ9"||i=="/ActionTarget/TPREDTIGER"||i=="/ActionTarget/TPDRAGONSOFT"||i=="/ActionTarget/TPSPEARHEAD"||i=="/ActionTarget/TPELYSIUM"||i=="/ActionTarget/TPGMW"||i=="/ActionTarget/TPBNG"||i=="/ActionTarget/TPPLAYSON"||i=="/ActionTarget/TPGAMEART"||i=="/ActionTarget/TPNETENT"||i=="/ActionTarget/TPBTG"||i=="/ActionTarget/TPPGSOFT"||i=="/ActionTarget/TPASPECT"||i=="/ActionTarget/TPBETSOFT"||i=="/ActionTarget/TPSKYWIND"||i=="/ActionTarget/TPFTG"||i=="/ActionTarget/TPNETGAMEING"||i=="/ActionTarget/TPPLAYSTAR"||i=="/ActionTarget/TPNAGA"||i=="/ActionTarget/TPNEXTSPING"||i=="/ActionTarget/TPPLAYNGO"||i=="/ActionTarget/TPNOLIMIT"||i=="/ActionTarget/TPHACKSAW"||i=="/ActionTarget/TPAVATARUX"||i=="/ActionTarget/TPGsPP"||i=="/ActionTarget/GoldPP"||i=="/ActionTarget/GoldGAMEART"||i=="/ActionTarget/GoldPLAYSTAR"||i=="/ActionTarget/GoldPLAYTECH"||i=="/ActionTarget/GoldGENESIS"||i=="/ActionTarget/GoldPGSOFT"||i=="/ActionTarget/GoldHABANERO"||i=="/ActionTarget/GoldBOOONGO"||i=="/ActionTarget/GoldCQ9"||i=="/ActionTarget/GoldMICROGAMING"||i=="/ActionTarget/GoldPLAYSON"||i=="/ActionTarget/GoldPLAYANDGO"||i=="/ActionTarget/GoldDREAMTECH"||i=="/ActionTarget/GoldEVOPLAY")&&(r="GameBox"),i=="#")return alert("μ κ² μ€?μ
λλ?"),!1;switch(u){case"get":(query=makeQueryString(t))&&(i.indexOf("?")!=-1?i=i.substring(1)+query:i+="?"+query.substring(1))}switch(u){case"get":$.ajax({url:i,type:"Get",dataType:"json",cache:!1,success:function(n){var t=$(n.dialog);$("body").append(t);t.filter(".modal").modal()}});break;case"post":window.setTimeout(function(){$.ajax({url:i,type:"POST",data:makeQueryString(t),cache:!1,contentType:"application/x-www-form-urlencodedl charset=UTF-8",async:!0,success:function(n){$(".modal-backdrop").remove();$("#modalContent").html(n);$(".modal_info").addClass(r);$(".modal_info").modal("show")},complete:function(){},error:function(){}})},100)}}catch(f){alert(f.message);return}}function dialogCenter(){$contentDiv.dialog("option","position","center")}function isShowDialog(){var n=window.top.$;return n("#_modalWindow").length>0}function closeDialog(n){var n=window.top.$;n(".modal_info").remove()}function parentReload(){return window.parent.location.reload(),!1}function callPopup(n){showDialog(n)}function showActionMemoForm(n,t){showDialog(n,t)}function callSubmit(n){var t=!0,r=extractUrl(n),i=n.attr("data-confirm");i&&(t=confirm(i));t&&n.closest("form").attr("action",r).submit()}function callSearch(n){var r=$("#hid_searchType").val(),u=$("#hid_searchInput").val(),f=$("#hid_pageSize").val(),e=$("#hid_sdate").val(),o=$("#hid_edate").val(),s=$("#hid_jobclass").val(),h=$("#hid_code").val(),c=$("#hid_no").val(),i,t;return n||(n=$("#hid_page").val()),i={searchType:r,searchInput:u,pageSize:f,sdate:e,edate:o,page:n,no:c,jobclass:s,code:h},t=makeQueryString(i),location.href=$(location).attr("href").split("?")[0]+"?"+t.substring(1,t.length),!1}function callLogSearch(){var t=$("#hid_searchType").val(),i=$("#hid_searchInput").val(),r=$("#hid_sdate").val(),u=$("#hid_shour").val(),f=$("#hid_smin").val(),e=$("#hid_edate").val(),o=$("#hid_ehour").val(),s=$("#hid_emin").val(),h=$("#hid_code").val(),c=$("#hid_page").val(),l={searchType:t,searchInput:i,sdate:r,shour:u,smin:f,edate:e,ehour:o,emin:s,code:h,page:c},n=makeQueryString(l);return location.href=$(location).attr("href").split("?")[0]+"?"+n.substring(1,n.length),!1}function callSearchAjax(n,t){var u=$("#hid_searchType").val(),f=$("#hid_searchInput").val(),e=$("#hid_pageSize").val(),o=$("#hid_sdate").val(),s=$("#hid_edate").val(),h=$("#hid_no").val(),c=$("#hid_userId").val(),r,l,i;return n||(n=$("#hid_page").val()),r={searchType:u,searchInput:f,pageSize:e,sdate:o,edate:s,page:n,no:h,userId:c},l=makeQueryString(r),t=="/Common/ListUserMemo"?i=$("#subtab_default_1"):t=="/Common/ListUserIo"?i=$("#tab_myio_6"):t=="/Common/ListBetHistory"?i=$("#tab_myio_8"):t=="/Common/ListBonus"?i=$("#user_comp_list"):t=="/Common/ListRecomm"?i=$("#tab_myio_4"):t=="/Common/ListCoupon"?i=$("#tab_myio_5"):t=="/Common/NoticeList"?i=$("#tab_default_1"):t=="/Common/EventList"?i=$("#tab_default_2"):t=="/Common/FaqList"?i=$("#tab_default_3"):t=="/Common/MessageList"&&(i=$("#tab_default_4")),$.ajax({url:t,type:"get",data:r,async:!1,success:function(n){i.html("");i.html(n);(t=="/Common/ListUserMemo"||t=="/Common/ListAdminMemo")&&mypageclick_event()},error:function(n,t,i){alert(i)}}),!1}function goLink(n){try{var t=n;if(t=="#")return alert("μ κ² μ€?μ
λλ?"),!1;window.setTimeout(function(){$.ajax({url:t,type:"POST",cache:!1,contentType:"application/x-www-form-urlencodedl charset=UTF-8",async:!0,success:function(n){$("#body").append(n)},complete:function(){},error:function(){}})},100)}catch(i){alert(i.message);return}}function mgoLink(n,t){try{var i=n;if(i=="#")return alert("μ κ² μ€?μ
λλ?"),!1;window.setTimeout(function(){$.ajax({url:i,type:"POST",cache:!1,contentType:"application/x-www-form-urlencodedl charset=UTF-8",async:!0,success:function(n){$(".gsp-page").remove();$(".gsp-nav__btn").removeClass("active");var i=$(".gsp-nav__btn:eq("+t+")").addClass("active");$(".gsp-content-wrapper").append(n);$(".main-container").addClass("ng-hide");$(".mobile-main-content").removeClass("ng-hide")},complete:function(){},error:function(){}})},100)}catch(r){alert(r.message);return}}function addAmount(n,t){var i=1===n?$("#AMOUNT_I"):$("#AMOUNT_O"),n=Number(CommaRemove(i.val()));n+=1e4*t;isNaN(n)&&(n=0);i.val(numberWithCommas(n));i.focus()}function resetAmount(n){(1===n?$("#AMOUNT_I"):$("#AMOUNT_O")).val("0")}function isInputNumber(n){var t=String.fromCharCode(n.which);/[0-9]/.test(t)||n.preventDefault()}function addComma(n){var r,t,i,u,f;for(f="",u=n.value.length,t=0;tnew Date&&(i=i-1);r.setDate(r.getDate()+i);document.cookie=n+"="+escape(t)+"; path=/; expires="+r.toGMTString()+";"}function getCookieNotice(){var n=document.cookie;n.indexOf("todayMain=N")<0?$("#divNoticePop").show():$("#divNoticePop").hide();n.indexOf("todayMain2=N")<0?$("#divNoticePop2").show():$("#divNoticePop2").hide();n.indexOf("todayMain3=N")<0?$("#divNoticePop3").show():$("#divNoticePop3").hide();n.indexOf("todayMain4=N")<0?$("#divNoticePop4").show():$("#divNoticePop4").hide();n.indexOf("todayMain5=N")<0?$("#divNoticePop5").show():$("#divNoticePop5").hide();n.indexOf("todayMain101=N")<0?$("#divNoticePop101").show():$("#divNoticePop101").hide();n.indexOf("todayMain102=N")<0?$("#divNoticePop102").show():$("#divNoticePop102").hide()}function getUserCheck(){$.ajax({type:"POST",url:"/Common/GetUserCheck",contentType:"application/x-www-form-urlencodedl charset=UTF-8",success:function(){},error:function(){}})}function minToHour(n){return"{0}μκ° {1}λΆμ ".replace("{0}",parseInt(n/60)).replace("{1}",n%60)}function numberWithCommas(n){return n.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function CommaRemove(n){return n.replace(/,/g,"")}var io_type="",io_type_first=!0,io_check_origin=0,io_check_new=0;$(document).ready(function(){$(".category-btn").on("click",function(){var n="",t=$(this).index();switch(t){case 0:n="Table";break;case 1:n="Slot"}if(t>1)return!0;if(n=="")return langchange()=="K"&&alert("μ€λΉ?μ€?μ
λλ?"),!1;SetGameType(n)});$(document).on("click","button#btn_bonus",function(){var n=$(this).attr("data-bonusseq");return confirm($(this).attr("data-confirm"))&&$.ajax({url:"/Common/UserBonus",type:"POST",data:{bonusSeq:n},contentType:"application/x-www-form-urlencodedl charset=UTF-8",dataType:"json",success:function(n){alert(n.message);n.success&&parentReload()},error:function(n){alert(n.responseText)}}),!1}).on("click","button#btn_coupon",function(){var n=$(this).attr("data-cpnseq");return confirm($(this).attr("data-confirm"))&&$.ajax({url:"/Common/UseCoupon",type:"POST",data:{cpnSeq:n},contentType:"application/x-www-form-urlencodedl charset=UTF-8",dataType:"json",success:function(n){alert(n.message);n.success&&parentReload()},error:function(n){alert(n.responseText)}}),!1})}),function(n,t){"use strict";var i=t;n(i).on("load",function(){n(document).ajaxStart(function(){n("#nowLoad").css("display","block")}).ajaxSuccess(function(){n("#nowLoad").css("display","none")}).ajaxError(function(){n("#nowLoad").css("display","none")});n("#imgLogo").on("click",function(){SetGameType("Slot")});n("#LoginName,#Password").keydown(function(t){if(t.keyCode==13)return n("#btn_login").trigger("click"),!1});n("#btn_login").click(function(){if(n("#LoginName").val()=="")return alert("μμ΄λλ₯Ό μ
λ ₯ν΄μ£ΌμΈμ"),!1;if(n("#Password").val()=="")return alert("λΉλ°λ²νΈλ₯?μ
λ ₯ν΄μ£ΌμΈμ"),!1;var i=n(this).button("loading"),r=n("#frmDialogSubmit").serialize();return n.ajax({url:"/Common/Login",type:"POST",data:r,contentType:"application/x-www-form-urlencodedl charset=UTF-8",dataType:"json",success:function(n){n.success?t.parent.location.reload():(alert(n.message),i.button("reset"))},error:function(){location.reload()}}),!1}),function(n){n(function(){var t=n("#LoginName").val();t==0?n("#LoginName").focus():n("#Password").focus()})}(jQuery);n(".logout-btn").on("click",function(){swal({title:"λ‘κ·Έμμ",text:"λ‘κ·Έμμ νμκ² μ΅λκΉ?",type:"warning",buttons:!0,dangerMode:!0}).then(t=>{t&&n.ajax({url:"/Common/Logout",type:"POST",data:null,contentType:"application/x-www-form-urlencodedl charset=UTF-8",dataType:"json",success:function(n){alert(n.message);location.reload()},error:function(){}})})});n("a#a_noticeview").click(function(){var t=n(this),i=t.attr("data-noticeid");return showActionMemoForm(t,{noticeId:i}),!1});n("a#a_faqview").click(function(){var t=n(this),i=t.attr("data-faqid");return showActionMemoForm(t,{faqId:i}),!1});n("input[name='io_balance']").on("change",function(){io_type=n(this).val()=="yin"?"I":"O";io_type_first=!0;io_check_origin=0;io_check_new=0;var t=n(this).val();t=="yin"?(n("#ioPresent_yin").show(),n("#ioPresent_yang").hide()):(n("#ioPresent_yin").hide(),n("#ioPresent_yang").show())});n("#ioPresent_yin").show();n("#ioPresent_yang").hide();n(".btnPopNoticeClose").on("click",function(){var t=n(this).data("option");document.getElementById("nottoday"+t).checked==!0&&setCookieNotice("todayMain"+t,"Y",1);n("#divNoticePop"+t).hide()});n("#btnPopNoticeClose").on("click",function(){var t=n(this).data("option");document.getElementById("nottoday"+t).checked==!0&&setCookieNotice("todayMain"+t,"Y",1);n(grandparents).hide()});n("#btnPopNoticeClose2").on("click",function(){document.getElementById("nottoday2").checked==!0&&setCookieNotice("todayMain2","Y",1);n("#divNoticePop2").hide()});n("#btnPopNoticeClose3").on("click",function(){document.getElementById("nottoday3").checked==!0&&setCookieNotice("todayMain3","Y",1);n("#divNoticePop3").hide()});n("#btnPopNoticeClose4").on("click",function(){document.getElementById("nottoday4").checked==!0&&setCookieNotice("todayMain4","Y",1);n("#divNoticePop4").hide()});n("#btnPopNoticeClose5").on("click",function(){document.getElementById("nottoday5").checked==!0&&setCookieNotice("todayMain5","Y",1);n("#divNoticePop5").hide()})})}(jQuery,window)