feat: 历史周报+图片预览+照片管理+导入优化+用户合并
新增: - 历史周报: Dashboard/周报详情支持周选择器翻看往周,归档只读 - 图片预览: 全屏大图(移动端+PC端),点击遮罩关闭 - PC端照片管理: 编辑时可上传/删除照片 - 客户导入改为更新模式: 重名自动更新信息,显示操作明细 - 导入跳过原因: 旧周报导入也显示每条跳过原因 优化: - 填报进度权限: 经理只看到自己,支局长/领导看全员 - 客户经理暖灰色hash标签列 - 用户去重合并(4组),数据完整迁移 - CLAUDE.md 更新到最新状态 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -202,7 +202,7 @@ async function handleImport() {
|
||||
try {
|
||||
const res = await api.post('/customers/import', fd, { headers: { 'Content-Type': 'multipart/form-data' } })
|
||||
importResult.value = res.data
|
||||
ElMessage.success(`导入完成:新增 ${res.data.created} 条,跳过 ${res.data.skipped} 条`)
|
||||
ElMessage.success(`导入完成:新增 ${res.data.created} 条,更新 ${res.data.updated || 0} 条`)
|
||||
await loadCustomers()
|
||||
} catch (e: any) { ElMessage.error('导入失败: ' + (e.response?.data?.detail || e.message)) }
|
||||
finally { importLoading.value = false }
|
||||
@@ -384,8 +384,14 @@ async function handleImport() {
|
||||
</el-form>
|
||||
<div v-if="importResult" style="margin-top:12px">
|
||||
<el-alert type="success" :closable="false">
|
||||
新增 {{ importResult.created }} 条,跳过 {{ importResult.skipped }} 条
|
||||
<template v-if="importResult.errors?.length"><br/>错误:{{ importResult.errors.join('; ') }}</template>
|
||||
新增 {{ importResult.created }} 条,更新 {{ importResult.updated || 0 }} 条
|
||||
<template v-if="importResult.reasons?.length">
|
||||
<div style="margin-top:8px;font-size:12px;max-height:200px;overflow-y:auto">
|
||||
<div v-for="(r,i) in importResult.reasons.slice(0,20)" :key="i">• {{ r }}</div>
|
||||
<div v-if="importResult.reasons.length > 20" style="color:var(--c-text-muted)">...还有 {{ importResult.reasons.length - 20 }} 条</div>
|
||||
</div>
|
||||
</template>
|
||||
<template v-if="importResult.errors?.length"><br/>⚠ 错误:{{ importResult.errors.join('; ') }}</template>
|
||||
</el-alert>
|
||||
</div>
|
||||
<template #footer>
|
||||
|
||||
Reference in New Issue
Block a user