Skip to content

Commit c3c47b7

Browse files
committed
feat: remove message push permission notice
1 parent 2aa3eeb commit c3c47b7

2 files changed

Lines changed: 15 additions & 8 deletions

File tree

web/src/components/Chat.vue

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import { onMounted, ref, watch, nextTick } from 'vue'
33
import { sendMessage } from '@/ws/report'
44
import { useMessageStore } from '@/stores/message'
5-
import { useStatusStore } from '@/stores/ststus'
5+
// import { useStatusStore } from '@/stores/ststus'
66
77
import StatusComponent from '@/components/Status.vue'
88
@@ -11,7 +11,7 @@ defineOptions({
1111
})
1212
1313
const messageStore = useMessageStore()
14-
const statusStore = useStatusStore()
14+
// const statusStore = useStatusStore()
1515
1616
const iptValue = ref('')
1717
const isComposing = ref(false)
@@ -106,7 +106,7 @@ onMounted(() => {
106106
</t-space>
107107
</div>
108108
<div class="input-group">
109-
<t-input
109+
<!-- <t-input
110110
v-model="iptValue"
111111
@compositionstart="isComposing = true"
112112
@compositionend="isComposing = false"
@@ -117,6 +117,13 @@ onMounted(() => {
117117
: '请输入消息内容'
118118
"
119119
:disabled="!statusStore.pushMessagePermission"
120+
/> -->
121+
<t-input
122+
v-model="iptValue"
123+
@compositionstart="isComposing = true"
124+
@compositionend="isComposing = false"
125+
@enter="!isComposing && handleSend()"
126+
placeholder="请输入消息内容"
120127
/>
121128
<t-button
122129
@click="handleSend()"

web/src/pages/Chat/Chat.vue

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import ChatComponent from '@/components/Chat.vue'
33
import { MessagePlugin } from 'tdesign-vue-next'
44
import { onMounted } from 'vue'
55
import { useInfoStore } from '@/stores/info'
6-
import { useStatusStore } from '@/stores/ststus'
6+
// import { useStatusStore } from '@/stores/ststus'
77
import router from '@/router'
88
99
import { getPermission } from '@/utils/push'
@@ -13,11 +13,11 @@ defineOptions({
1313
})
1414
1515
const infoStore = useInfoStore()
16-
const statusStore = useStatusStore()
16+
// const statusStore = useStatusStore()
1717
1818
onMounted(() => {
1919
if (!infoStore.uuid || !infoStore.username) {
20-
MessagePlugin.error('基于保安理由,补充资料后才能进行该操作')
20+
MessagePlugin.error('基于保安理由,阁下需进行补充资料后才能执行该操作')
2121
setTimeout(() => {
2222
router.push('/info')
2323
}, 100)
@@ -30,7 +30,7 @@ onMounted(() => {
3030
<template>
3131
<div class="chat">
3232
<chat-component />
33-
<div v-if="!statusStore.pushMessagePermission" class="tips">
33+
<!-- <div v-if="!statusStore.pushMessagePermission" class="tips">
3434
<t-alert theme="error">
3535
<p>你必须将接收消息权限设置为允许才能继续使用聊天功能。</p>
3636
<p>在浏览器左上角选择允许,然后点击重试按钮。</p>
@@ -41,7 +41,7 @@ onMounted(() => {
4141
<span @click="getPermission(true)">重试</span>
4242
</template>
4343
</t-alert>
44-
</div>
44+
</div> -->
4545
</div>
4646
</template>
4747

0 commit comments

Comments
 (0)