提交 baf517e9 authored 作者: 李顺's avatar 李顺

Merge branch 'master' of http://8.140.26.4:10003/caijian/risk-monitor into ls_dev

差异被折叠。
......@@ -147,4 +147,132 @@ export function getSurvyInfo(params) {
url: `/api/marketsearchHome/statSortDetails`,
params
})
}
// 查询调查的所有发布领域 /marketsearchDetails/getSearchAllArea
export function getSearchAllArea(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchAllArea`,
params
})
}
// 查询调查的所有发布时间
export function getSearchAllYear(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchYears`,
params
})
}
// 调查简介 /marketsearchDetails/searchBlurb
export function getSearchBlurb(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/searchBlurb`,
params
})
}
// 获取相关事件getRelatedEvents
export function getRelatedEvents(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getRelatedEvents`,
params
})
}
// 获取事件脉络 getSearchContext
export function getSearchContext(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchContext`,
params
})
}
// getSearchMeasures 报复性措施
export function getSearchMeasures(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchMeasures`,
params
})
}
// /marketsearchDetails/getSearchDirection 查询调查方向和结果信息
export function getSearchDirection(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchDirection`,
params
})
}
// 中国公司受调查情况 /marketsearchDetails/statcnOrgCount
export function getStatcnOrgCount(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/statcnOrgCount`,
params
})
}
// /marketsearchDetails/getSearchConclusion 查询调查结论
export function getSearchConclusion(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSearchConclusion`,
params
})
}
// getReportAnalyze 报告分析
export function getReportAnalyze(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getReportAnalyze`,
params
})
}
// 被诉企业列表
export function getSuedOrg(params) {
return request({
method: 'GET',
url: `/api/marketsearchDetails/getSuedOrg`,
params
})
}
// 进出口数据
export function getOrgImportAndExport(params) {
return request({
method: 'GET',
url: `/api/organization/scale/getOrgImportAndExport`,
params
})
}
// 营收数据
export function getRevenue(params) {
return request({
method: 'GET',
url: `/api/organization/scale/revenue`,
params
})
}
// 净利润数据
export function getNetProfit(params) {
return request({
method: 'GET',
url: `/api/organization/scale/netProfit`,
params
})
}
\ No newline at end of file
......@@ -2,7 +2,7 @@
<template>
<div class="home-wrapper">
<img :src="background" alt="" class="background-img" />
<div class="home-header">
<!-- <div class="home-header">
<div class="header-left">
<HeaderMenu></HeaderMenu>
</div>
......@@ -21,7 +21,7 @@
</div>
</div>
</div>
</div>
</div> -->
<div class="content-box">
<!-- 导航栏 -->
<div class="content-nav">
......@@ -168,92 +168,91 @@ const handleDateClick = type => {
width: 100%;
height: 700px;
position: absolute;
top: 64px;
left: 0;
z-index: -1;
}
.home-header {
height: 64px;
flex-shrink: 0;
z-index: 100;
background: url("./assets/images/header-bg.png") no-repeat center center;
background-size: 100% 100%;
box-sizing: border-box;
padding: 0 160px;
display: flex;
justify-content: space-between;
align-items: center;
.header-right {
.header-search-box {
display: flex;
gap: 12px;
justify-content: flex-end;
// .home-header {
// height: 64px;
// flex-shrink: 0;
// z-index: 100;
// background: url("./assets/images/header-bg.png") no-repeat center center;
// background-size: 100% 100%;
// box-sizing: border-box;
// padding: 0 160px;
// display: flex;
// justify-content: space-between;
// align-items: center;
// .header-right {
// .header-search-box {
// display: flex;
// gap: 12px;
// justify-content: flex-end;
.header-search-left {
width: 360px;
height: 36px;
line-height: 36px;
border-radius: 4px;
background: rgba(255, 255, 255, 0.3);
display: flex;
// .header-search-left {
// width: 360px;
// height: 36px;
// line-height: 36px;
// border-radius: 4px;
// background: rgba(255, 255, 255, 0.3);
// display: flex;
.input-box {
width: 324px;
:deep(.el-input) {
.el-input__wrapper {
background-color: transparent !important;
box-shadow: none !important;
padding: 0 12px;
}
.el-input__inner {
color: #fff;
height: 36px;
line-height: 36px;
&::placeholder {
color: rgba(255, 255, 255, 0.6);
}
}
}
}
// .input-box {
// width: 324px;
// :deep(.el-input) {
// .el-input__wrapper {
// background-color: transparent !important;
// box-shadow: none !important;
// padding: 0 12px;
// }
// .el-input__inner {
// color: #fff;
// height: 36px;
// line-height: 36px;
// &::placeholder {
// color: rgba(255, 255, 255, 0.6);
// }
// }
// }
// }
.icon {
width: 36px;
height: 36px;
border-radius: 4px;
cursor: pointer;
&:hover {
background: rgba(255, 255, 255, 0.5);
}
// .icon {
// width: 36px;
// height: 36px;
// border-radius: 4px;
// cursor: pointer;
// &:hover {
// background: rgba(255, 255, 255, 0.5);
// }
img {
width: 100%;
height: 100%;
}
}
}
// img {
// width: 100%;
// height: 100%;
// }
// }
// }
.header-search-right {
width: 36px;
height: 36px;
line-height: 36px;
border-radius: 4px;
background: rgba(255, 255, 255, 0.3);
cursor: pointer;
// .header-search-right {
// width: 36px;
// height: 36px;
// line-height: 36px;
// border-radius: 4px;
// background: rgba(255, 255, 255, 0.3);
// cursor: pointer;
.header-img-box {
width: 19px;
height: 24px;
margin: 5px auto;
// .header-img-box {
// width: 19px;
// height: 24px;
// margin: 5px auto;
img {
width: 100%;
height: 100%;
}
}
}
}
}
}
// img {
// width: 100%;
// height: 100%;
// }
// }
// }
// }
// }
// }
.content-box {
flex: 1;
......
......@@ -933,7 +933,7 @@ onMounted(() => {
width: 1064px;
height: 846px;
.box2 {
width: 1210px;
width: 1064px;
height: 415px;
border: 1px solid rgba(234, 236, 238, 1);
border-radius: 10px;
......@@ -948,7 +948,7 @@ onMounted(() => {
}
.box3 {
margin-top: 16px;
width: 1210px;
width: 1064px;
height: 415px;
border: 1px solid rgba(234, 236, 238, 1);
border-radius: 10px;
......
......@@ -635,7 +635,7 @@ onMounted(() => {
<style lang="scss" scoped>
.process-overview-wrap {
width: 1744px;
width: 1600px;
height: 848px;
border-radius: 10px;
box-shadow: 0px 0px 20px 0px rgba(25, 69, 130, 0.1);
......
......@@ -183,7 +183,7 @@
</div>
</div>
<div class="info-right">
<div class="info-right-title">{{ curPerson.name }}</div>
<div class="info-right-title" @click="handleClickAvatar(curPerson)">{{ curPerson.name }}</div>
<div class="info-right-item">
<div class="item-left">英文名:</div>
<div class="item-right">{{ curPerson.ename }}</div>
......@@ -889,6 +889,7 @@ onMounted(() => {
margin-top: 25px;
display: flex;
.info-left {
cursor: pointer;
img {
width: 128px;
height: 128px;
......@@ -935,6 +936,7 @@ onMounted(() => {
font-size: 16px;
font-weight: 600;
line-height: 22px;
cursor: pointer;
}
.info-right-item {
margin-top: 8px;
......@@ -1110,6 +1112,7 @@ onMounted(() => {
line-height: 22px;
text-align: center;
margin-bottom: 50px;
cursor: pointer;
}
.info-right-item {
margin-top: 8px;
......
......@@ -978,6 +978,7 @@ onUnmounted(() => {
<style lang="scss" scoped>
:deep(.el-input__wrapper) {
box-shadow: none;
height: 44px;
}
:deep(.el-input__wrapper:hover) {
box-shadow: none !important;
......@@ -1024,7 +1025,13 @@ onUnmounted(() => {
font-weight: 400;
}
.wrapper {
width: 100%;
height: 100%;
overflow-y: auto;
.header {
position: sticky;
top: 0;
z-index: 9999;
height: 64px;
color: #fff;
font-family: Microsoft YaHei;
......
......@@ -6,9 +6,9 @@
<div class="icon">
<img src="./assets/images/search-icon1.png" alt="" />
</div>
<el-input v-model="keyword" :border="false" style="width: 900px; height: 100%" @keyup.enter="handleSearch" />
<el-input v-model="keyword" :border="false" style="width: 900px" @keyup.enter="handleSearch" />
</div>
<div class="right" @click="handleSearch">
<div class="right" @click="handleToAi">
<img src="./assets/images/ai-icon.png" alt="" />
</div>
</div>
......@@ -51,9 +51,9 @@
<div class="text-box">
搜索关键词:<span class="text-2">{{ keyword }}</span>
</div>
<div class="text-box">
<!-- <div class="text-box">
当前领域:<span class="text-2">{{ curArea }}</span>
</div>
</div> -->
</div>
<!-- <div class="info-right">
<el-select v-model="selectTime" placeholder="选择时间" style="width: 125px">
......@@ -262,6 +262,13 @@ const handleClickDomains = domain => {
handleSearch();
};
function highlightText(text, keyword) {
if (!text || !keyword) return text;
const regex = new RegExp(`(${keyword})`, 'gi');
return text.replace(regex, '<span style="color: red; font-weight: bold;">$1</span>');
}
const handleSearch = async () => {
let params;
if (activeTabId.value) {
......@@ -292,6 +299,10 @@ const handleSearch = async () => {
}));
}
searchResults.value = res.data.records;
searchResults.value.forEach(item => {
item.originalTitle = highlightText(item.originalTitle, keyword.value)
item.originalDescription = highlightText(item.originalDescription, keyword.value)
})
totalNum.value = res.data.total;
if (totalNum.value) {
ElMessage.success(`共计搜索到${totalNum.value}条结果`);
......@@ -475,27 +486,26 @@ onMounted(() => {
}
handleSearch();
});
const handleToAi = () => {
const route = router.resolve({
path: "/chat"
});
window.open(route.href, "_blank");
};
</script>
<style lang="scss" scoped>
:deep(.el-input__wrapper) {
box-shadow: none;
}
:deep(.el-input__wrapper:hover) {
box-shadow: none !important;
}
:deep(.el-input__wrapper.is-focus) {
box-shadow: none !important;
}
.wrapper {
width: 100%;
height: 100%;
background: url("../assets/images/background.png") no-repeat;
background-size: 100% 100%;
overflow-y: auto;
.header {
margin-top: 24px;
position: relative;
// position: sticky;
// top: 24px;
.header-right {
position: absolute;
width: 360px;
......@@ -589,12 +599,12 @@ onMounted(() => {
margin-top: 12px;
height: 48px;
display: flex;
margin-left: 257px;
align-items: center;
margin-left: 240px;
.tab-left {
width: 726px;
height: 48px;
display: flex;
justify-content: flex-start;
gap: 32px;
.tab {
color: rgba(59, 65, 75, 1);
......@@ -655,7 +665,7 @@ onMounted(() => {
display: flex;
flex-wrap: wrap;
gap: 12px;
margin-left: 256px;
margin-left: 240px;
.tag {
height: 32px;
line-height: 30px;
......@@ -678,7 +688,7 @@ onMounted(() => {
}
.info-box {
margin-top: 26px;
margin-left: 257px;
margin-left: 240px;
width: 920px;
height: 32px;
display: flex;
......@@ -748,7 +758,7 @@ onMounted(() => {
width: 913px;
// height: 1464px;
margin-top: 36px;
margin-left: 264px;
margin-left: 240px;
.item {
width: 913px;
min-height: 108px;
......@@ -848,7 +858,17 @@ onMounted(() => {
justify-content: center;
}
}
:deep(.el-input__wrapper) {
box-shadow: none;
height: 46px;
}
:deep(.el-input__wrapper:hover) {
box-shadow: none !important;
}
:deep(.el-input__wrapper.is-focus) {
box-shadow: none !important;
}
:deep(.el-input__inner) {
color: rgba(59, 65, 75, 1);
font-family: Microsoft YaHei;
......
......@@ -285,17 +285,17 @@
<div class="header-title">{{ "社交媒体" }}</div>
</div>
<div class="box4-main">
<MessageBubble
v-for="(item, index) in messageList"
@click="handleClickPerson(item)"
@info-click="handleMediaClick(item)"
:key="index"
:avatar="item.img ? item.img : DefaultIcon1"
:name="item.name"
:time="item.time"
:source="item.source"
:content="item.content"
/>
<MessageBubble
v-for="(item, index) in messageList"
@click="handleClickPerson(item)"
@info-click="handleMediaClick(item)"
:key="index"
:avatar="item.img ? item.img : DefaultIcon1"
:name="item.name"
:time="item.time"
:source="item.source"
:content="item.content"
/>
<!-- <div class="box4-main-item" v-for="(item, index) in messageList" :key="index">
<div class="left" @click="handleClickPerson(item)">
<img :src="item.img ? item.img : DefaultIcon1" alt="" />
......@@ -407,8 +407,7 @@
</div>
<div class="header-title">{{ "政令重点条款" }}</div>
</div>
<div class="box8-main" id="wordCloudChart">
</div>
<div class="box8-main" id="wordCloudChart"></div>
</div>
</div>
</div>
......@@ -561,7 +560,7 @@
</template>
<script setup>
import { onMounted, ref, computed, watch } from "vue";
import { onMounted, ref, computed, watch, nextTick } from "vue";
import router from "@/router";
import HeaderMenu from "@/components/headerMenu.vue";
import headerInfo from "@/components/headerInfo.vue";
......@@ -1141,19 +1140,25 @@ const handleSwithSort = () => {
};
const handleToPosi = id => {
// 0 618 1240 2350
switch (id) {
case "position2":
containerRef.value.scrollTop = isShow.value ? 844 : 1190;
break;
case "position3":
containerRef.value.scrollTop = isShow.value ? 1480 : 1826;
break;
case "position4":
containerRef.value.scrollTop = isShow.value ? 2554 : 2900;
break;
default:
containerRef.value.scrollTop = 0;
const element = document.getElementById(id);
if (element && containerRef.value) {
// 1. 如果是从完整搜索框跳转,先强制切换状态稳定布局
if (!isShow.value) {
isShow.value = true;
}
// 2. 使用 nextTick 等待 DOM 布局(如高度切换)完成后再进行坐标计算
nextTick(() => {
const containerRect = containerRef.value.getBoundingClientRect();
const elementRect = element.getBoundingClientRect();
// 使用 getBoundingClientRect 计算元素相对于容器顶部的绝对距离,不受嵌套布局影响
const top = elementRect.top - containerRect.top + containerRef.value.scrollTop;
containerRef.value.scrollTo({
top: top,
behavior: "smooth"
});
});
}
};
......@@ -1583,7 +1588,7 @@ onMounted(async () => {
box-shadow: 0px 0px 20px 0px rgba(25, 69, 130, 0.1);
background: rgba(255, 255, 255, 0.65);
align-items: center;
gap:17px;
gap: 17px;
margin: 0 6px 16px 6px;
cursor: pointer;
transition: transform 0.3s ease, box-shadow 0.3s ease;
......
<template>
<div class="case-wrap">
<Discussion1 v-if="showDiscussion ==='337'"></Discussion1>
<Discussion2 v-else-if="showDiscussion ==='232'"></Discussion2>
<Discussion3 v-else></Discussion3>
<Discussion2 v-if="showDiscussion ==='232'"></Discussion2>
<Discussion3 v-if="showDiscussion ==='301'"></Discussion3>
</div>
</template>
<script setup>
import { ref, onMounted, computed } from "vue";
// import Discussion1 from './337/index.vue'
// import Discussion2 from './232/index.vue'
import Discussion1 from './337/index.vue'
import Discussion2 from './232/index.vue'
import Discussion3 from './301/index.vue'
import { useRoute } from "vue-router";
......
......@@ -22,7 +22,7 @@
</div>
</div>
<div class="center">
<div class="box1">
<div class="box1" v-loading="box1Loading">
<div class="box-header">
<div class="header-left"></div>
<div class="title">美国对华337调查年度趋势</div>
......@@ -39,8 +39,8 @@
</div>
</div>
<div class="box1-main" id="chart1"></div>
</div>
<div class="box2">
</div>
<div class="box2" v-loading="box2Loading">
<div class="box-header">
<div class="header-left"></div>
<div class="title">调查案件领域分布</div>
......@@ -60,7 +60,7 @@
</div>
</div>
<div class="footer">
<div class="box3">
<div class="box3" v-loading="box3Loading">
<div class="box-header">
<div class="header-left"></div>
<div class="title">中国公司受调查情况</div>
......@@ -106,7 +106,7 @@
<div class="box3-main1-right" id="chartMap"></div>
</div>
</div>
<div class="box4">
<div class="box4" v-loading="box4Loading">
<div class="box-header">
<div class="header-left"></div>
<div class="title">调查结果分布</div>
......@@ -133,6 +133,8 @@ import * as echarts from "echarts";
import ChinaJson from "../../assets/json/China.json";
import { getStatcnOrgCount, getSearchResult, getStatArea, getStatNum } from "@/api/marketAccessRestrictions";
import getMultiLineChart from "./utils/multiLineChart";
import getBarChart from "./utils/barChart";
import getPieChart from "./utils/piechart";
......@@ -147,95 +149,198 @@ const setChart = (option, chartId) => {
return chart;
};
const box1Loading = ref(false);
const box2Loading = ref(false);
const box3Loading = ref(false);
const box4Loading = ref(false);
const btnActiveName = ref("注册地分布");
const provinceCoords = {
"北京": [116.46, 39.92],
"上海": [121.48, 31.22],
"天津": [117.2, 39.13],
"重庆": [106.54, 29.59],
"河北": [114.48, 38.03],
"山西": [112.53, 37.87],
"内蒙古": [111.65, 40.82],
"辽宁": [123.38, 41.8],
"吉林": [125.35, 43.88],
"黑龙江": [126.63, 45.75],
"江苏": [118.78, 32.04],
"浙江": [120.19, 30.26],
"安徽": [117.27, 31.86],
"福建": [119.3, 26.08],
"江西": [115.89, 28.68],
"山东": [117.0, 36.65],
"河南": [113.65, 34.76],
"湖北": [114.31, 30.52],
"湖南": [113.0, 28.21],
"广东": [113.23, 23.16],
"广西": [108.33, 22.84],
"海南": [110.35, 20.02],
"四川": [104.06, 30.67],
"贵州": [106.71, 26.57],
"云南": [102.73, 25.04],
"西藏": [91.11, 29.97],
"陕西": [108.95, 34.27],
"甘肃": [103.73, 36.03],
"青海": [101.74, 36.56],
"宁夏": [106.27, 38.47],
"新疆": [87.68, 43.77],
"香港": [114.17, 22.28],
"澳门": [113.54, 22.19],
"台湾": [121.5, 25.05]
};
const handleGetStatcnOrgCount = async (type) => {
box3Loading.value = true;
try {
const res = await getStatcnOrgCount({
type,
sortCode: "337"
});
if (res.code === 200 && res.data) {
if (type === "01") {
chart3Data.value = {
name: res.data.map(item => item.ORGNAME),
value: res.data.map(item => item.ORGCOUNT)
};
nextTick(() => {
let chart3 = getBarChart(chart3Data.value.name, chart3Data.value.value);
setChart(chart3, "chart3");
});
} else if (type === "02") {
mapData.value = res.data.map(item => {
const name = item.ORGPROVINCE//.replace(/省|市|自治区|特别行政区/g, "");
return {
name: item.ORGPROVINCE,
value: item.PROVINCECOUNT,
coord: provinceCoords[name] || [0, 0]
};
});
nextTick(() => {
let chartMap = getMapChart(mapData.value);
setChart(chartMap, "chartMap");
});
}
}
} catch (error) {
console.error("获取中国公司受调查情况失败", error);
} finally {
box3Loading.value = false;
}
};
const handleClickBox3Btn = name => {
btnActiveName.value = name;
if (name === "调查次数") {
nextTick(() => {
let chart3 = getBarChart(chart3Data.value.name, chart3Data.value.value);
setChart(chart3, "chart3");
});
handleGetStatcnOrgCount("01");
} else {
nextTick(() => {
let chartMap = getMapChart(mapData.value);
setChart(chartMap, "chartMap");
});
handleGetStatcnOrgCount("02");
}
};
const chart1Data = ref({
title: ["2014", "2015", "2016", "2017", "2018", "2019", "2020", "2021", "2022", "2023", "2024", "2025"],
data: [
{
name: "提出法案",
value: [145, 52, 84, 99, 71, 96, 128, 144, 140, 168, 188, 172]
}
]
title: [],
data: []
});
const chart2Data = ref([
{ name: "半导体", value: 50 },
{ name: "电子设备", value: 46 },
{ name: "显示技术", value: 40 },
{ name: "新能源", value: 32 },
{ name: "通信设备", value: 31 },
{ name: "汽车", value: 31 },
{ name: "轻工业制造", value: 30 },
{ name: "其他", value: 24 }
]);
const handleGetStatNum = async () => {
box1Loading.value = true;
try {
const res = await getStatNum({
byYorM: "12",
sortCode: "337"
});
if (res.code === 200 && res.data) {
const sortedData = res.data.sort((a, b) => parseInt(a.searchYorM) - parseInt(b.searchYorM));
chart1Data.value.title = sortedData.map(item => item.searchYorM);
chart1Data.value.data = [
{
name: "调查数量",
value: sortedData.map(item => item.searchCount)
}
];
nextTick(() => {
let chart1 = getMultiLineChart(chart1Data.value.title, chart1Data.value.data[0].value);
setChart(chart1, "chart1");
});
}
} catch (error) {
console.error("获取年度趋势数据失败", error);
} finally {
box1Loading.value = false;
}
};
const chart2Data = ref([]);
const chart2ColorList = ref(["#69B1FF", "#FFC069", "#87E8DE", "#597EF7", "#D6E4FF", "#FF7875", "#B37FEB", "#FFA39E"]);
const handleGetStatArea = async () => {
box2Loading.value = true;
try {
const res = await getStatArea({
sortCode: "337"
});
if (res.code === 200 && res.data) {
chart2Data.value = res.data
.filter(item => item.SORTCODE === "337" || item.SORTNAME === "337调查")
.map(item => ({
name: item.AREANAME,
value: item.AREACOUNT
}));
nextTick(() => {
let chart2 = getPieChart(chart2Data.value, chart2ColorList.value);
setChart(chart2, "chart2");
});
}
} catch (error) {
console.error("获取调查案件领域分布失败", error);
} finally {
box2Loading.value = false;
}
};
const chart3Data = ref({
name: [
"华为技术有限公司",
"大疆创新科技有限公司",
"TCL科技集团股份有限公司",
"中兴通讯股份有限公司",
"联想集团",
"比亚迪集团",
"宁德时代新能源科技股份有限公司",
"晶科智能科技有限公司"
],
value: [42, 35, 28, 19, 15, 12, 11, 8]
name: [],
value: []
});
const mapData = ref([
{ name: "北京", value: 10, coord: [116.46, 39.92] },
{ name: "上海", value: 9, coord: [121.48, 31.22] },
{ name: "广东", value: 15, coord: [113.23, 23.16] },
{ name: "江苏", value: 30, coord: [118.78, 32.04] },
{ name: "浙江", value: 20, coord: [120.19, 30.26] },
{ name: "四川", value: 4, coord: [104.06, 30.67] },
{ name: "陕西", value: 1, coord: [108.95, 34.27] },
{ name: "辽宁", value: 3, coord: [123.38, 41.8] }
// { name: "湖北", value: 2, coord: [114.31, 30.52] },
// { name: "山东", value: 12, coord: [117.0, 36.65] },
]);
const chart4Data = ref([
{ name: "和解/同意令", value: 50 },
{ name: "裁定不侵权", value: 46 },
{ name: "裁定侵权", value: 40 },
{ name: "申诉方撤诉", value: 31 },
{ name: "其他", value: 24 }
]);
const chart4ColorList = ref(["#69B1FF", "#FFC069", "#87E8DE", "#D6E4FF", "#FFA39E"]);
const mapData = ref([]);
onMounted(() => {
let chart1 = getMultiLineChart(chart1Data.value.title, chart1Data.value.data[0].value);
setChart(chart1, "chart1");
const chart4Data = ref([]);
const chart4ColorList = ref(["#69B1FF", "#FFC069", "#87E8DE", "#597EF7", "#D6E4FF", "#FF7875", "#B37FEB", "#FFA39E"]);
let chart2 = getPieChart(chart2Data.value, chart2ColorList.value);
setChart(chart2, "chart2");
const handleGetSearchResult = async () => {
box4Loading.value = true;
try {
const res = await getSearchResult({
sortCode: "337"
});
if (res.code === 200 && res.data) {
chart4Data.value = res.data.map(item => ({
name: item.RESULTNAME,
value: item.RESULTNUM
}));
nextTick(() => {
let chart4 = getPieChart(chart4Data.value, chart4ColorList.value);
setChart(chart4, "chart4");
});
}
} catch (error) {
console.error("获取调查结果分布失败", error);
} finally {
box4Loading.value = false;
}
};
let chart3 = getBarChart(chart3Data.value.name, chart3Data.value.value);
setChart(chart3, "chart3");
onMounted(() => {
handleGetStatNum();
let chartMap = getMapChart(mapData.value);
setChart(chartMap, "chartMap");
handleGetStatArea();
let chart4 = getPieChart(chart4Data.value, chart4ColorList.value);
setChart(chart4, "chart4");
handleGetStatcnOrgCount(btnActiveName.value === "调查次数" ? "01" : "02");
handleGetSearchResult();
});
</script>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论