update 统计分析echartCard组件替换
This commit is contained in:
@@ -196,7 +196,13 @@ const hasFilterField = ref(false);
|
||||
watch(
|
||||
() => formData.value,
|
||||
(newVal) => {
|
||||
hasFilterField.value = Object.values({ ...newVal, ...props.extraFilters }).some((item) => item);
|
||||
hasFilterField.value = Object.values({ ...newVal, ...props.extraFilters }).some((item) => {
|
||||
// 排除空数组、空字符串、null、undefined和0
|
||||
if (Array.isArray(item)) {
|
||||
return item.length > 0;
|
||||
}
|
||||
return Boolean(item);
|
||||
});
|
||||
},
|
||||
{ deep: true, immediate: true }
|
||||
);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div class="gl-page-content-grey-full">
|
||||
<div class="content">
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.任务完成统计机台')"
|
||||
:charts-id="'chart-4'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -10,10 +10,10 @@
|
||||
:option="taskCompletionAtWorkstations"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.任务完成统计学科')"
|
||||
:charts-id="'chart-5'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -21,11 +21,11 @@
|
||||
:option="taskCompletionAtDisciplineOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<!-- 新增 任务达成统计 工位/学科 -->
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.任务达成统计机台')"
|
||||
:charts-id="'chart-Quality-1'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -33,10 +33,10 @@
|
||||
:option="taskAchieveAtWorkstations"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.任务达成统计学科')"
|
||||
:charts-id="'chart-Quality-2'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -44,10 +44,10 @@
|
||||
:option="taskAchieveAtDisciplineOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.指标完成统计机台')"
|
||||
:charts-id="'chart-6'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -55,10 +55,10 @@
|
||||
:option="performanceCompletionAtWorkstationsOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.指标完成统计学科')"
|
||||
:charts-id="'chart-7'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -66,10 +66,10 @@
|
||||
:option="performanceCompletionAtDisciplineOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.成员任务进度统计')"
|
||||
:charts-id="'chart-2'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -77,10 +77,10 @@
|
||||
:option="userTaskCompleteOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
<div class="chart-box">
|
||||
<EchartCard
|
||||
<commonFilterChart
|
||||
:title="$t('统计分析.难度系数统计')"
|
||||
:charts-id="'chart-3'"
|
||||
:bar-type="'barChart'"
|
||||
@@ -88,7 +88,7 @@
|
||||
:option="userDifficultyCoefficientOption"
|
||||
:showChangeModel="true"
|
||||
>
|
||||
</EchartCard>
|
||||
</commonFilterChart>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -96,7 +96,7 @@
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, watchEffect } from 'vue';
|
||||
import EchartCard from '@/components/common/echartCard/index.vue';
|
||||
import commonFilterChart from '@/components/common/echartCard/commonFilterChart.vue';
|
||||
import {
|
||||
getTaskCompleteStatisticsApi,
|
||||
getTaskAchieveStatisticsApi,
|
||||
|
||||
Reference in New Issue
Block a user