var nowSupplier = 'redtie'; var chat_meta = {"host" : "222", "host_name" : "hotel_grabel", "lang" : "1", "supportedLangs" : "1,2,3,4","qrLocation" : "", "country" : "US", "sds_url" : "https://sds.maum.ai:443", "previousSess" : "y", "chatServerURL" : "https://fast-aicc.maum.ai:50000", "hostAddJs" : ""}; // var sds_url = 'https://sds.maum.ai'; var chatOpenClose; function mainFunction() { var sds_url = chat_meta.sds_url; var host_name = chat_meta.host_name; var qrLocation = chat_meta.qrLocation; var previousSess = chat_meta.previousSess; var hostNo = chat_meta.host; var hostAddJs = chat_meta.hostAddJs; if (host_name === "chatbot") { alert("챗봇 Host 오류"); throw new Error('챗봇 Host 오류'); } var iframe_url = sds_url + '/' + host_name + '/' + qrLocation; var chatbot_tag = '
\n' + ' \n' + '
'; var nowSupplierTag = '' var nowSupplierHtml = '' if (nowSupplier === 'mindslab'){ nowSupplierTag = '/resources/images/img_tit_mindsLab.png' }else if (nowSupplier === 'redtie'){ nowSupplierTag = '/resources/images/img_tit_redtie.svg' } if(nowSupplierTag.length>0){ nowSupplierHtml = '

Powered by RedTie Butler

'; } var floating_tag = '
\n' + ' 무엇을 도와드릴까요?
\n' + ' How may I help you?\n' + ' \n' + '
\n' + nowSupplierHtml; if ($("#chatbot").length !== 1) { $("body").append(chatbot_tag); // qr 버전일때는 floating tag를 띄우지 않음 if (qrLocation === undefined || qrLocation === '') { $("body").append(floating_tag); } if(hostAddJs === "hostAddJs"){ var hostAddTag = '