修
This commit is contained in:
parent
376bd0bb11
commit
e940e4f809
|
|
@ -463,9 +463,9 @@ export const useGroupStructureStore = defineStore("groupStructure", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name === '内部密度指数演化' ? 20.0 : 0,
|
||||
max: item.name === '内部密度指数演化' ? 20.5 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name === '内部密度指数演化' ? 0.1 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data,
|
||||
|
|
@ -480,9 +480,9 @@ export const useGroupStructureStore = defineStore("groupStructure", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name === '内部密度指数演化' ? 20.0 : 0,
|
||||
max: item.name === '内部密度指数演化' ? 20.5 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name === '内部密度指数演化' ? 0.1 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data,
|
||||
|
|
@ -497,9 +497,9 @@ export const useGroupStructureStore = defineStore("groupStructure", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name === '内部密度指数演化' ? 20.0 : 0,
|
||||
max: item.name === '内部密度指数演化' ? 20.5 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name === '内部密度指数演化' ? 0.1 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data,
|
||||
|
|
@ -626,9 +626,9 @@ export const useGroupMemberStore = defineStore("groupMember", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name ==='合并演化' || item.name ==='扩展演化' ? 20.00 : 0,
|
||||
max: item.name ==='合并演化' || item.name ==='扩展演化' ? 20.03 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name ==='合并演化' || item.name ==='扩展演化' ? 0.006 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data.map((item) => item.toFixed(2)),
|
||||
|
|
@ -644,9 +644,9 @@ export const useGroupMemberStore = defineStore("groupMember", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name ==='合并演化' || item.name ==='扩展演化' ? 20.00 : 0,
|
||||
max: item.name ==='合并演化' || item.name ==='扩展演化' ? 20.03 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name ==='合并演化' || item.name ==='扩展演化' ? 0.006 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data.map((item) => item.toFixed(2)),
|
||||
|
|
@ -662,9 +662,9 @@ export const useGroupMemberStore = defineStore("groupMember", {
|
|||
chart: {
|
||||
xAxisData: item.chart.xaxisData.map((item) => utcStringToHHMMSS(item)),
|
||||
yAxisRange: {
|
||||
min: 0,
|
||||
max: Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
min: item.name ==='合并演化' ? 20.00 : 0,
|
||||
max: item.name ==='合并演化' ? 20.03 : Math.ceil(item.chart.yaxisRange.max / 5) * 5,
|
||||
interval: item.name ==='合并演化' ? 0.006 : Math.ceil(item.chart.yaxisRange.max / 5)
|
||||
},
|
||||
seriesList: item.chart.seriesList.map((item) => ({
|
||||
data: item.data.map((item) => item.toFixed(2)),
|
||||
|
|
|
|||
|
|
@ -29,9 +29,9 @@
|
|||
<script setup>
|
||||
import { defineProps, onMounted, ref, watch } from "vue";
|
||||
import GroupChart from "../../component/groupChart.vue";
|
||||
const curSelectedTab = ref("头部自媒体");
|
||||
const curSelectedTab = ref("群体一");
|
||||
const curSelectedTabData = ref(null);
|
||||
const tabs = ["头部自媒体", "官方媒体", "普通自媒体"];
|
||||
const tabs = ["群体一", "群体二", "群体三"];
|
||||
const props = defineProps({
|
||||
title: {
|
||||
type: String,
|
||||
|
|
@ -50,9 +50,9 @@ watch(
|
|||
// 当chartsData加载完成且不为空时,更新当前选中标签的数据
|
||||
if (newVal && Object.keys(newVal).length > 0) {
|
||||
const keyMapList = {
|
||||
头部自媒体: "topSelfMedia",
|
||||
官方媒体: "officalMedia",
|
||||
普通自媒体: "ordinaryMedia"
|
||||
群体一: "topSelfMedia",
|
||||
群体二: "officalMedia",
|
||||
群体三: "ordinaryMedia"
|
||||
};
|
||||
const currentKey = keyMapList[curSelectedTab.value];
|
||||
if (newVal[currentKey]) {
|
||||
|
|
@ -67,15 +67,16 @@ watch(
|
|||
const handleSwitch = (item) => {
|
||||
curSelectedTab.value = item;
|
||||
const keyMapList = {
|
||||
头部自媒体: "topSelfMedia",
|
||||
官方媒体: "officalMedia",
|
||||
普通自媒体: "ordinaryMedia"
|
||||
群体一: "topSelfMedia",
|
||||
群体二: "officalMedia",
|
||||
群体三: "ordinaryMedia"
|
||||
};
|
||||
curSelectedTabData.value = props.chartsData[keyMapList[item]];
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
handleSwitch("头部自媒体");
|
||||
handleSwitch("群体一");
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user