| | |
| | | countZhPipeMapLength, |
| | | countLargeCategories, |
| | | countProjectType, |
| | | countProjectDown |
| | | countProjectDown, |
| | | countProjectTypeNumber, |
| | | countStorageByProject, |
| | | } from "@/api/screen.js" |
| | | export default { |
| | | props: { |
| | |
| | | option() { |
| | | let xAxis = [] |
| | | let yAxis = [] |
| | | |
| | | this.dataList.forEach(item => { |
| | | xAxis.push(item.type) |
| | | yAxis.push(item.count) |
| | | }) |
| | | const proObj = this.dataList.find(item => item.项目名称 == this.project) |
| | | if (proObj) { |
| | | Object.keys(proObj).forEach(item => { |
| | | if (item.toString() != '项目名称') { |
| | | xAxis.push(item) |
| | | yAxis.push(proObj[item]) |
| | | } |
| | | }) |
| | | } else { |
| | | this.dataList.forEach(item => { |
| | | let type = item.type || item.projtype |
| | | xAxis.push(type) |
| | | yAxis.push(item.count) |
| | | }) |
| | | } |
| | | |
| | | // let data = [220, 182, 191, 234, 290, 330, 310] |
| | | // const sideData = data.map(item => { |
| | |
| | | let requsetFn = null |
| | | switch (newVal) { |
| | | case "全球项目": |
| | | requsetFn = countLargeCategories |
| | | requsetFn = countProjectTypeNumber |
| | | break |
| | | case "全国项目": |
| | | requsetFn = countLargeCategories |
| | | requsetFn = countProjectTypeNumber |
| | | break |
| | | case "全球管网图": |
| | | requsetFn = countZhPipeMapLength |
| | |
| | | requsetFn = countZhPipeMapLength |
| | | break |
| | | default: |
| | | requsetFn = GetServicesVisitsCount |
| | | requsetFn = countStorageByProject |
| | | |
| | | break |
| | | } |