|
77 | 77 | :close-on-click-modal="false" |
78 | 78 | :close-on-press-escape="false" |
79 | 79 | > |
| 80 | + <template #header="{ titleId, titleClass }"> |
| 81 | + <div class="flex-between"> |
| 82 | + <span class="medium ellipsis" :title="dialogTitle" :id="titleId" :class="titleClass"> |
| 83 | + {{ dialogTitle }} |
| 84 | + </span> |
| 85 | + <div class="flex align-center mr-8"> |
| 86 | + <span v-if="dialogType === 'pdfDocument'" class="mr-4"> |
| 87 | + <el-button text> |
| 88 | + <el-icon> <Download /> </el-icon> |
| 89 | + </el-button> |
| 90 | + </span> |
| 91 | + <span v-if="dialogType === 'pdfDocument'"> |
| 92 | + <el-button text> <app-icon iconName="app-export" size="20" /></el-button> |
| 93 | + </span> |
| 94 | + <el-divider direction="vertical" /> |
| 95 | + </div> |
| 96 | + </div> |
| 97 | + </template> |
80 | 98 | <div class="mb-8"> |
81 | 99 | <component :is="currentComponent" :detail="currentChatDetail" :type="type"></component> |
82 | 100 | </div> |
@@ -119,6 +137,7 @@ const dialogVisible = ref(false) |
119 | 137 | const dialogTitle = ref('') |
120 | 138 | const currentComponent = shallowRef<any>(null) |
121 | 139 | const currentChatDetail = ref<any>(null) |
| 140 | +const dialogType = ref('') |
122 | 141 | function openParagraph(row: any, id?: string) { |
123 | 142 | dialogTitle.value = t('chat.KnowledgeSource.title') |
124 | 143 | const obj = cloneDeep(row) |
@@ -149,7 +168,7 @@ function openParagraphDocument(row: any) { |
149 | 168 | emit('openParagraphDocument', row) |
150 | 169 | return |
151 | 170 | } |
152 | | -
|
| 171 | + dialogType.value = 'pdfDocument' |
153 | 172 | currentComponent.value = ParagraphDocumentContent |
154 | 173 | dialogTitle.value = row.document_name |
155 | 174 | currentChatDetail.value = row |
|
0 commit comments