From 42b9e51aeb85c10100d945af4bf7b95b87d29609 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 13 May 2022 11:02:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8F=82=E6=95=B0questionTyp?= =?UTF-8?q?e?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/MainPage/ProjectManager/manager.js | 11 +++++++---- .../conversation/components/ChatInput/ChatInput.jsx | 4 ++-- .../customerservice/support/conversation/index.jsx | 9 +++++---- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/src/pages/MainPage/ProjectManager/manager.js b/src/pages/MainPage/ProjectManager/manager.js index 5dab896..c7063df 100644 --- a/src/pages/MainPage/ProjectManager/manager.js +++ b/src/pages/MainPage/ProjectManager/manager.js @@ -42,6 +42,7 @@ class manager extends PureComponent { staffId: '', //智慧客服' staffName:'', //智慧客服 kfType:0,//智慧客服 + questionType:0,//智慧客服 // NTKF_PARAM: { // siteid: "bl_1000", //企业ID,,为固定值 // settingid: "bl_1000_1492484340268", //接待组ID,为固定值,必填 @@ -173,7 +174,7 @@ class manager extends PureComponent { }; render() { const { downlist, projectlist, staloading, tlist, trelist, idList, dateNum } = this.props; - const { datevalue, messId, messageDetail, detailId, noticeDetail, questData, questVisible, mainDetail, isModalVisible, isCloseWs, optionsModal, projectModal, supplierNumber, staffId, staffName, kfType,} = this.state; + const { datevalue, messId, messageDetail, detailId, noticeDetail, questData, questVisible, mainDetail, isModalVisible, isCloseWs, optionsModal, projectModal, supplierNumber, staffId, staffName, kfType, questionType,} = this.state; return ( <> { @@ -321,8 +322,9 @@ class manager extends PureComponent { this.setState({kfType: 2}) this.setState({projectModal: true}) }} - openWin={(index)=>{ - this.setState({kfType: index}) + openWin={(kfType, questionType)=>{ + this.setState({questionType: questionType}) + this.setState({kfType: kfType}) this.setState({optionsModal: false}) this.setState({isModalVisible: true}) this.setState({isCloseWs: false}) @@ -330,6 +332,7 @@ class manager extends PureComponent { }} closeWin={()=>{ this.setState({kfType: 0}) + this.setState({questionType: 0}) this.setState({optionsModal: false}) this.setState({isModalVisible: false}) this.setState({isCloseWs: true}) @@ -338,8 +341,8 @@ class manager extends PureComponent { optionsModal={optionsModal} projectModal={projectModal} isModalVisible={isModalVisible} - //supplierNo='EMPTY' kfType={kfType} + questionType={questionType} staffId={staffId} staffName={staffName} supplierNumber={supplierNumber} diff --git a/src/pages/customerservice/support/conversation/components/ChatInput/ChatInput.jsx b/src/pages/customerservice/support/conversation/components/ChatInput/ChatInput.jsx index 635108a..1bb1bf9 100644 --- a/src/pages/customerservice/support/conversation/components/ChatInput/ChatInput.jsx +++ b/src/pages/customerservice/support/conversation/components/ChatInput/ChatInput.jsx @@ -26,6 +26,7 @@ const ChatInput = ((props) => { isModalVisible, supplierNo, kfType, + questionType, conversationId, isSend, sendMsg, @@ -200,8 +201,7 @@ const ChatInput = ((props) => { "contentType": msg.message.type=="text"?1:msg.message.type=="image"?2:msg.message.type=="file"?3:'', "custType": kfType == 2? 2 : 1, "message": msg.message.type=="image" || msg.message.type=="file" ?JSON.stringify(msg.message.content):msg.message.content, - //"questionType": location.pathname.indexOf('/home')!=-1? 3 : 1, - "questionType": 2, + "questionType": questionType, "supplierNo": supplierNo } API.sendToCs(params).then(res => { diff --git a/src/pages/customerservice/support/conversation/index.jsx b/src/pages/customerservice/support/conversation/index.jsx index b6677c9..99c6dfd 100644 --- a/src/pages/customerservice/support/conversation/index.jsx +++ b/src/pages/customerservice/support/conversation/index.jsx @@ -45,7 +45,7 @@ const conversation = (props) => { const wid = 600 const hei = 500 - let {isModalVisible, isCloseWs, closeWin, hideWin, msgAlert, supplierNumber, staffId, staffName, optionsModal, projectModal, closeOptionsModal, closeProjectModal, kfType, openWin, openProjectWin} = props + let {isModalVisible, isCloseWs, closeWin, hideWin, msgAlert, supplierNumber, staffId, staffName, optionsModal, projectModal, closeOptionsModal, closeProjectModal, kfType, questionType, openWin, openProjectWin} = props const onMsgRender = ()=>{ let serverAvatar = user let data = wsMsg @@ -292,7 +292,7 @@ const getProject = (params)=>{ } ]) closeProjectModal && closeProjectModal() - openWin && openWin(2) + openWin && openWin(2,10) }} okText="确定" cancelText="取消" @@ -317,6 +317,7 @@ const getProject = (params)=>{ textHeight={textHeight} listHeight={listHeight} kfType={kfType} + questionType={questionType} supplierNo={kfType==1?'EMPTY':agentNumber} conversationId={conversationId} closeWin={()=>{ @@ -396,8 +397,8 @@ const getProject = (params)=>{ { closeOptionsModal && closeOptionsModal() }}> -

openWin && openWin(1)}>点击咨询平台客服(平台操作相关问题)

-

openWin && openWin(1)}>点击咨询智慧安全公司客服(iPASS及电子签章相关问题)

+

openWin && openWin(1,2)}>点击咨询平台客服(平台操作相关问题)

+

openWin && openWin(1,6)}>点击咨询智慧安全公司客服(iPASS及电子签章相关问题)

openProjectWin && openProjectWin()}>点击咨询代理机构客服(项目内容相关问题)

}