修改页数
This commit is contained in:
@@ -124,9 +124,9 @@
|
||||
</template>
|
||||
|
||||
<template #action-area>
|
||||
<ElButton type="primary" @click="showWorkcaseDetail = true">
|
||||
<ElButton type="primary" @click="handleWorkcaseAction">
|
||||
<FileText :size="16" />
|
||||
查看工单
|
||||
{{ currentWorkcaseId ? '查看工单' : '创建工单' }}
|
||||
</ElButton>
|
||||
</template>
|
||||
</ChatRoom>
|
||||
@@ -154,6 +154,17 @@
|
||||
>
|
||||
<WorkcaseDetail :workcase-id="currentWorkcaseId" />
|
||||
</ElDialog>
|
||||
|
||||
<!-- 工单创建对话框 -->
|
||||
<ElDialog
|
||||
v-model="showWorkcaseCreator"
|
||||
title="创建工单"
|
||||
width="800px"
|
||||
class="workcase-dialog"
|
||||
>
|
||||
<!-- TODO: 添加工单创建组件 -->
|
||||
<div>工单创建表单</div>
|
||||
</ElDialog>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
@@ -205,7 +216,7 @@ const loadingMore = ref(false)
|
||||
const autoFilling = ref(false)
|
||||
|
||||
// 分页状态
|
||||
const PAGE_SIZE = 5
|
||||
const PAGE_SIZE = 20
|
||||
const currentPage = ref(1)
|
||||
const hasMore = ref(true)
|
||||
|
||||
@@ -239,6 +250,8 @@ const messages = ref<ChatRoomMessageVO[]>([])
|
||||
|
||||
// 工单详情对话框
|
||||
const showWorkcaseDetail = ref(false)
|
||||
// 工单创建对话框
|
||||
const showWorkcaseCreator = ref(false)
|
||||
|
||||
// Jitsi Meet会议相关
|
||||
const currentMeetingUrl = ref('')
|
||||
@@ -480,6 +493,27 @@ const downloadFile = (fileId: string) => {
|
||||
window.open(`${FILE_DOWNLOAD_URL}/${fileId}`, '_blank')
|
||||
}
|
||||
|
||||
// 处理工单操作(创建或查看)
|
||||
const handleWorkcaseAction = () => {
|
||||
if (currentWorkcaseId.value) {
|
||||
// 已有工单,查看详情
|
||||
showWorkcaseDetail.value = true
|
||||
} else {
|
||||
// 无工单,创建新工单
|
||||
showWorkcaseCreator.value = true
|
||||
}
|
||||
}
|
||||
|
||||
// 工单创建成功
|
||||
const onWorkcaseCreated = (workcaseId: string) => {
|
||||
showWorkcaseCreator.value = false
|
||||
// 更新当前聊天室的工单ID
|
||||
if (currentRoom.value) {
|
||||
currentRoom.value.workcaseId = workcaseId
|
||||
}
|
||||
ElMessage.success('工单创建成功')
|
||||
}
|
||||
|
||||
// 发起会议
|
||||
const startMeeting = async () => {
|
||||
if (!currentRoomId.value) return
|
||||
|
||||
Reference in New Issue
Block a user