From 27cd042df9aca0383a49f3514bc21958dd890912 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期一, 29 六月 2026 15:42:23 +0800
Subject: [PATCH] 银川 1.联调产品维护页面 2.添加IM即时通讯模块
---
src/views/im/manager/rtc/index.vue | 98 +++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 98 insertions(+), 0 deletions(-)
diff --git a/src/views/im/manager/rtc/index.vue b/src/views/im/manager/rtc/index.vue
new file mode 100644
index 0000000..8a0cdfb
--- /dev/null
+++ b/src/views/im/manager/rtc/index.vue
@@ -0,0 +1,98 @@
+<script lang="ts" setup>
+import type { VxeTableGridOptions } from '#/adapter/vxe-table';
+import type { ImManagerRtcApi } from '#/api/im/manager/rtc';
+
+import { ref } from 'vue';
+
+import { Page } from '#/packages/effects/common-ui/src';
+import { DICT_TYPE } from '#/packages/constants/src';
+
+import { ACTION_ICON, TableAction, useVbenVxeGrid } from '#/adapter/vxe-table';
+import { getManagerRtcCallPage } from '#/api/im/manager/rtc';
+import { DictTag } from '#/components/dict-tag';
+import {
+ formatGroupLabel,
+ formatUserLabel,
+} from '#/views/im/manager/utils/format';
+import { resolveCallDuration } from '#/views/im/utils/time';
+
+import { useRtcGridColumns, useRtcGridFormSchema } from './data';
+import Detail from './modules/detail.vue';
+
+defineOptions({ name: 'ImManagerRtcCall' });
+
+const detailRef = ref<InstanceType<typeof Detail>>();
+
+/** 鎵撳紑璇︽儏 */
+function handleDetail(row: ImManagerRtcApi.RtcCall) {
+ detailRef.value?.open(row);
+}
+
+const [Grid] = useVbenVxeGrid({
+ formOptions: {
+ schema: useRtcGridFormSchema(),
+ },
+ gridOptions: {
+ columns: useRtcGridColumns(),
+ height: 'auto',
+ keepSource: true,
+ proxyConfig: {
+ ajax: {
+ query: async ({ page }, formValues) => {
+ return await getManagerRtcCallPage({
+ pageNo: page.currentPage,
+ pageSize: page.pageSize,
+ ...formValues,
+ });
+ },
+ },
+ },
+ rowConfig: {
+ keyField: 'id',
+ isHover: true,
+ },
+ toolbarConfig: {
+ refresh: true,
+ search: true,
+ },
+ } as VxeTableGridOptions<ImManagerRtcApi.RtcCall>,
+});
+</script>
+
+<template>
+ <Page auto-content-height>
+ <Detail ref="detailRef" />
+ <Grid table-title="閫氳瘽璁板綍鍒楄〃">
+ <template #inviter="{ row }">
+ {{ formatUserLabel(row.inviterNickname, row.inviterUserId) }}
+ </template>
+ <template #group="{ row }">
+ {{ formatGroupLabel(row.groupName, row.groupId) }}
+ </template>
+ <template #endReason="{ row }">
+ <DictTag
+ v-if="row.endReason"
+ :type="DICT_TYPE.IM_RTC_CALL_END_REASON"
+ :value="row.endReason"
+ />
+ <span v-else>-</span>
+ </template>
+ <template #duration="{ row }">
+ {{ resolveCallDuration(row.acceptTime, row.endTime) }}
+ </template>
+ <template #actions="{ row }">
+ <TableAction
+ :actions="[
+ {
+ label: '璇︽儏',
+ type: 'link',
+ icon: ACTION_ICON.VIEW,
+ auth: ['im:manager:rtc:query'],
+ onClick: handleDetail.bind(null, row),
+ },
+ ]"
+ />
+ </template>
+ </Grid>
+ </Page>
+</template>
--
Gitblit v1.9.3