From 388f82c141cbb7bc339b294b5ce8fe25324db6f3 Mon Sep 17 00:00:00 2001 From: Yu Date: Wed, 11 Aug 2021 15:42:34 +0800 Subject: [PATCH] #1286 encode chatbot im title --- .../app/src/main/resources/templates/apps/im/chatbot/index.pug | 2 +- .../app/src/main/resources/templates/apps/im/chatbot/mobile.pug | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/contact-center/app/src/main/resources/templates/apps/im/chatbot/index.pug b/contact-center/app/src/main/resources/templates/apps/im/chatbot/index.pug index ad0e80e..021e2b7 100644 --- a/contact-center/app/src/main/resources/templates/apps/im/chatbot/index.pug +++ b/contact-center/app/src/main/resources/templates/apps/im/chatbot/index.pug @@ -312,7 +312,7 @@ html if models.contains("chatbot") && inviteData.ai && aiid if exchange || exchange == "true" li - a(href="/im/index.html?appid=" + appid + "&orgi=" + orgi + (aiid ? "&aiid=" + aiid : "") + "&ai=false" + (client ? "&client=" + client : '') + (type ? "&type=text" : "") + (skill ? "&skill=" + skill : '') + (agent ? "&agent=" + agent : '') + (title ? "&title=" + title : '') + (url ? "&url=" + url : '') + (traceid ? "&traceid=" + traceid : '') + "&userid=" + userid + "&sessionid=" + sessionid + "&t=" + pugHelper.currentTimeMillis()) 人工坐席 + a(href="/im/index.html?appid=" + appid + "&orgi=" + orgi + (aiid ? "&aiid=" + aiid : "") + "&ai=false" + (client ? "&client=" + client : '') + (type ? "&type=text" : "") + (skill ? "&skill=" + skill : '') + (agent ? "&agent=" + agent : '') + (title ? "&title=" + encodeURIComponent(title) : '') + (url ? "&url=" + url : '') + (traceid ? "&traceid=" + traceid : '') + "&userid=" + userid + "&sessionid=" + sessionid + "&t=" + pugHelper.currentTimeMillis()) 人工坐席 li.cur a(href="javascript:void(0)") 智能客服 else diff --git a/contact-center/app/src/main/resources/templates/apps/im/chatbot/mobile.pug b/contact-center/app/src/main/resources/templates/apps/im/chatbot/mobile.pug index 0908eff..611b3f0 100644 --- a/contact-center/app/src/main/resources/templates/apps/im/chatbot/mobile.pug +++ b/contact-center/app/src/main/resources/templates/apps/im/chatbot/mobile.pug @@ -306,7 +306,7 @@ html var hostname = location.hostname; var protocol = window.location.protocol.replace(/:/g, ''); var username = encodeURIComponent("#{username}"); - var socket = io(protocol + '://' + hostname + ':#{port}/im/chatbot?userid=#{userid}&orgi=#{orgi}&session=#{sessionid}&appid=#{appid}&osname=!{osname}&browser=!{browser}!{skill ? "&skill=" + skill : ""}!{username ? "&nickname='+username+'" : ""}!{agent ? "&agent=" + agent : ""}!{title ? "&title=" + title : ""}!{traceid ? "&url=" + url : ""}!{traceid ? "&traceid=" + traceid : ""}!{aiid ? "&aiid=" + aiid : ""}', {transports: ['websocket', 'polling']}); + var socket = io(protocol + '://' + hostname + ':#{port}/im/chatbot?userid=#{userid}&orgi=#{orgi}&session=#{sessionid}&appid=#{appid}&osname=!{osname}&browser=!{browser}!{skill ? "&skill=" + skill : ""}!{username ? "&nickname='+username+'" : ""}!{agent ? "&agent=" + agent : ""}!{title ? "&title=" + encodeURIComponent(title) : ""}!{traceid ? "&url=" + url : ""}!{traceid ? "&traceid=" + traceid : ""}!{aiid ? "&aiid=" + aiid : ""}', {transports: ['websocket', 'polling']}); socket.on('connect', function () { //service.sendRequestMessage(); //output(''+ new Date().format("yyyy-MM-dd hh:mm:ss") + ' 开始沟通' +'' , 'message callOutConnect-message'); -- GitLab