Compare commits
5 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
efd61b30f4 | ||
|
84096be043 | ||
|
4b7c69ea36 | ||
|
f5ca14f746 | ||
576e950650 |
2
env/.env.test
vendored
2
env/.env.test
vendored
@ -7,6 +7,6 @@ VUE_APP_PREVIEW=false
|
|||||||
#VITE_SOCKET_API=ws://192.168.88.21:9504
|
#VITE_SOCKET_API=ws://192.168.88.21:9504
|
||||||
VITE_BASE_API=http://114.218.158.24:8503
|
VITE_BASE_API=http://114.218.158.24:8503
|
||||||
VITE_SOCKET_API=ws://114.218.158.24:8504
|
VITE_SOCKET_API=ws://114.218.158.24:8504
|
||||||
VITE_EPR_BASEURL=http://172.16.100.93:8503
|
VITE_EPR_BASEURL=http://114.218.158.24:9020
|
||||||
VITE_PAGE_URL=http://172.16.100.93:9032
|
VITE_PAGE_URL=http://172.16.100.93:9032
|
||||||
VUE_APP_WEBSITE_NAME=""
|
VUE_APP_WEBSITE_NAME=""
|
7356
pnpm-lock.yaml
7356
pnpm-lock.yaml
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -146,7 +146,7 @@ watch(
|
|||||||
ServeCheckFriend({ receiver_id: newValue.receiver_id, talk_type: 1 }).then((res) => {
|
ServeCheckFriend({ receiver_id: newValue.receiver_id, talk_type: 1 }).then((res) => {
|
||||||
if (res?.code === 200) {
|
if (res?.code === 200) {
|
||||||
console.log(res, 'ress')
|
console.log(res, 'ress')
|
||||||
isFriend.value = res.data.is_friend
|
isFriend.value = !res.data.is_friend
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -537,7 +537,7 @@ const clearSelectedDateTime = () => {
|
|||||||
<main class="el-main relative">
|
<main class="el-main relative">
|
||||||
<div
|
<div
|
||||||
class="p-[15px] pt-[10px] w-[100%] z-99 absolute"
|
class="p-[15px] pt-[10px] w-[100%] z-99 absolute"
|
||||||
v-if="!isFriend && talkParams.type !== 2"
|
v-if="isFriend && talkParams.type !== 2"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
class="bg-[#FFFFFF] w-[100%] p-[10px] text-[14px] flex justify-between"
|
class="bg-[#FFFFFF] w-[100%] p-[10px] text-[14px] flex justify-between"
|
||||||
|
@ -3,7 +3,7 @@ import { watch, onMounted, ref, nextTick, onUnmounted } from 'vue'
|
|||||||
import { NDropdown, NCheckbox, NPopover, NInfiniteScroll } from 'naive-ui'
|
import { NDropdown, NCheckbox, NPopover, NInfiniteScroll } from 'naive-ui'
|
||||||
import { Loading, MoreThree, ToTop } from '@icon-park/vue-next'
|
import { Loading, MoreThree, ToTop } from '@icon-park/vue-next'
|
||||||
import { bus } from '@/utils/event-bus'
|
import { bus } from '@/utils/event-bus'
|
||||||
import { useDialogueStore, useTalkStore } from '@/store'
|
import { useDialogueStore } from '@/store'
|
||||||
import { formatTime, parseTime } from '@/utils/datetime'
|
import { formatTime, parseTime } from '@/utils/datetime'
|
||||||
import { clipboard, htmlDecode, clipboardImage } from '@/utils/common'
|
import { clipboard, htmlDecode, clipboardImage } from '@/utils/common'
|
||||||
import { downloadImage } from '@/utils/functions'
|
import { downloadImage } from '@/utils/functions'
|
||||||
@ -19,11 +19,8 @@ import RevokeMessage from '@/components/talk/message/RevokeMessage.vue'
|
|||||||
import { voiceToText, ServeMessageReadDetail } from '@/api/chat.js'
|
import { voiceToText, ServeMessageReadDetail } from '@/api/chat.js'
|
||||||
import { confirmBox } from '@/components/confirm-box/service.js'
|
import { confirmBox } from '@/components/confirm-box/service.js'
|
||||||
import ws from '@/connect'
|
import ws from '@/connect'
|
||||||
import { useRouter } from 'vue-router'
|
|
||||||
import avatarModule from '@/components/avatar-module/index.vue'
|
import avatarModule from '@/components/avatar-module/index.vue'
|
||||||
|
|
||||||
const router = useRouter()
|
|
||||||
|
|
||||||
// 定义消息已读状态接口
|
// 定义消息已读状态接口
|
||||||
interface ReadStatus {
|
interface ReadStatus {
|
||||||
msg_ids: string[]
|
msg_ids: string[]
|
||||||
@ -89,28 +86,11 @@ const { dropdown, showDropdownMenu, closeDropdownMenu, isOneMonthBefore } = useM
|
|||||||
const { showUserInfoModal } = useInject()
|
const { showUserInfoModal } = useInject()
|
||||||
const dialogueStore = useDialogueStore()
|
const dialogueStore = useDialogueStore()
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
const talkStore = useTalkStore()
|
|
||||||
// const showUserInfoModal = (uid: number) => {
|
// const showUserInfoModal = (uid: number) => {
|
||||||
// userStore.getUserInfo(uid)
|
// userStore.getUserInfo(uid)
|
||||||
// }
|
// }
|
||||||
// 置底按钮
|
// 置底按钮
|
||||||
const skipBottom = ref(false)
|
const skipBottom = ref(false)
|
||||||
const goToMessage = (result) => {
|
|
||||||
const talk_type = props.talk_type
|
|
||||||
const receiver_id = props.receiver_id
|
|
||||||
dialogueStore.specifiedMsg = encodeURIComponent(
|
|
||||||
JSON.stringify({
|
|
||||||
talk_type,
|
|
||||||
receiver_id,
|
|
||||||
msg_id: result.msg_id,
|
|
||||||
cursor: result.sequence - 15 > 0 ? result.sequence - 15 : 0,
|
|
||||||
direction: 'down',
|
|
||||||
sort_sequence: 'asc',
|
|
||||||
create_time: result.created_at
|
|
||||||
})
|
|
||||||
)
|
|
||||||
talkStore.toTalk(talk_type, receiver_id, router)
|
|
||||||
}
|
|
||||||
// 是否显示消息时间
|
// 是否显示消息时间
|
||||||
const isShowTalkTime = (index: number, datetime: string) => {
|
const isShowTalkTime = (index: number, datetime: string) => {
|
||||||
if (datetime == undefined) {
|
if (datetime == undefined) {
|
||||||
@ -350,16 +330,15 @@ const onContextMenuHandle = (key: string) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const onRowClick = (item: ITalkRecord) => {
|
const onRowClick = (item: ITalkRecord) => {
|
||||||
if (dialogueStore.isOpenMultiSelect) {
|
if (dialogueStore.isOpenMultiSelect && isOneMonthBefore(item.created_at.split(' ')[0])) {
|
||||||
if (!isOneMonthBefore(item.created_at.split(' ')[0])) {
|
|
||||||
return useMessage.info('只支持转发近一个月内的消息')
|
|
||||||
}
|
|
||||||
console.log('item.msg_type', item.msg_type)
|
console.log('item.msg_type', item.msg_type)
|
||||||
if (ForwardableMessageType.includes(item.msg_type)) {
|
if (ForwardableMessageType.includes(item.msg_type)) {
|
||||||
item.isCheck = !item.isCheck
|
item.isCheck = !item.isCheck
|
||||||
} else {
|
} else {
|
||||||
useMessage.info('此类消息不支持转发')
|
useMessage.info('此类消息不支持转发')
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
useMessage.info('只支持转发近一个月内的消息')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -928,11 +907,11 @@ const onCustomSkipBottomEvent = () => {
|
|||||||
<n-icon class="more-tools pointer" :component="MoreThree" @click="onContextMenu($event, item)" />
|
<n-icon class="more-tools pointer" :component="MoreThree" @click="onContextMenu($event, item)" />
|
||||||
</div> -->
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- @click="onJumpMessage(item.extra?.reply?.msg_id)" -->
|
|
||||||
<div
|
<div
|
||||||
v-if="item.extra.reply"
|
v-if="item.extra.reply"
|
||||||
class="talk-reply pointer"
|
class="talk-reply pointer"
|
||||||
@click="goToMessage(item.extra?.reply)"
|
@click="onJumpMessage(item.extra?.reply?.msg_id)"
|
||||||
>
|
>
|
||||||
<n-icon :component="ToTop" size="14" class="icon-top" />
|
<n-icon :component="ToTop" size="14" class="icon-top" />
|
||||||
<span class="ellipsis">
|
<span class="ellipsis">
|
||||||
@ -1077,7 +1056,6 @@ const onCustomSkipBottomEvent = () => {
|
|||||||
&.border {
|
&.border {
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
border: 1px solid var(--im-primary-color);
|
border: 1px solid var(--im-primary-color);
|
||||||
background-color: red;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user