diff --git a/yunkes/src/components/YkStaffDetailModal.vue b/yunkes/src/components/YkStaffDetailModal.vue index 307e2a8..a5b3ec8 100644 --- a/yunkes/src/components/YkStaffDetailModal.vue +++ b/yunkes/src/components/YkStaffDetailModal.vue @@ -24,6 +24,8 @@ const props = defineProps<{ /** fetcher(page, page_size) → Page。宽松 Page:Customer 无 index signature, * 不可直接赋 Page>,故用 any 接纳 Page 等。 */ fetcher: (page: number, page_size: number) => Promise> + /** 弹框顶部汇总说明(对齐云客) */ + summaryText?: string pageSizes?: number[] }>() const emit = defineEmits<{ 'update:modelValue': [boolean] }>() @@ -63,6 +65,8 @@ watch( width="900px" @update:model-value="emit('update:modelValue', $event)" > +
{{ summaryText }}
+ Promise>( async () => ({ items: [], total: 0 }), ) const detailCols = ref([]) +const detailSummary = ref('') const fmtTime = (_r: any, _c: any, v: any): string => typeof v === 'number' && v > 0 ? formatTime(v) : v ? String(v) : '--' @@ -450,6 +451,10 @@ function openWechatCommModal(row: Account, metric: ChatMetric): void { staff_info: staffInfo, staff_wx: staffWx, })) + // 汇总说明(对齐云客) + const metricTitle = METRIC_TITLES[metric] + const statCount = stats.summary?.[metric === 'chat' ? 'chat_count' : metric === 'effective' ? 'effective_count' : metric === 'follow' ? 'follow_count' : metric === 'last_reply' ? 'last_reply_count' : 'no_reply_count'] ?? 0 + detailSummary.value = `${metricTitle}总${statCount}人次,其中重复客户${Math.max(0, statCount - filtered.length)}人次 剩余${filtered.length}条记录:` return { items, total: filtered.length, page, page_size } } detailOpen.value = true @@ -930,6 +935,7 @@ onMounted(() => {