function fn_incenter(a_code,a_class,a_jisa){ $(".li_class").removeClass("active"); $("#group_code_"+a_class).addClass("active"); jisa_network_info(a_jisa); } function jisa_network_info(p_jisaCode){ $("#group_name").empty(); $("#intro_text").empty(); $("#group_address").empty(); $("#group_roadaddr").empty(); $("#group_roadmap").empty(); $("#group_tel").empty(); $("#group_fax").empty(); $("#group_mail").empty(); $("#kakao_id").empty(); $("#group_24tel").empty(); $("#group_pic").empty(); $("#group_pic_gallery").empty(); $("#group_mapimg").empty(); $("#addr_tooltip").empty(); $("#pdf_btn").empty(); var tmp_pic1,tmp_pic2,tmp_pic3,tmp_pic4,tmp_pic5,tmp_pic6,tmp_pic7,tmp_pic8,tmp_pic9,tmp_pic10,tmp_pic11,tmp_pic12 tmp_pic1=""; tmp_pic2=""; tmp_pic3=""; tmp_pic4=""; tmp_pic5=""; tmp_pic6=""; tmp_pic7=""; tmp_pic8=""; tmp_pic9=""; tmp_pic10=""; tmp_pic11=""; tmp_pic12=""; var param = 'group_code='+ p_jisaCode; $.ajax({ url: '/service/user_support/svc_network.asp', type: 'POST', data: param, dataType: 'json', //timeout: 3000, error: function(p_req, p_status, p_err) { alert("["+ p_status + "]"+"지사정보 연결중 오류가 발생되었습니다."); }, success: function(p_data) { if(dvf_ISNULL(p_data.group_name, "") != ""){ //센터명 $("#group_name").html(p_data.group_name); } if(dvf_ISNULL(p_data.intro_text, "") != ""){ //센터소개 $("#intro_text").html(unescape(p_data.intro_text)); } if(dvf_ISNULL(p_data.group_address, "") != ""){ //주소 $("#group_address").html("주소 : "+unescape(p_data.group_address)); } if(dvf_ISNULL(p_data.group_roadaddr, "") != ""){ //도로명 주소 $("#group_roadaddr").html("도로명 주소 : "+unescape(p_data.group_roadaddr)); } if(dvf_ISNULL(p_data.group_pure_addr, "") != ""){ //구글맵 툴팁 $("#addr_tooltip").html("주소 : "+unescape(p_data.group_pure_addr)); } if(dvf_ISNULL(p_data.group_roadmap, "") != ""){ //오시는길 $("#group_roadmap").html("오시는길 : "+unescape(p_data.group_roadmap)); } if(dvf_ISNULL(p_data.group_tel, "") != ""){ //TEL $("#group_tel").html("Tel : "+unescape(p_data.group_tel)); } if(dvf_ISNULL(p_data.group_fax, "") != ""){ //FAX $("#group_fax").html("Fax : "+unescape(p_data.group_fax)); } if(dvf_ISNULL(p_data.group_mail, "") != ""){ //MAIL $("#group_mail").html("E-Mail : "+unescape(p_data.group_mail)); } if(dvf_ISNULL(p_data.kakao_id, "") != ""){ //카카오톡ID $("#kakao_id").html("카카오톡 ID : "+unescape(p_data.kakao_id)); } if(dvf_ISNULL(p_data.group_24tel, "") != ""){ //24시간 상담전화 $("#group_24tel").html("24시간 상담전화 : "+unescape(p_data.group_24tel)); } if(dvf_ISNULL(p_data.group_pic1, "") != ""){ //센터 전경 이미지 tmp_pic1 = ""; } if(dvf_ISNULL(p_data.group_pic2, "") != ""){ // tmp_pic2 = ""; } if(dvf_ISNULL(p_data.group_pic3, "") != ""){ // tmp_pic3 = ""; } if(dvf_ISNULL(p_data.group_pic4, "") != ""){ // tmp_pic4 = ""; } if(dvf_ISNULL(p_data.group_pic5, "") != ""){ // tmp_pic5 = ""; } if(dvf_ISNULL(p_data.group_pic6, "") != ""){ // tmp_pic6 = ""; } if(dvf_ISNULL(p_data.group_pic7, "") != ""){ // tmp_pic7 = ""; } if(dvf_ISNULL(p_data.group_pic8, "") != ""){ // tmp_pic8 = ""; } if(dvf_ISNULL(p_data.group_pic9, "") != ""){ // tmp_pic9 = ""; } if(dvf_ISNULL(p_data.group_pic10, "") != ""){ // tmp_pic10 = ""; } if(dvf_ISNULL(p_data.group_pic11, "") != ""){ // tmp_pic11 = ""; } if(dvf_ISNULL(p_data.group_pic12, "") != ""){ // tmp_pic12 = ""; } $("#group_pic").html(""); fn_gallery(); //갤러리 호출 fn_googleMap(p_data.group_pure_addr); if(p_jisaCode !=61){ $("#pdf_btn").html("센터소개 바로출력"); } } }); } function fn_googleMap(realAddr) { var geocoder = new google.maps.Geocoder(); geocoder.geocode( { 'address': realAddr}, function(results, status) { if (status == google.maps.GeocoderStatus.OK) { var latlng = new google.maps.LatLng(37.4927509, 127.0342735); var mapOptions = {zoom: 17, center: latlng} var map = new google.maps.Map(document.getElementById('group_mapimg'), mapOptions); map.setCenter(results[0].geometry.location); var infowindow = new google.maps.InfoWindow({}); var marker = new google.maps.Marker({map: map, position: results[0].geometry.location }); infowindow.setContent('유학네트 ' + $("#group_name").text() + '
' + $("#addr_tooltip").text()); infowindow.open(map, marker); }else{ return false; } }); } function fn_gallery(){ $("area[rel^='prettyPhoto']").prettyPhoto(); $(".gallery:first a[rel^='prettyPhoto']").prettyPhoto({animation_speed:'normal',theme:'light_square',slideshow:3000, autoplay_slideshow: false}); $(".gallery:gt(0) a[rel^='prettyPhoto']").prettyPhoto({animation_speed:'fast',slideshow:10000, hideflash: true}); $("#custom_content a[rel^='prettyPhoto']:first").prettyPhoto({ changepicturecallback: function(){ initialize(); } }); $("#custom_content a[rel^='prettyPhoto']:last").prettyPhoto({ changepicturecallback: function(){ _bsap.exec(); } }); } //클릭된 삭제버튼(a link 의 data-whatever값) 데이터를 저장해둠 $('#gallery').on('show.bs.modal', function (event) { var button = $(event.relatedTarget); var title = $(button).parents(".tab-pane").find(".tab-title").html(); $("#title").html(title); });