群公告的群内提醒,链接跳转
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
<template>
|
||||
<view class="">
|
||||
<view class="notify" v-if="message.objectName === 'RC:GrpNtf'">{{ message.content.message }}</view>
|
||||
<view class="notify" v-if="message.objectName === 'RC:GrpNtf'">
|
||||
{{ message.content.message }}
|
||||
<text class="link" @click="toAnnounce(message.content.extra)"
|
||||
v-if="message.content.operation == 'ANNOUNCEMENT'">点击查看 </text>
|
||||
</view>
|
||||
<view class="notify" v-else-if="message.objectName === 'RC:RcNtf'">
|
||||
{{ contact(message.senderUserId).name }} 撤回了一条消息
|
||||
</view>
|
||||
@@ -75,6 +79,19 @@
|
||||
})
|
||||
}
|
||||
},
|
||||
// 跳转群公告
|
||||
toAnnounce(targetId) {
|
||||
if (targetId) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/im/group/announceCreate?targetId=' + this.targetId
|
||||
})
|
||||
} else {
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '旧版本,无链接'
|
||||
})
|
||||
}
|
||||
},
|
||||
// 撤回消息测试
|
||||
backMessage() {
|
||||
if (this.$store.getters.sender.userId != this.message.senderUserId) {
|
||||
@@ -118,6 +135,11 @@
|
||||
text-align: center;
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
|
||||
.link {
|
||||
color: blue;
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.cell-item {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<template>
|
||||
<view class="create">
|
||||
<view class="create-title">公告内容</view>
|
||||
<block v-if="type !== 'cheack'">
|
||||
<block v-if="type !== 'check'">
|
||||
<u--textarea v-model="content" count height="240" maxlength="240" placeholder="请输入公告内容" />
|
||||
<u-button type="primary" text="发布" :disabled="disabled" @click="onCreate" color="#34CE98" />
|
||||
</block>
|
||||
<block v-if="type === 'cheack'">
|
||||
<block v-if="type === 'check'">
|
||||
<view class="content-a"> {{content}} </view>
|
||||
</block>
|
||||
</view>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
onNavigationBarButtonTap() {
|
||||
if (this.isAdmin) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/im/group/announceCreate?targetId=' + this.targetId
|
||||
url: '/pages/im/group/announceCreate?type=check&targetId=' + this.targetId
|
||||
})
|
||||
} else {
|
||||
uni.showToast({
|
||||
@@ -119,7 +119,7 @@
|
||||
},
|
||||
tabA(id) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/im/group/announceCreate?type=cheack&targetId=' + this.targetId + '&aId=' + id
|
||||
url: '/pages/im/group/announceCreate?type=check&targetId=' + this.targetId + '&aId=' + id
|
||||
})
|
||||
},
|
||||
onTop(aId) {
|
||||
|
||||
@@ -55,7 +55,8 @@ const notifyMsgTypes = [
|
||||
IMLib.ObjectName.Location,
|
||||
IMLib.ObjectName.Voice,
|
||||
IMLib.ObjectName.HQVoice,
|
||||
IMLib.ObjectName.Sight
|
||||
IMLib.ObjectName.Sight,
|
||||
IMLib.ObjectName.GroupNotification
|
||||
]
|
||||
|
||||
const imLibListeners = () => {
|
||||
|
||||
Reference in New Issue
Block a user