提交 4a198500 authored 作者: 付康's avatar 付康

合并分支 'fk-dev' 到 'pre'

Fk dev 查看合并请求 !324
流水线 #389 已通过 于阶段
in 3 分 30 秒
......@@ -1131,10 +1131,10 @@ const initParam = () => {
const query = route.query;
if (Object.keys(query).length > 0) {
sessionStorage.setItem('routeQuery', JSON.stringify(query));
sessionStorage.setItem('countryRouteQuery', JSON.stringify(query));
}
} else {
const savedQuery = JSON.parse(sessionStorage.getItem('routeQuery') || '{}');
const savedQuery = JSON.parse(sessionStorage.getItem('countryRouteQuery') || '{}');
selectedArea.value = savedQuery.domains ? savedQuery.domains : '全部领域'
if (savedQuery.selectedDate && Array.isArray(JSON.parse(savedQuery.selectedDate)) && JSON.parse(savedQuery.selectedDate).length) {
selectedDate.value = '自定义'
......
......@@ -876,10 +876,10 @@ const initParam = () => {
const query = route.query;
if (Object.keys(query).length > 0) {
sessionStorage.setItem('decreeRouteQuery', JSON.stringify(query));
sessionStorage.setItem('commerceRouteQuery', JSON.stringify(query));
}
} else {
const savedQuery = JSON.parse(sessionStorage.getItem('decreeRouteQuery') || '{}');
const savedQuery = JSON.parse(sessionStorage.getItem('commerceRouteQuery') || '{}');
selectedArea.value = savedQuery.domains ? savedQuery.domains : '全部领域'
if (savedQuery.selectedDate && Array.isArray(JSON.parse(savedQuery.selectedDate)) && JSON.parse(savedQuery.selectedDate).length) {
selectedDate.value = '自定义'
......
......@@ -803,10 +803,10 @@ const initParam = () => {
const query = route.query;
if (Object.keys(query).length > 0) {
sessionStorage.setItem('decreeRouteQuery', JSON.stringify(query));
sessionStorage.setItem('commerceEventRouteQuery', JSON.stringify(query));
}
} else {
const savedQuery = JSON.parse(sessionStorage.getItem('decreeRouteQuery') || '{}');
const savedQuery = JSON.parse(sessionStorage.getItem('commerceEventRouteQuery') || '{}');
selectedArea.value = savedQuery.domains ? savedQuery.domains : '全部领域'
if (savedQuery.selectedDate && Array.isArray(JSON.parse(savedQuery.selectedDate)) && JSON.parse(savedQuery.selectedDate).length) {
selectedDate.value = '自定义'
......
......@@ -191,7 +191,7 @@ const route = useRoute();
const isShowProvinceBox = computed(() => {
let isShow = false
if(isFolderAll.value && (selectedCountry.value==='0101' || selectedCountry.value==='全部国家')) {
if (isFolderAll.value && (selectedCountry.value === '0101' || selectedCountry.value === '全部国家')) {
isShow = true
}
return isShow
......@@ -207,18 +207,18 @@ const handleSwitchChartData = () => {
return item.name === curDemension.value
})[0]
// setTimeout(() => {
activeChart.value = curDemensionItem.chartTypeList[0]
if (curDemension.value === '制裁时间') {
if (selectedTime.value === '按月度统计') {
curChartData.value = curDemensionItem.data
} else if (selectedTime.value === '按季度统计') {
curChartData.value = curDemensionItem.quatarData
} else {
curChartData.value = curDemensionItem.yearData
}
} else {
activeChart.value = curDemensionItem.chartTypeList[0]
if (curDemension.value === '制裁时间') {
if (selectedTime.value === '按月度统计') {
curChartData.value = curDemensionItem.data
} else if (selectedTime.value === '按季度统计') {
curChartData.value = curDemensionItem.quatarData
} else {
curChartData.value = curDemensionItem.yearData
}
} else {
curChartData.value = curDemensionItem.data
}
// })
}
}
......@@ -686,7 +686,7 @@ const handleGetProvinceList = async () => {
try {
const res = await getProvinceList()
console.log('获取省份列表', res);
if(res && res.length) {
if (res && res.length) {
provinceList.value = res.map(item => {
return {
name: item,
......@@ -1051,30 +1051,33 @@ const initParam = () => {
customTime.value = JSON.parse(route.query.selectedDate)
}
selectedCountry.value = route.query.orgnizationName ? route.query.orgnizationName : '全部国家'
selectedProvince.value = route.query.selectedProvince ? provinceList.value.filter(item => item.name.indexOf(route.query.selectedProvince) > -1)[0].name : '全部省份'
selectedCountry.value = route.query.selectedCountryId ? route.query.selectedCountryId : '全部国家'
isHalfRule.value = route.query.isHalfRule ? true : false
isCnEntityOnly.value = route.query.isCnEntityOnly ? true : false
selectedEntityType.value = route.query.selectedEntityType ? route.query.selectedEntityType : '全部实体类型'
selectedEntityType.value = route.query.selectedEntityType ? entityTypeList.value.filter(item => item.name === route.query.selectedEntityType)[0].id : '全部实体类型'
const query = route.query;
if (Object.keys(query).length > 0) {
sessionStorage.setItem('decreeRouteQuery', JSON.stringify(query));
sessionStorage.setItem('entityRouteQuery', JSON.stringify(query));
}
} else {
const savedQuery = JSON.parse(sessionStorage.getItem('decreeRouteQuery') || '{}');
const savedQuery = JSON.parse(sessionStorage.getItem('entityRouteQuery') || '{}');
selectedArea.value = savedQuery.domains ? savedQuery.domains : '全部领域'
if (savedQuery.selectedDate && Array.isArray(JSON.parse(savedQuery.selectedDate)) && JSON.parse(savedQuery.selectedDate).length) {
selectedDate.value = '自定义'
customTime.value = JSON.parse(savedQuery.selectedDate)
}
isHalfRule.value = savedQuery.isHalfRule ? true : false
selectedProvince.value = savedQuery.selectedProvince ? provinceList.value.filter(item => item.name.indexOf(savedQuery.selectedProvince) > -1)[0].name : '全部省份'
selectedCountry.value = route.query.selectedCountryId ? route.query.selectedCountryId : '全部国家'
isCnEntityOnly.value = savedQuery.isCnEntityOnly ? true : false
selectedEntityType.value = savedQuery.selectedEntityType ? savedQuery.selectedEntityType : '全部实体类型'
selectedEntityType.value = savedQuery.selectedEntityType ? entityTypeList.value.filter(item => item.name === savedQuery.selectedEntityType)[0].id : '全部实体类型'
}
}
......@@ -1129,9 +1132,9 @@ const handleExport = () => {
};
onMounted(async () => {
handleGetProvinceList() // 获取省份列表
handleGetCountryList() // 获取国家列表
handleGetEntityTypes() // 获取实体类型列表
await handleGetProvinceList() // 获取省份列表
await handleGetCountryList() // 获取国家列表
await handleGetEntityTypes() // 获取实体类型列表
initParam()
// 初始化
await fetchTableData()
......
......@@ -803,10 +803,10 @@ const initParam = () => {
const query = route.query;
if (Object.keys(query).length > 0) {
sessionStorage.setItem('decreeRouteQuery', JSON.stringify(query));
sessionStorage.setItem('entityEventRouteQuery', JSON.stringify(query));
}
} else {
const savedQuery = JSON.parse(sessionStorage.getItem('decreeRouteQuery') || '{}');
const savedQuery = JSON.parse(sessionStorage.getItem('entityEventRouteQuery') || '{}');
selectedArea.value = savedQuery.domains ? savedQuery.domains : '全部领域'
if (savedQuery.selectedDate && Array.isArray(JSON.parse(savedQuery.selectedDate)) && JSON.parse(savedQuery.selectedDate).length) {
selectedDate.value = '自定义'
......
......@@ -393,7 +393,7 @@ const timer = ref(null);
// 关闭当前标签页
const handleCloseCurTab = (tab, index) => {
if(tagsViewStore.visitedViews.length === 1) {
if (tagsViewStore.visitedViews.length === 1) {
ElMessage.warning('至少保留一个标签页')
return
}
......@@ -494,16 +494,17 @@ onMounted(() => {
siderList.value[3].isExpanded = true;
siderList.value[3].children[0].active = true;
break;
case "/dataLibrary/dataCommerceControlList":
case "/dataLibrary/dataEntityListEvent":
siderList.value[3].active = true;
siderList.value[3].isExpanded = true;
siderList.value[3].children[1].active = true;
break;
case "/dataLibrary/dataEntityListEvent":
case "/dataLibrary/dataCommerceControlList":
siderList.value[3].active = true;
siderList.value[3].isExpanded = true;
siderList.value[3].children[2].active = true;
break;
case "/dataLibrary/dataCommerceControlListEvent":
siderList.value[3].active = true;
siderList.value[3].isExpanded = true;
......
......@@ -973,7 +973,7 @@ export const getMultipleBarChart_m = object => {
const option = {
tooltip: {
trigger: "axis",
trigger: "item",
axisPointer: {
type: "shadow"
}
......
......@@ -105,7 +105,8 @@
</div>
</template>
<!-- <div class="echarts" ref="sanctionCountChartRef"></div> -->
<EChart :option="sanctionCountChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" />
<EChart :option="sanctionCountChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }"
@chart-click="handleBarChartClick" />
<!-- <div class="bottom">
<div class="ai">
<div class="left">
......@@ -139,17 +140,14 @@
<div class="map-wrapper">
<div class="map-chart" ref="mapChartRef"></div>
<div class="rank-list">
<div class="rank-item" v-for="(item, index) in rankData" :key="index">
<div class="rank-item" v-for="(item, index) in rankData" :key="index" @click="handleClickRankChart(item)">
<div class="rank-index" :class="'rank-' + (index + 1)">{{ index + 1 }}</div>
<div class="rank-name">{{ item.name }}</div>
<div class="rank-bar-bg">
<div
class="rank-bar-fill"
:style="{
width: (item.value / maxRankValue) * 100 + '%',
background: getBarColor(index)
}"
></div>
<div class="rank-bar-fill" :style="{
width: (item.value / maxRankValue) * 100 + '%',
background: getBarColor(index)
}"></div>
</div>
<div class="rank-value">{{ item.value }}家</div>
</div>
......@@ -186,7 +184,8 @@
</el-select>
</template>
<!-- <div class="echarts" ref="domainChartRef"></div> -->
<EChart :option="domainChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" />
<EChart :option="domainChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }"
@chart-click="handlePieChartClick" />
<!-- <div class="bottom">
<div class="ai">
<div class="left">
......@@ -218,7 +217,7 @@
</el-select>
</template>
<!-- <div class="echarts" ref="typeChartRef"></div> -->
<EChart :option="typeChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" />
<EChart :option="typeChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" @chart-click="handlePieChartClick1" />
<!-- <div class="bottom">
<div class="ai">
<div class="left">
......@@ -261,6 +260,7 @@ import {
} from "@/api/exportControlV2.0";
import EChart from "@/components/Chart/index.vue";
import { useRoute } from "vue-router";
import { useRouter } from "vue-router";
import tipsIcon from "../../../assets/icons/info-icon.png";
import AiButton from "@/components/base/Ai/AiButton/index.vue";
import AiPane from "@/components/base/Ai/AiPane/index.vue";
......@@ -271,6 +271,7 @@ const typeChart = useChartInterpretation();
const rankChart = useChartInterpretation();
const route = useRoute();
const router = useRouter()
// 实体清单-数据统计-制裁实体类型分布情况
const typeData = ref([]);
const getTypeCountData = async () => {
......@@ -637,6 +638,17 @@ const updateMapChart = () => {
};
mapChartInstance.setOption(option);
mapChartInstance.on('click', function (params) {
const param = {
selectedProvince: params.name,
selectedDate: regionTime.value === 'all' ? null : JSON.stringify([regionTime.value + '-01-01', regionTime.value + '-12-31'])
}
const route = router.resolve({
path: '/dataLibrary/dataEntityList',
query: param
});
window.open(route.href, "_blank");
});
};
const initMapChart = () => {
......@@ -976,10 +988,10 @@ const updateTypeChart = () => {
let data = typeData.value.length
? [...typeData.value]
: [
{ value: 50, name: "企业" },
{ value: 32, name: "高校" },
{ value: 32, name: "科研院所" }
];
{ value: 50, name: "企业" },
{ value: 32, name: "高校" },
{ value: 32, name: "科研院所" }
];
// 2. 聚合逻辑:保留前5项,其余合并为“其他”
data.sort((a, b) => b.value - a.value);
......@@ -1100,6 +1112,64 @@ const initTypeChart = () => {
};
const sanTypeId = ref("");
// 点击制裁实体数量变化情况
const handleBarChartClick = (val) => {
console.log('value', val);
const params = {
selectedDate: activeTab.value === 'year' ? JSON.stringify([val.name + '-01-01', val.name + '-12-31']) : JSON.stringify([val.name, val.name])
}
const route = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(route.href, "_blank");
}
// 制裁实体各省分布情况
const handleClickRankChart = (item) => {
// console.log('item', item);
const params = {
selectedProvince: item.name,
selectedDate: regionTime.value === 'all' ? null : JSON.stringify([regionTime.value + '-01-01', regionTime.value + '-12-31'])
}
const route = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(route.href, "_blank");
}
// 制裁实体领域分布情况
const handlePieChartClick = (val) => {
console.log('val', val);
const params = {
domains: val.name,
selectedDate: domainTime.value === 'all' ? null : JSON.stringify([domainTime.value + '-01-01', domainTime.value + '-12-31'])
}
const route = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(route.href, "_blank");
}
// 制裁实体类型分布情况
const handlePieChartClick1 = (val) => {
console.log('val', val);
const params = {
selectedEntityType: val.name,
selectedDate: typeTime.value === 'all' ? null : JSON.stringify([typeTime.value + '-01-01', typeTime.value + '-12-31'])
}
const route = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(route.href, "_blank");
}
onMounted(() => {
sanTypeId.value = route.query.sanTypeId || "";
console.log("数据统计页面接收到的 sanTypeId:", sanTypeId.value);
......@@ -1536,16 +1606,19 @@ onMounted(() => {
align-items: center;
justify-content: flex-start;
padding: 22px;
.data-origin-icon {
width: 16px;
height: 16px;
font-size: 0px;
margin-right: 8px;
img {
width: 100%;
height: 100%;
}
}
.data-origin-text {
font-family: Source Han Sans CN;
font-size: 14px;
......@@ -1558,18 +1631,23 @@ onMounted(() => {
right: 0px;
bottom: 15px;
z-index: 2;
:deep(.ai-pane-wrapper) {
display: none;
}
:deep(.ai-button-wrapper) {
display: flex;
}
&:hover {
width: 100%;
bottom: 0px;
:deep(.ai-pane-wrapper) {
display: block;
}
:deep(.ai-button-wrapper) {
display: none;
}
......
......@@ -54,7 +54,8 @@
</div>
</div>
</div> -->
<EChart :option="domainChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" />
<EChart :option="domainChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }"
@chart-click="handlePieChartClick" />
<div class="data-origin-box">
<div class="data-origin-icon">
<img :src="tipsIcon" alt="" />
......@@ -104,7 +105,8 @@
</div>
</div>
</div> -->
<EChart :option="typeChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }" />
<EChart :option="typeChartOption" autoresize :style="{ height: '300px', padding: '0 20px' }"
@chart-click="handlePieChartClick1" />
<div class="data-origin-box">
<div class="data-origin-icon">
<img :src="tipsIcon" alt="" />
......@@ -120,17 +122,15 @@
<div class="main-item">
<AnalysisBox title="制裁实体国家地区分布情况">
<div class="country-list">
<div class="list-item" v-for="(item, index) in countryDistribution" :key="index">
<div class="list-item" v-for="(item, index) in countryDistribution" :key="index"
@click="handleClickRankChart(item)">
<img :src="flag" alt="" class="flag" />
<div class="country-name">{{ item.name }}</div>
<div class="progress-bar-container">
<div
class="progress-bar"
:style="{
width: item.width,
background: item.gradient
}"
></div>
<div class="progress-bar" :style="{
width: item.width,
background: item.gradient
}"></div>
</div>
<div class="count" :class="{ highlight: index === 0 }">{{ item.count }}</div>
</div>
......@@ -163,17 +163,15 @@
<div class="map-wrapper">
<div class="map-chart" ref="mapChartRef"></div>
<div class="rank-list">
<div class="rank-item" v-for="(item, index) in regionDistribution" :key="index">
<div class="rank-item" v-for="(item, index) in regionDistribution" :key="index"
@click="handleRankChartClick(item)">
<div class="rank-index" :class="'rank-' + (index + 1)">{{ index + 1 }}</div>
<div class="rank-name">{{ item.name }}</div>
<div class="rank-bar-bg">
<div
class="rank-bar-fill"
:style="{
width: (maxRegionCount > 0 ? (item.count / maxRegionCount) * 100 : 0) + '%',
background: getBarColor(index)
}"
></div>
<div class="rank-bar-fill" :style="{
width: (maxRegionCount > 0 ? (item.count / maxRegionCount) * 100 : 0) + '%',
background: getBarColor(index)
}"></div>
</div>
<div class="rank-value">{{ item.count }}</div>
</div>
......@@ -474,6 +472,18 @@ const initMapChart = () => {
chart.setOption(option);
chart.on('click', function (params) {
const param = {
selectedProvince: params.name,
selectedDate: JSON.stringify([route.query.date, route.query.date])
}
const curRoute = router.resolve({
path: '/dataLibrary/dataEntityList',
query: param
});
window.open(curRoute.href, "_blank");
});
window.addEventListener("resize", () => {
chart.resize();
});
......@@ -841,6 +851,64 @@ const initTypeChart = () => {
// });
};
const sanTypeId = ref("");
// 制裁实体领域分布情况
const handlePieChartClick = (val) => {
// console.log('val', val);
const params = {
domains: val.name,
selectedDate: JSON.stringify([route.query.date, route.query.date])
}
const curRoute = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(curRoute.href, "_blank");
}
// 制裁实体类型分布情况
const handlePieChartClick1 = (val) => {
// console.log('val', val);
const params = {
selectedEntityType: val.name,
selectedDate: JSON.stringify([route.query.date, route.query.date])
}
const curRoute = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(curRoute.href, "_blank");
}
// 制裁实体国家地区分布情况
const handleClickRankChart = (item) => {
// console.log('item', item);
const params = {
selectedCountryId: item.id,
selectedDate: JSON.stringify([route.query.date, route.query.date])
}
const curRoute = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(curRoute.href, "_blank");
}
// 制裁实体各省分布情况
const handleRankChartClick = (item) => {
console.log('item', item);
const params = {
selectedProvince: item.name,
selectedDate: JSON.stringify([route.query.date, route.query.date])
}
const curRoute = router.resolve({
path: '/dataLibrary/dataEntityList',
query: params
});
window.open(curRoute.href, "_blank");
}
onMounted(() => {
// 获取路由参数id
sanTypeId.value = route.query.sanTypeId;
......@@ -986,6 +1054,11 @@ onMounted(() => {
display: flex;
align-items: center;
margin-bottom: 16px;
cursor: pointer;
&:hover {
background: var(--color-primary-2);
}
&:last-child {
margin-bottom: 0;
......@@ -1284,22 +1357,26 @@ onMounted(() => {
}
}
}
.data-origin-box {
width: 100%;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 22px;
.data-origin-icon {
width: 16px;
height: 16px;
font-size: 0px;
margin-right: 8px;
img {
width: 100%;
height: 100%;
}
}
.data-origin-text {
font-family: Source Han Sans CN;
font-size: 14px;
......@@ -1312,18 +1389,23 @@ onMounted(() => {
right: 0px;
bottom: 15px;
z-index: 2;
:deep(.ai-pane-wrapper) {
display: none;
}
:deep(.ai-button-wrapper) {
display: flex;
}
&:hover {
width: 100%;
bottom: 0px;
:deep(.ai-pane-wrapper) {
display: block;
}
:deep(.ai-button-wrapper) {
display: none;
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论