refactor(content-style): 将"批量分析"统一重命名为"风格提取"
Some checks failed
Build and Deploy / deploy (push) Has been cancelled
Some checks failed
Build and Deploy / deploy (push) Has been cancelled
- 修改 BatchAnalyzeModal 中的成功提示文本 - 更新 BenchmarkTable 中的按钮文本 - 调整 useBenchmarkAnalysis 中的加载提示和错误信息 - 移除 BenchmarkTaskList 中已不再使用的提示词查看和复制功能
This commit is contained in:
@@ -83,7 +83,7 @@ async function generateBatchPrompt() {
|
|||||||
batchPrompt.value = fullText
|
batchPrompt.value = fullText
|
||||||
}
|
}
|
||||||
console.log('[BatchAnalyzeModal] onComplete - batchPrompt.value length:', batchPrompt.value?.length)
|
console.log('[BatchAnalyzeModal] onComplete - batchPrompt.value length:', batchPrompt.value?.length)
|
||||||
toast.success(`批量分析完成:已基于 ${props.textCount} 个视频的文案生成综合提示词`)
|
toast.success(`风格分析完成:已基于 ${props.textCount} 个视频的文案生成综合提示词`)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ function formatNumber(value) {
|
|||||||
icon="download"
|
icon="download"
|
||||||
/>
|
/>
|
||||||
<GradientButton
|
<GradientButton
|
||||||
:text="`批量分析 (${selectedRowKeys.length}/20)`"
|
:text="`风格提取 (${selectedRowKeys.length}/20)`"
|
||||||
size="small"
|
size="small"
|
||||||
@click="$emit('createAsyncTask')"
|
@click="$emit('createAsyncTask')"
|
||||||
:disabled="data.length === 0 || selectedRowKeys.length === 0 || selectedRowKeys.length > 20"
|
:disabled="data.length === 0 || selectedRowKeys.length === 0 || selectedRowKeys.length > 20"
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ export function useBenchmarkAnalysis(data, expandedRowKeys, saveTableDataToSessi
|
|||||||
|
|
||||||
batchAnalyzeLoading.value = true
|
batchAnalyzeLoading.value = true
|
||||||
globalLoading.value = true
|
globalLoading.value = true
|
||||||
globalLoadingText.value = `正在批量分析 ${selectedRowKeys.value.length} 个视频...`
|
globalLoadingText.value = `正在风格提取 ${selectedRowKeys.value.length} 个视频...`
|
||||||
|
|
||||||
try {
|
try {
|
||||||
globalLoadingText.value = '正在获取中...'
|
globalLoadingText.value = '正在获取中...'
|
||||||
@@ -118,8 +118,8 @@ export function useBenchmarkAnalysis(data, expandedRowKeys, saveTableDataToSessi
|
|||||||
await onBatchComplete(mergedText, allTexts.length)
|
await onBatchComplete(mergedText, allTexts.length)
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('批量分析失败:', error)
|
console.error('风格提取失败:', error)
|
||||||
toast.error('批量分析失败,请稍后重试')
|
toast.error('风格提取失败,请稍后重试')
|
||||||
} finally {
|
} finally {
|
||||||
batchAnalyzeLoading.value = false
|
batchAnalyzeLoading.value = false
|
||||||
globalLoading.value = false
|
globalLoading.value = false
|
||||||
|
|||||||
@@ -63,24 +63,6 @@
|
|||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell>
|
<TableCell>
|
||||||
<div class="flex gap-1">
|
<div class="flex gap-1">
|
||||||
<Button
|
|
||||||
v-if="record.status === 2 && record.generatedPrompt"
|
|
||||||
variant="link"
|
|
||||||
size="sm"
|
|
||||||
class="h-auto p-0"
|
|
||||||
@click="handleViewPrompt(record)"
|
|
||||||
>
|
|
||||||
查看
|
|
||||||
</Button>
|
|
||||||
<Button
|
|
||||||
v-if="record.status === 2 && record.generatedPrompt"
|
|
||||||
variant="link"
|
|
||||||
size="sm"
|
|
||||||
class="h-auto p-0"
|
|
||||||
@click="handleCopyPrompt(record)"
|
|
||||||
>
|
|
||||||
复制
|
|
||||||
</Button>
|
|
||||||
<AlertDialog v-if="record.status !== 1">
|
<AlertDialog v-if="record.status !== 1">
|
||||||
<AlertDialogTrigger as-child>
|
<AlertDialogTrigger as-child>
|
||||||
<Button variant="link" size="sm" class="h-auto p-0 text-destructive">
|
<Button variant="link" size="sm" class="h-auto p-0 text-destructive">
|
||||||
@@ -112,24 +94,6 @@
|
|||||||
</Table>
|
</Table>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<!-- 弹窗 -->
|
|
||||||
<template #modals>
|
|
||||||
<!-- 提示词弹窗 -->
|
|
||||||
<Dialog v-model:open="promptModalVisible">
|
|
||||||
<DialogContent class="sm:max-w-[700px]">
|
|
||||||
<DialogHeader>
|
|
||||||
<DialogTitle>生成的提示词</DialogTitle>
|
|
||||||
</DialogHeader>
|
|
||||||
<div class="prompt-content">{{ currentPrompt }}</div>
|
|
||||||
<DialogFooter>
|
|
||||||
<Button @click="handleCopyCurrentPrompt">
|
|
||||||
<Icon icon="lucide:copy" class="size-4" />
|
|
||||||
复制到剪贴板
|
|
||||||
</Button>
|
|
||||||
</DialogFooter>
|
|
||||||
</DialogContent>
|
|
||||||
</Dialog>
|
|
||||||
</template>
|
|
||||||
</TaskPageLayout>
|
</TaskPageLayout>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user