hejianhao
2025-03-24 31e3901ef4c11bbb10d3dfe306533617b5ccdb61
天气、各季度应补偿总额
17个文件已删除
7个文件已修改
311 ■■■■■ 已修改文件
.gitignore 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
README.md 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
public/favicon.ico 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/android-chrome-192x192.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/android-chrome-512x512.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/android-chrome-maskable-192x192.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/android-chrome-maskable-512x512.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon-120x120.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon-152x152.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon-180x180.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon-60x60.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon-76x76.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/apple-touch-icon.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/favicon-16x16.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/favicon-32x32.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/msapplication-icon-144x144.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/mstile-150x150.png 补丁 | 查看 | 原始文档 | blame | 历史
public/img/icons/safari-pinned-tab.svg 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
public/index.html 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
public/robots.txt 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/datascreen/HeaderPanel.vue 30 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/datascreen/RightPanel.vue 170 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/datascreen/map.vue 93 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/DataScreen.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
.gitignore
@@ -1,6 +1,7 @@
.DS_Store
node_modules
/dist
package-lock.json
# local env files
README.md
@@ -1,4 +1,4 @@
# chongzhou-screen
# 崇州市自主安置购房信息化大数据平台
## Project setup
```
public/favicon.ico
Binary files differ
public/img/icons/android-chrome-192x192.png
Binary files differ
public/img/icons/android-chrome-512x512.png
Binary files differ
public/img/icons/android-chrome-maskable-192x192.png
Binary files differ
public/img/icons/android-chrome-maskable-512x512.png
Binary files differ
public/img/icons/apple-touch-icon-120x120.png
Binary files differ
public/img/icons/apple-touch-icon-152x152.png
Binary files differ
public/img/icons/apple-touch-icon-180x180.png
Binary files differ
public/img/icons/apple-touch-icon-60x60.png
Binary files differ
public/img/icons/apple-touch-icon-76x76.png
Binary files differ
public/img/icons/apple-touch-icon.png
Binary files differ
public/img/icons/favicon-16x16.png
Binary files differ
public/img/icons/favicon-32x32.png
Binary files differ
public/img/icons/msapplication-icon-144x144.png
Binary files differ
public/img/icons/mstile-150x150.png
Binary files differ
public/img/icons/safari-pinned-tab.svg
File was deleted
public/index.html
@@ -4,7 +4,7 @@
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <!-- <link rel="icon" href="<%= BASE_URL %>favicon.ico"> -->
    <link rel="icon" href="<%= BASE_URL %>favicon.ico">
    <title><%= htmlWebpackPlugin.options.title %></title>
  </head>
  <body>
public/robots.txt
File was deleted
src/components/datascreen/HeaderPanel.vue
@@ -2,8 +2,10 @@
  <div class="header">
    <!-- 左侧天气 -->
    <div class="weather">
      <!-- <img :src="require(`@/assets/weather/${weatherInfo.icon}.png`)" alt="weather" class="weather-icon"> -->
      <span class="weather-text">{{ weatherInfo.text }}</span>
      <div class="mask"></div>
      <div class="box"></div>
      <iframe allowtransparency="true" frameborder="0" width="180" height="36" scrolling="no"
        src="//tianqi.2345.com/plugin/widget/index.htm?s=3&z=3&t=1&v=0&d=3&bd=0&k=000000&f=ffffff&ltf=ffffff&htf=ffffff&q=1&e=1&a=1&c=60910&w=103&h=36&align=left" />
    </div>
    
    <!-- 中间标题 -->
@@ -75,15 +77,24 @@
    display: flex;
    margin-top: 61px;
    
    .weather-icon {
      width: 30px;
      height: 30px;
      margin-right: 10px;
    .mask {
      position: absolute;
      width: 180px;
      height: 36px;
      z-index: 1;
      filter: alpha(opacity=0);
      opacity: 0;
      background: #040A56
    }
    .weather-text {
      color: #fff;
      font-size: 16px;
    .box {
      position: absolute;
      width: 20px;
      height: 36px;
      left: 140px;
      z-index: 1;
      background: #040A56
    }
  }
@@ -100,6 +111,7 @@
  .datetime {
    display: flex;
    margin-top: 61px;
    .calendar-icon {
      width: 22px;
      height: 21px;
src/components/datascreen/RightPanel.vue
@@ -18,9 +18,9 @@
    <!-- 右侧第三块 -->
    <div class="panel-item bottom-panel-item">
      <div class="box-title">安置房类型分布</div>
      <div class="box-title">各季度应补偿总额</div>
      <div class="pie-chart">
        <!-- <v-chart class="chart" :option="typeDistOption" autoresize /> -->
        <v-chart class="chart" :option="barOption" autoresize />
      </div>
    </div>
  </div>
@@ -29,6 +29,12 @@
<script>
export default {
  name: 'RightPanel',
  props: {
    data: {
      type: Object,
      default: () => { }
    }
  },
  data() {
    return {
      circleOption: {
@@ -56,46 +62,7 @@
          ]
        }]
      },
      barOption: {
        tooltip: {
          trigger: 'axis'
        },
        xAxis: {
          type: 'category',
          data: ['2023年4月', '2023年5月', '2023年7月', '2023年10月'],
          axisLine: {
            lineStyle: {
              color: '#7cb9e8'
            }
          },
          axisLabel: {
            color: '#7cb9e8'
          }
        },
        yAxis: {
          type: 'value',
          axisLine: {
            lineStyle: {
              color: '#7cb9e8'
            }
          },
          axisLabel: {
            color: '#7cb9e8'
          },
          splitLine: {
            lineStyle: {
              color: 'rgba(124,185,232,0.1)'
            }
          }
        },
        series: [{
          data: [120, 200, 150, 80],
          type: 'bar',
          itemStyle: {
            color: '#00ffff'
          }
        }]
      },
      barOption: {},
      typeDistOption: {
        tooltip: {
          trigger: 'item'
@@ -120,6 +87,119 @@
        }]
      }
    };
  },
  mounted() {
    // 组件挂载后初始化地图
    this.$nextTick(() => {
      this.initBarChart();
    });
  },
  methods: {
    initBarChart() {
      if (!this.data.quarterPayResponses || !this.data.quarterPayResponses[0]) return;
      const sortedData = Object.entries(this.data.quarterPayResponses[0])
        .sort((a, b) => {
          const dateA = new Date(a[0].replace('-', '/'));
          const dateB = new Date(b[0].replace('-', '/'));
          return dateA - dateB;
        });
      const maxValue = Math.max(...sortedData.map(item => item[1]));
      const yAxisMax = Math.ceil(maxValue / 100) * 100;
      this.barOption = {
        tooltip: {
          trigger: 'axis',
          formatter: function (params) {
            const dataParams = params[1];
            return `${dataParams.name}<br/>数值:${dataParams.value}`;
          },
          backgroundColor: 'rgba(0,0,0,0.7)',
          borderColor: '#00ffff',
          borderWidth: 1,
          textStyle: {
            color: '#fff',
            fontSize: 14
          }
        },
        grid: {
          top: '10%',
          left: '3%',
          right: '4%',
          bottom: '3%',
          containLabel: true
        },
        xAxis: {
          type: 'category',
          data: sortedData.map(item => item[0]),
          axisTick: {
            show: false  // 隐藏刻度线
          },
          axisLine: {
            lineStyle: {
              color: 'rgba(30, 44, 88, 1)'
            }
          },
          axisLabel: {
            color: '#ffffff',
            fontSize: 12
          }
        },
        yAxis: {
          type: 'value',
          max: yAxisMax,
          splitNumber: 4,
          axisLabel: {
            color: 'rgba(88, 115, 150, 1)',
            fontSize: 12
          },
          splitLine: {
            lineStyle: {
              color: 'rgba(30, 44, 88, 1)'
            }
          }
        },
        series: [
          {
            type: 'bar',
            barWidth: '30%',
            z: 1,
            data: Array(sortedData.length).fill(yAxisMax),
            itemStyle: {
              color: 'rgba(0, 255, 255, 0.1)'
            }
          },
          {
            type: 'pictorialBar',
            symbol: 'roundRect',
            symbolSize: [20, 6],
            symbolRepeat: 'fixed',
            symbolMargin: 1,
            symbolClip: true,
            symbolPosition: 'start',
            symbolOffset: [0, 0],
            symbolBoundingData: yAxisMax,
            z: 2,
            data: sortedData.map(item => item[1]),
            itemStyle: {
              color: function (params) {
                return params.dataIndex === 0 ? '#ffd700' : '#00ffff';
              }
            }
          }
        ]
      };
    }
  },
  watch: {
    data: {
      handler() {
        this.initBarChart();
      },
      deep: true
    }
  }
};
</script>
@@ -166,7 +246,11 @@
  .chart {
    width: 100%;
    height: calc(100% - 35px);
    height: 100%;
  }
}
.pie-chart {
  height: calc(100% - 35px);
}
</style> 
src/components/datascreen/map.vue
@@ -274,67 +274,66 @@
        // 生成标记点系列的配置
        getMarkerSeries(type) {
            return {
                name: type === "blue" ? "蓝色标记" : "橙色标记",  // 系列名称
                type: "scatter",         // 散点图类型
                coordinateSystem: "geo", // 使用地理坐标系
                geoIndex: 0,            // 关联第一个geo组件
                data: this.mapPoints.filter(point => point.type === type), // 筛选对应类型的数据
                symbol: `image://${type === "blue" ? tooltipBlue : tooltipOrange}`, // 标记图标
                symbolSize: [20, 30],    // 标记大小
                symbolOffset: [0, -15],  // 标记偏移量
                z: 20,                   // 层级
                name: type === "blue" ? "蓝色标记" : "橙色标记",
                type: "scatter",
                coordinateSystem: "geo",
                geoIndex: 0,
                data: this.mapPoints.filter(point => point.type === type),
                symbol: `image://${type === "blue" ? tooltipBlue : tooltipOrange}`,
                symbolSize: MAP_CONSTANTS.MARKER.SIZE,
                symbolOffset: MAP_CONSTANTS.MARKER.OFFSET,
                z: MAP_CONSTANTS.MARKER.Z_INDEX,
                // 提示框配置
                label: {
                    show: false  // 禁用标签显示
                },
                // 修复tooltip配置
                tooltip: {
                    show: true,          // 显示提示框
                    trigger: 'item',     // 触发类型:数据项
                    backgroundColor: 'transparent', // 背景透明
                    borderWidth: 0,      // 无边框
                    padding: [0, 0, 0, 0], // 内边距
                    // 提示框位置
                    show: true,
                    trigger: 'item',
                    backgroundColor: 'transparent',
                    borderWidth: 0,
                    padding: 0,
                    className: 'map-tooltip',
                    position: function (point) {
                        // 固定偏移量
                        return [point[0] - 100, point[1] - 160];
                    },
                    // 提示框内容格式化
                    formatter: function (params) {
                        // 返回自定义HTML结构的提示框内容
                        return `<div style="
                        const { name, data } = params;
                        return `
                            <div style="
                            background: url(${tooltipBg}) no-repeat center center;
                            background-size: 100% 100%;
                            width: 211px;
                            padding-bottom: 24px;
                                padding: 20px 0;
                            display: flex;
                            flex-direction: column;
                            justify-content: center;
                            align-items: center;
                        ">
                            <div style="color: #fff; font-size: 16px; margin: 21px 0;font-weight: bold;">${params.name}</div>
                            <div style="display: flex; justify-content: space-around; width: 100%;">
                                <div style="color: #fff; font-size: 16px; margin-bottom: 16px; font-weight: bold;">${name}</div>
                                <div style="display: flex; justify-content: space-around; width: 100%; padding: 0 20px;">
                                <div style="text-align: center;">
                                    <div style="color: rgba(102, 255, 255, 1); font-size: 20px;margin-bottom: 8px;font-family: 'pangmenzhengdao';">${params.data.householdCount}</div>
                                        <div style="color: #66ffff; font-size: 20px; font-family: 'pangmenzhengdao'; margin-bottom: 8px;">${data.householdCount}</div>
                                    <div style="color: #fff; font-size: 12px;">安置户数(户)</div>
                                </div>
                                <div style="text-align: center;">
                                    <div style="color: rgba(102, 255, 255, 1); font-size: 20px;margin-bottom: 8px;font-family: 'pangmenzhengdao';">${params.data.personCount}</div>
                                        <div style="color: #66ffff; font-size: 20px; font-family: 'pangmenzhengdao'; margin-bottom: 8px;">${data.personCount}</div>
                                    <div style="color: #fff; font-size: 12px;">安置人数(人)</div>
                                </div>
                            </div>
                        </div>`;
                            </div>
                        `;
                    }
                },
                // 标签配置
                label: {
                    show: false         // 不显示标签
                },
                // 高亮效果配置
                emphasis: {
                    scale: true,        // 启用缩放效果
                    scaleSize: 1.2,     // 放大比例
                    scale: true,
                    scaleSize: 1.2,
                    itemStyle: {
                        shadowBlur: 10,  // 阴影模糊大小
                        shadowColor: type === "blue" ? '#00eaff' : '#ff8e3a' // 根据类型设置阴影颜色
                        shadowBlur: 10,
                        shadowColor: type === "blue" ? MAP_CONSTANTS.SHADOW.COLOR : '#ff8e3a'
                    }
                }
            };
