feat(导航): 添加双击导航功能并优化数据展示
- 在GroupComparison组件中添加双击部门跳转到经理页面的功能 - 在secondTop组件中添加双击成员跳转到销售页面的功能 - 优化topOne组件中客户迫切问题排行榜的数据格式转换 - 在RankingList组件中增加展示条目并添加排序功能 - 在SalesTimelineWithTaskList组件中替换alert弹窗为自定义模态框 - 优化secondTop组件路由跳转逻辑,避免重复请求
This commit is contained in:
@@ -520,7 +520,6 @@ async function getCustomerTypeRatio(data) {
|
||||
}
|
||||
try {
|
||||
const res = await getCustomerTypeDistribution(params)
|
||||
console.log(1222222,res)
|
||||
customerTypeRatio.value = res.data
|
||||
} catch (error) {
|
||||
console.error("获取客户类型占比失败:", error);
|
||||
@@ -528,11 +527,20 @@ async function getCustomerTypeRatio(data) {
|
||||
}
|
||||
// 客户迫切解决的问题排行榜
|
||||
const customerUrgency = ref({});
|
||||
const problemRankingData = ref([]);
|
||||
|
||||
async function getCustomerUrgency() {
|
||||
try {
|
||||
const res = await getUrgentNeedToAddress()
|
||||
console.log(1222222,res)
|
||||
customerUrgency.value = res.data
|
||||
|
||||
// 将API返回的数据转换为ProblemRanking组件需要的格式
|
||||
if (res.data && res.data.company_urgent_issue_ratio) {
|
||||
problemRankingData.value = Object.entries(res.data.company_urgent_issue_ratio).map(([name, value]) => ({
|
||||
name,
|
||||
value
|
||||
}));
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("获取客户迫切解决的问题排行榜失败:", error);
|
||||
}
|
||||
@@ -542,7 +550,6 @@ const levelTree = ref({});
|
||||
async function CusotomGetLevelTree() {
|
||||
try {
|
||||
const res = await getLevelTree()
|
||||
console.log(1222222,res)
|
||||
levelTree.value = res.data
|
||||
} catch (error) {
|
||||
console.error("获取级别树失败:", error);
|
||||
|
||||
Reference in New Issue
Block a user