refactor(crm): 移除潜客管理页冗余微统计与雷达胶囊条,将85%+全屏空间留给客户工作台
这个提交包含在:
@@ -27,60 +27,7 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- Row 2: Micro Metrics Bar (Compact Single-Row Funnel, 36px Height, Direct Filter on Click) -->
|
||||
<view class="micro-stats-bar">
|
||||
<view
|
||||
class="micro-stat-item"
|
||||
:class="{ 'micro-stat-active': state.status === '' }"
|
||||
@click="selectStatus('')"
|
||||
>
|
||||
<text class="micro-stat-num text-brand">{{ statsTotal }}</text>
|
||||
<text class="micro-stat-label">{{ t('statTotal') }}</text>
|
||||
</view>
|
||||
<view class="micro-stat-divider"></view>
|
||||
<view
|
||||
class="micro-stat-item"
|
||||
:class="{ 'micro-stat-active': state.status === 'hot' }"
|
||||
@click="selectStatus('hot')"
|
||||
>
|
||||
<view class="micro-stat-num-row">
|
||||
<view class="micro-hot-dot"></view>
|
||||
<text class="micro-stat-num text-hot">{{ statsHot }}</text>
|
||||
</view>
|
||||
<text class="micro-stat-label">{{ t('statHot') }}</text>
|
||||
</view>
|
||||
<view class="micro-stat-divider"></view>
|
||||
<view
|
||||
class="micro-stat-item"
|
||||
:class="{ 'micro-stat-active': state.status === 'new' }"
|
||||
@click="selectStatus('new')"
|
||||
>
|
||||
<text class="micro-stat-num">{{ statsNew }}</text>
|
||||
<text class="micro-stat-label">{{ t('statNew') }}</text>
|
||||
</view>
|
||||
<view class="micro-stat-divider"></view>
|
||||
<view
|
||||
class="micro-stat-item"
|
||||
:class="{ 'micro-stat-active': state.status === 'won' }"
|
||||
@click="selectStatus('won')"
|
||||
>
|
||||
<text class="micro-stat-num text-won">{{ statsWon }}</text>
|
||||
<text class="micro-stat-label">{{ t('statWon') }}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- Row 3: Single-Line Live Radar Capsule (Collapsible, Auto-Hidden when Empty, 28px Height) -->
|
||||
<view v-if="hasRadarAlert" class="radar-capsule-bar" @click="openRadar">
|
||||
<view class="radar-capsule-left">
|
||||
<view class="radar-pulse-dot"></view>
|
||||
<text class="radar-capsule-text">{{ radarLineOne }}</text>
|
||||
</view>
|
||||
<view class="radar-capsule-right">
|
||||
<text class="radar-capsule-link">{{ radarMoreLabel }}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- Row 4: Integrated Quick Search & Primary Action -->
|
||||
<!-- Row 2: Integrated Quick Search & Primary Action -->
|
||||
<view class="search-row">
|
||||
<view class="search-input-wrap">
|
||||
<input
|
||||
@@ -297,54 +244,6 @@ const leadsCountSummary = computed((): string => {
|
||||
return `${count}`;
|
||||
});
|
||||
|
||||
const statsTotal = computed((): number => {
|
||||
return state.total > 0 ? state.total : state.list.length;
|
||||
});
|
||||
|
||||
const statsHot = computed((): number => {
|
||||
let count = 0;
|
||||
for (let i = 0; i < state.list.length; i++) {
|
||||
const item = state.list[i];
|
||||
if (item.status === 'hot' || item.intentScore >= 80) {
|
||||
count++;
|
||||
}
|
||||
}
|
||||
return count;
|
||||
});
|
||||
|
||||
const statsNew = computed((): number => {
|
||||
let count = 0;
|
||||
for (let i = 0; i < state.list.length; i++) {
|
||||
const item = state.list[i];
|
||||
if (item.status === 'new') {
|
||||
count++;
|
||||
}
|
||||
}
|
||||
return count;
|
||||
});
|
||||
|
||||
const statsWon = computed((): number => {
|
||||
let count = 0;
|
||||
for (let i = 0; i < state.list.length; i++) {
|
||||
const item = state.list[i];
|
||||
if (item.status === 'won') {
|
||||
count++;
|
||||
}
|
||||
}
|
||||
return count;
|
||||
});
|
||||
|
||||
const radarLineOne = computed((): string => {
|
||||
if (state.radarTracks.length < 1) {
|
||||
return '';
|
||||
}
|
||||
return formatRadarLine(state.radarTracks[0]);
|
||||
});
|
||||
|
||||
const hasRadarAlert = computed((): boolean => {
|
||||
return radarLineOne.value !== '';
|
||||
});
|
||||
|
||||
const pageRtlClass = computed((): string => {
|
||||
return isRtl(getCurrentLocale()) ? 'leads-rtl' : '';
|
||||
});
|
||||
@@ -598,143 +497,7 @@ onShow(() => {
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
/* Row 2: Micro Metrics Bar (Compact High-Information Bar) */
|
||||
.micro-stats-bar {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
background-color: var(--oc-surface, #F7F8FA);
|
||||
border: 1px solid var(--oc-border, #E3E7ED);
|
||||
border-radius: 12px;
|
||||
padding: 6px 12px;
|
||||
margin-block-end: var(--oc-space-8, 8px);
|
||||
}
|
||||
|
||||
.micro-stat-item {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding-block: 2px;
|
||||
border-radius: 8px;
|
||||
transition: background-color 150ms cubic-bezier(0.2, 0.8, 0.2, 1);
|
||||
}
|
||||
|
||||
.micro-stat-item:active {
|
||||
background-color: #EBF5FF;
|
||||
}
|
||||
|
||||
.micro-stat-active {
|
||||
background-color: #EBF5FF;
|
||||
}
|
||||
|
||||
.micro-stat-num-row {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.micro-hot-dot {
|
||||
width: 5px;
|
||||
height: 5px;
|
||||
border-radius: 3px;
|
||||
background-color: var(--oc-error, #F04438);
|
||||
margin-inline-end: 4px;
|
||||
}
|
||||
|
||||
.micro-stat-num {
|
||||
font-size: 15px;
|
||||
font-weight: 800;
|
||||
color: var(--oc-text, #101828);
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.text-brand {
|
||||
color: var(--oc-primary, #0B5CFF);
|
||||
}
|
||||
|
||||
.text-hot {
|
||||
color: var(--oc-error, #F04438);
|
||||
}
|
||||
|
||||
.text-won {
|
||||
color: var(--oc-success, #12B76A);
|
||||
}
|
||||
|
||||
.micro-stat-label {
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
color: var(--oc-text-2, #667085);
|
||||
margin-block-start: 1px;
|
||||
}
|
||||
|
||||
.micro-stat-divider {
|
||||
width: 1px;
|
||||
height: 20px;
|
||||
background-color: var(--oc-border, #E3E7ED);
|
||||
}
|
||||
|
||||
/* Row 3: Radar Alert Capsule */
|
||||
.radar-capsule-bar {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
height: 28px;
|
||||
padding-inline: 10px;
|
||||
background-color: #F5F9FF;
|
||||
border: 1px solid #D1E4FF;
|
||||
border-radius: 8px;
|
||||
margin-block-end: var(--oc-space-8, 8px);
|
||||
transition: opacity 150ms cubic-bezier(0.2, 0.8, 0.2, 1);
|
||||
}
|
||||
|
||||
.radar-capsule-bar:active {
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
.radar-capsule-left {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.radar-pulse-dot {
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
border-radius: 3px;
|
||||
background-color: var(--oc-primary, #0B5CFF);
|
||||
margin-inline-end: 6px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.radar-capsule-text {
|
||||
font-size: 11px;
|
||||
color: var(--oc-text, #101828);
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.radar-capsule-right {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-inline-start: 8px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.radar-capsule-link {
|
||||
font-size: 11px;
|
||||
color: var(--oc-primary, #0B5CFF);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* Row 4: Search Input & Primary CTA Integrated */
|
||||
/* Row 2: Search Input & Primary CTA Integrated */
|
||||
.search-row {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
||||
在新工单中引用
屏蔽一个用户