diff --git a/src/api/server/employeehosts/index.ts b/src/api/server/employeehosts/index.ts index 665ee81..7ac7d8d 100644 --- a/src/api/server/employeehosts/index.ts +++ b/src/api/server/employeehosts/index.ts @@ -36,7 +36,7 @@ export const EmployeeHostsApi = { getEmployeeHostsPageDsec: async (params: any) => { return await request.get({ url: `/server/employee-big-brother/self_complete` }) }, - // 查询爬大哥建联 + // 查询爬主播建联 employeeCompleteBarChart: async (params: number[], days: number) => { return await request.post({ url: `/server/employee-hosts/employeeCompleteBarChart`, diff --git a/src/views/Home/Index.vue b/src/views/Home/Index.vue index ed28caf..6a18a4f 100644 --- a/src/views/Home/Index.vue +++ b/src/views/Home/Index.vue @@ -251,17 +251,17 @@ onMounted(async () => { await getAllApi() await getAllocationList() - //判断菜单有没有主播管理中的管理员权限 + //判断菜单有没有爬大哥管理中的管理员权限 if (wsCache.get('roleRouters').find(item => item.id === 5041)?.children.find(item => item.id === 5042)) { - await fetchAllHostsCount(1) await fetchAllHostsCountDesc(1) + await fetchDailyHostsCountDesc() } - //判断菜单有没有爬大哥管理中的管理员权限 + //判断菜单有没有主播管理中的管理员权限 if (wsCache.get('roleRouters').find(item => item.id === 5019)?.children.find(item => item.id === 5020)) { + await fetchAllHostsCount(1) await fetchDailyHostsCount() - await fetchDailyHostsCountDesc() } }) @@ -280,17 +280,17 @@ onActivated(async () => { } - //判断菜单有没有主播管理中的管理员权限 + //判断菜单有没有爬大哥管理中的管理员权限 if (wsCache.get('roleRouters').find(item => item.id === 5041)?.children.find(item => item.id === 5042)) { - await fetchAllHostsCount(1) await fetchAllHostsCountDesc(1) + await fetchDailyHostsCountDesc() } - //判断菜单有没有爬大哥管理中的管理员权限 + //判断菜单有没有主播管理中的管理员权限 if (wsCache.get('roleRouters').find(item => item.id === 5019)?.children.find(item => item.id === 5020)) { + await fetchAllHostsCount(1) await fetchDailyHostsCount() - await fetchDailyHostsCountDesc() } }) @@ -759,7 +759,7 @@ async function fetchDailyHostsCountDesc() { // 如果柱状图依赖这个值,顺便刷新一次图表数据 } -// ✅ 爬大哥建联率 +// ✅ 爬主播建联率 async function fetchAllHostsCount(val) { // 以“传入的用户 id”为准展示(顺序也按这里来) const ids = allocationUserList.value.map(item => item.value) @@ -774,7 +774,7 @@ async function fetchAllHostsCount(val) { // 渲染 updateEmployeeBarChart(list) } - +// ✅ 爬大哥建联率 async function fetchAllHostsCountDesc(val) { // 以“传入的用户 id”为准展示(顺序也按这里来) const idss = allocationUserList.value.map(item => item.value)