diff --git a/config/config.UAT.ts b/config/config.UAT.ts index c31047c..19ebc69 100644 --- a/config/config.UAT.ts +++ b/config/config.UAT.ts @@ -21,5 +21,25 @@ export default defineConfig({ // REACT_APP_XUNJIA_REDIRECT: 'http://10.0.204.215:8280/provider_uat', //询价-查看报价详情-虚拟用户uid REACT_APP_XUNJIA_UID: 'admin_entrance', + + // //智慧客服ws地址 + // REACT_APP_CUSTOMERSERVICE_WS_REDIRECT: 'ws://10.242.31.158:18022/api/api/biz-customer-service', + + //智慧客服用户中心地址 + REACT_APP_CUSTOMERSERVICE_USERCENTER: 'http://10.242.31.158:18022/auth/oauth/authorize?response_type=code', + + //智慧客服client_id + REACT_APP_CUSTOMERSERVICE_CLIENT_ID: 'COsHJydx', + + //智慧客服地址 + REACT_APP_CUSTOMERSERVICE_REDIRECT: 'http://10.242.31.158:8632', + + // //智慧客服文档中心查看图片地址 + // REACT_APP_CUSTOMERSERVICE_DOC_REDIRECT: 'http://cos.gz-tst.cos.tg.unicom.local/349553515466:mall/', + + // //智慧客服加密公钥私钥ciphercode + // REACT_APP_CUSTOMERSERVICE_PUBLICKEY : '0428D625CEEB71CE823BD7D78DFEE7B122F2DA5C4D21E32253AD684D0FE21810394A799639C0CDFBFEB535A1DFD6A366A637E582CE0B1466A5FE7858841135DE6B', + // REACT_APP_CUSTOMERSERVICE_PRIVATEKEY : '4F7144028D4DCF88FA50F0E2B3FFDDCF63BBE17D1700537DCE037687D3AA3DA7', + // REACT_APP_CUSTOMERSERVICE_CIPHERCODE : 1, }, }); diff --git a/config/config.dev.ts b/config/config.dev.ts index 2a4cf79..2b07069 100644 --- a/config/config.dev.ts +++ b/config/config.dev.ts @@ -21,5 +21,25 @@ export default defineConfig({ // REACT_APP_XUNJIA_REDIRECT: 'http://10.0.204.215:8080/provider_dev', //询价-查看报价详情-虚拟用户uid REACT_APP_XUNJIA_UID: 'admin_entrance', + + //智慧客服用户中心地址 + REACT_APP_CUSTOMERSERVICE_USERCENTER: 'http://10.242.31.158:8100/auth/oauth/authorize?response_type=code', + + //智慧客服client_id + REACT_APP_CUSTOMERSERVICE_CLIENT_ID: 'COsHJydx', + + //智慧客服地址 + REACT_APP_CUSTOMERSERVICE_REDIRECT: 'http://10.242.31.158:8632', + + // //智慧客服ws地址 + // REACT_APP_CUSTOMERSERVICE_WS_REDIRECT: 'ws://10.242.37.148:18022/api/api/biz-customer-service', + + // //智慧客服文档中心查看图片地址 + // REACT_APP_CUSTOMERSERVICE_DOC_REDIRECT: 'http://cos.gz-tst.cos.tg.unicom.local/349553515466:mall/', + + // //智慧客服加密公钥私钥ciphercode + // REACT_APP_CUSTOMERSERVICE_PUBLICKEY : '0428D625CEEB71CE823BD7D78DFEE7B122F2DA5C4D21E32253AD684D0FE21810394A799639C0CDFBFEB535A1DFD6A366A637E582CE0B1466A5FE7858841135DE6B', + // REACT_APP_CUSTOMERSERVICE_PRIVATEKEY : '4F7144028D4DCF88FA50F0E2B3FFDDCF63BBE17D1700537DCE037687D3AA3DA7', + // REACT_APP_CUSTOMERSERVICE_CIPHERCODE : 1, }, }); diff --git a/config/config.prod.ts b/config/config.prod.ts index c00bb2e..a3545df 100644 --- a/config/config.prod.ts +++ b/config/config.prod.ts @@ -21,5 +21,23 @@ export default defineConfig({ // REACT_APP_XUNJIA_REDIRECT: 'https://60.10.26.178/provider', //询价-查看报价详情-虚拟用户uid REACT_APP_XUNJIA_UID: 'admin_entrance', + //智慧客服用户中心地址 + REACT_APP_CUSTOMERSERVICE_USERCENTER: 'https://uscm.chinaunicom.cn:18023/auth/oauth/authorize?response_type=code', + + //智慧客服client_id + REACT_APP_CUSTOMERSERVICE_CLIENT_ID: 'COsHJydx', + + //智慧客服地址 + REACT_APP_CUSTOMERSERVICE_REDIRECT: 'https://uscm.chinaunicom.cn:18011', + // //智慧客服ws地址 + // REACT_APP_CUSTOMERSERVICE_WS_REDIRECT: 'ws://uscm.unicom.local:18022/api/api/biz-customer-service', + + // //智慧客服文档中心查看图片地址 + // REACT_APP_CUSTOMERSERVICE_DOC_REDIRECT: 'http://cos.xx-pbc.cos.tg.unicom.local/349553515466:mall/', + + // //智慧客服加密公钥私钥ciphercode + // REACT_APP_CUSTOMERSERVICE_PUBLICKEY : '0428D625CEEB71CE823BD7D78DFEE7B122F2DA5C4D21E32253AD684D0FE21810394A799639C0CDFBFEB535A1DFD6A366A637E582CE0B1466A5FE7858841135DE6B', + // REACT_APP_CUSTOMERSERVICE_PRIVATEKEY : '4F7144028D4DCF88FA50F0E2B3FFDDCF63BBE17D1700537DCE037687D3AA3DA7', + // REACT_APP_CUSTOMERSERVICE_CIPHERCODE : 1, }, }); diff --git a/config/config.sim.ts b/config/config.sim.ts index fa9e473..2538565 100644 --- a/config/config.sim.ts +++ b/config/config.sim.ts @@ -21,5 +21,23 @@ export default defineConfig({ // REACT_APP_XUNJIA_REDIRECT: 'http://10.0.204.215:8080/provider', //询价-查看报价详情-虚拟用户uid REACT_APP_XUNJIA_UID: 'admin_entrance', + //智慧客服用户中心地址 + REACT_APP_CUSTOMERSERVICE_USERCENTER: 'http://10.242.31.158:8100/auth/oauth/authorize?response_type=code', + + //智慧客服client_id + REACT_APP_CUSTOMERSERVICE_CLIENT_ID: 'COsHJydx', + + //智慧客服地址 + REACT_APP_CUSTOMERSERVICE_REDIRECT: 'http://10.242.31.158:8632', + // //智慧客服ws地址 + // REACT_APP_CUSTOMERSERVICE_WS_REDIRECT: 'ws://10.242.31.54:18022/api/api/biz-customer-service', + + // //智慧客服文档中心查看图片地址 + // REACT_APP_CUSTOMERSERVICE_DOC_REDIRECT: 'http://cos.xx-pbc.cos.tg.unicom.local/349553515466:mall/', + + // //智慧客服加密公钥私钥ciphercode + // REACT_APP_CUSTOMERSERVICE_PUBLICKEY : '0428D625CEEB71CE823BD7D78DFEE7B122F2DA5C4D21E32253AD684D0FE21810394A799639C0CDFBFEB535A1DFD6A366A637E582CE0B1466A5FE7858841135DE6B', + // REACT_APP_CUSTOMERSERVICE_PRIVATEKEY : '4F7144028D4DCF88FA50F0E2B3FFDDCF63BBE17D1700537DCE037687D3AA3DA7', + // REACT_APP_CUSTOMERSERVICE_CIPHERCODE : 1, }, }); diff --git a/package.json b/package.json index b759f9c..57a7017 100644 --- a/package.json +++ b/package.json @@ -4,14 +4,14 @@ "private": true, "description": "An out-of-box UI solution for enterprise applications", "scripts": { - "start-dev": "cross-env UMI_UI=none UMI_ENV=dev LOGIN_PATH=login umi dev --port=3000", - "start-UAT": "cross-env UMI_UI=none UMI_ENV=UAT LOGIN_PATH=login umi dev --port=3000", - "start-sim": "cross-env UMI_UI=none UMI_ENV=sim LOGIN_PATH=login umi dev --port=3000", - "start-prod": "cross-env UMI_UI=none UMI_ENV=prod LOGIN_PATH=prod/login umi dev --port=3000", - "build-dev": "cross-env UMI_ENV=dev LOGIN_PATH=login umi build", - "build-UAT": "cross-env UMI_ENV=UAT LOGIN_PATH=login umi build", - "build-sim": "cross-env UMI_ENV=sim LOGIN_PATH=login umi build", - "build-prod": "cross-env UMI_ENV=prod LOGIN_PATH=prod/login umi build", + "start-dev": "cross-env UMI_UI=none UMI_ENV=dev LOGIN_PATH=ebtp-frontend umi dev --port=3000", + "start-UAT": "cross-env UMI_UI=none UMI_ENV=UAT LOGIN_PATH=ebtp-frontend umi dev --port=3000", + "start-sim": "cross-env UMI_UI=none UMI_ENV=sim LOGIN_PATH=ebtp-frontend umi dev --port=3000", + "start-prod": "cross-env UMI_UI=none UMI_ENV=prod LOGIN_PATH=prod/ebtp-frontend umi dev --port=3000", + "build-dev": "cross-env UMI_ENV=dev LOGIN_PATH=ebtp-frontend umi build", + "build-UAT": "cross-env UMI_ENV=UAT LOGIN_PATH=ebtp-frontend umi build", + "build-sim": "cross-env UMI_ENV=sim LOGIN_PATH=ebtp-frontend umi build", + "build-prod": "cross-env UMI_ENV=prod LOGIN_PATH=prod/ebtp-frontend umi build", "analyze": "cross-env ANALYZE=1 umi build", "build": "umi build", "deploy": "npm run site && npm run gh-pages", diff --git a/src/assets/img/kefu.png b/src/assets/img/kefu.png new file mode 100644 index 0000000..4bd2a8f Binary files /dev/null and b/src/assets/img/kefu.png differ diff --git a/src/components/Promenu/index.tsx b/src/components/Promenu/index.tsx index 0615e2c..199d7c1 100644 --- a/src/components/Promenu/index.tsx +++ b/src/components/Promenu/index.tsx @@ -9,6 +9,7 @@ import { getReadInfo, menuList, updateReadStatus } from './service/service'; import { getProName, getSessionRoleData, getProTypeCode, getDefId, getPurchaseCanOperate, getReturnURL, getProId, getProMethod } from '@/utils/session'; import { Step, StepButton, StepLabel, Stepper, Toolbar, Popover, Typography } from '@material-ui/core'; import { isEmpty } from '@/utils/CommonUtils'; +import { CustomerServiceTwoTone } from '@ant-design/icons'; const useStyles = makeStyles((theme: Theme) => ({ root: { @@ -194,6 +195,29 @@ const Promenu: React.FC<{}> = () => { const handlePopoverClose = () => { setAnchorEl(null); }; + const initChatUI = () => { //智慧客服 + if(MethodDict!='procurement_mode_6' && MethodDict!='procurement_mode_7' && window.location.pathname.indexOf('BidEvaluation')!=-1){ + message.warn('非谈判类项目【评标】阶段禁止沟通') + }else{ + var tempForm = document.getElementById('tempForm_CustomerService') as HTMLFormElement + if(tempForm){ + var hideInput = document.getElementById('tempInput_CustomerService') as HTMLInputElement + if(hideInput){ + hideInput.value= window.location.pathname + }else{ + hideInput = document.createElement("input") + hideInput.id = 'tempInput_CustomerService' + hideInput.type="hidden" + hideInput.name= 'sceneUrl' + hideInput.value= window.location.pathname + tempForm.appendChild(hideInput) + } + tempForm.submit(); + }else{ + message.warn('请先选择跟进的项目') + } + } + } return (