@@ -456,14 +455,12 @@
                            disabled: false,   // 启用高亮效果
                            label: {
                                show: true,       // 显示标签
                                textStyle: {      // 标签文字样式
                                    color: "#fff",
                                    fontSize: 10,
                                    fontWeight: "normal",
                                    opacity: 1
                                }
                                color: "#fff",    // 文字颜色
                                fontSize: 10,     // 文字大小
                                fontWeight: "normal", // 文字粗细
                                opacity: 1        // 不透明度
                            },
                            itemStyle: {      // 高亮时的样式
                            itemStyle: {
                                areaColor: {  // 区域填充,保持与正常状态相同的背景
                                    type: 'pattern',
                                    image: mapBg,
@@ -494,12 +491,10 @@
                        // 标签配置
                        label: {
                            show: true,       // 显示标签
                            textStyle: {      // 标签文字样式
                                color: "#fff",
                                fontSize: 10,
                                fontWeight: "normal",
                                opacity: 1
                            }
                            color: "#fff",    // 文字颜色
                            fontSize: 10,     // 文字大小
                            fontWeight: "normal", // 文字粗细
                            opacity: 1        // 不透明度
                        },
                        tooltip: {
src/views/DataScreen.vue
@@ -3,7 +3,7 @@
    <header-panel />
    <left-panel />
    <center-panel v-if="!loading" :data="data" />
    <right-panel />
    <right-panel v-if="!loading" :data="data" />
  </div>
</template>
@@ -35,6 +35,7 @@
    };
  },
  created() {
    this.handleResize();
    getData().then(res => {
      this.data = res.data;
      this.loading = false;
@@ -48,7 +49,10 @@
  },
  methods: {
    handleResize() {
      this.screenStyle.transform = `scale(${window.innerWidth / 1920})`;
      const widthScale = window.innerWidth / 1920;
      const heightScale = window.innerHeight / 1080;
      const scale = Math.min(widthScale, heightScale);
      this.screenStyle.transform = `scale(${scale})`;
    }
  }
};