From 7e80dc84eb986fb4bf6f3681b71d88ae5fa301ab Mon Sep 17 00:00:00 2001 From: Lei OT Date: Fri, 6 Dec 2024 15:39:49 +0800 Subject: [PATCH] =?UTF-8?q?test:=20=E6=B5=8B=E8=AF=95=E7=89=88=20=E9=82=AE?= =?UTF-8?q?=E4=BB=B6=E5=BC=80=E6=94=BE=E8=B4=A6=E6=88=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/Conversations/Online/ReplyWrapper.jsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/views/Conversations/Online/ReplyWrapper.jsx b/src/views/Conversations/Online/ReplyWrapper.jsx index 1c017d7..ef19807 100644 --- a/src/views/Conversations/Online/ReplyWrapper.jsx +++ b/src/views/Conversations/Online/ReplyWrapper.jsx @@ -10,7 +10,7 @@ import useStyleStore from '@/stores/StyleStore'; import { isEmpty } from '@/utils/commons'; import { DEFAULT_CHANNEL } from '@/config'; import { WABAccounts, WABAccountsMapped } from '@/channel/bubbleMsgUtils'; -import useAuthStore from '@/stores/AuthStore'; +import useAuthStore, { PERM_USE_EMAL} from '@/stores/AuthStore'; /** * @ignore @@ -42,6 +42,7 @@ const WABASwitcher = ({ onSelect, }) => { const ReplyWrapper = () => { const [mobile] = useStyleStore(state => [state.mobile]); const {userId, whatsAppBusiness} = useAuthStore((state) => state.loginUser); + const [isPermitted] = useAuthStore((state) => [state.isPermitted]) const [activeChannel, setActiveChannel] = useState(DEFAULT_CHANNEL); const onChannelTabsChange = (activeKey) => { @@ -72,10 +73,10 @@ const ReplyWrapper = () => { const replyTypes = [ // { key: 'waba', label: mobile ? '' : (), icon: , children: }, { key: 'waba', label: mobile ? '' : `商业号(${WABAccountsMapped[whatsAppBusiness]?.verifiedName || '-'})`, icon: , children: }, - { key: 'email', label: mobile ? '' : '邮件', icon: , children: }, + { key: 'email', label: mobile ? '' : '邮件', icon: , children: isPermitted(PERM_USE_EMAL) ? :
敬请期待
}, // { key: 'whatsapp', label: mobile ? '' : 'WhatsApp', icon: , children: }, { key: 'wa', label: mobile ? '' : 'WhatsApp', icon: , children:
正在开发……敬请期待
}, - // TODO ⬆️WA未登录,要提示用户到个人页面扫码 + // TODO: ⬆️WA未登录,要提示用户到个人页面扫码 ]; return (