Browse Source

fix--二级首页大屏修改

master
buaixuexideshitongxue 1 month ago
parent
commit
6a98e7b5a2
  1. 8
      src/api/screen/subScreen/subOneGlobal.ts
  2. 19
      src/views/datav/subonedatav/SubOneGlobal.vue

8
src/api/screen/subScreen/subOneGlobal.ts

@ -28,9 +28,11 @@ export function getSubOneAllCount(body) {
}); });
} }
export function getSubOneGlobalMap(departId, times) {
return request.get({ export function getSubOneGlobalMap(body) {
url: `/datav/sub1/getSubOneGlobalMap?departId=${departId}&beginTime=${times[0]}&endTime=${times[1]}` return request.post({
url: `/datav/sub1/getSubOneGlobalMap`,
body
}); });
} }

19
src/views/datav/subonedatav/SubOneGlobal.vue

@ -442,7 +442,7 @@ const getMapJSON = async (departId = currentDepartId) => {
echarts.registerMap("changsha", res); echarts.registerMap("changsha", res);
subOneGlobalMap.value.chart.setOption(option.value); subOneGlobalMap.value.chart.setOption(option.value);
} }
const getOrganizationProRankData = async (departId = currentDepartId, timeValue = time.value) => { const getOrganizationProRankData = async () => {
const body={ const body={
departId: currentDepartId, departId: currentDepartId,
beginTime: time.value[0], beginTime: time.value[0],
@ -456,7 +456,7 @@ const getBusinessRateData = async (departId = currentDepartId, timeValue = time.
const res = await getSubOneBusinessRate(departId, timeValue); const res = await getSubOneBusinessRate(departId, timeValue);
ywlxPieOption.value.series[0].data = res.ywzblist; ywlxPieOption.value.series[0].data = res.ywzblist;
} }
const getAllGlobalCountData = async (departId = currentDepartId, timeValue = time.value) => { const getAllGlobalCountData = async () => {
const body={ const body={
departId: currentDepartId, departId: currentDepartId,
beginTime: time.value[0], beginTime: time.value[0],
@ -465,8 +465,13 @@ const getAllGlobalCountData = async (departId = currentDepartId, timeValue = tim
const res = await getSubOneAllCount(body); const res = await getSubOneAllCount(body);
overviewData.value = res.overview; overviewData.value = res.overview;
} }
const getSubOneGlobalMapIcon = async (departId = currentDepartId, timeValue = time.value) => { const getSubOneGlobalMapIcon = async () => {
const res = await getSubOneGlobalMap(departId, timeValue) const body={
departId: currentDepartId,
beginTime: time.value[0],
endTime: time.value[1]
}
const res = await getSubOneGlobalMap(body)
const mappedData = res.globalTempMapVoList.map(item => { const mappedData = res.globalTempMapVoList.map(item => {
return { return {
...item, ...item,
@ -509,10 +514,10 @@ const getData = () => {
console.log(userStore) console.log(userStore)
} }
console.log('currentDepartId',currentDepartId) console.log('currentDepartId',currentDepartId)
getOrganizationProRankData(currentDepartId, time.value); getOrganizationProRankData();
getBusinessRateData(currentDepartId, time.value); getBusinessRateData(currentDepartId, time.value);
getAllGlobalCountData(currentDepartId, time.value); getAllGlobalCountData();
getSubOneGlobalMapIcon(currentDepartId, time.value); getSubOneGlobalMapIcon();
getSubOneGlobalTrendData(currentDepartId, selectedYear.value); getSubOneGlobalTrendData(currentDepartId, selectedYear.value);
getSubOneStrongProblemRateData(currentDepartId, time.value); getSubOneStrongProblemRateData(currentDepartId, time.value);
getSubOneProblemBusinessRateData(currentDepartId, time.value); getSubOneProblemBusinessRateData(currentDepartId, time.value);

Loading…
Cancel
Save