diff --git a/src/views/iot/device/detailForm.vue b/src/views/iot/device/detailForm.vue index dc3e160a..66654719 100644 --- a/src/views/iot/device/detailForm.vue +++ b/src/views/iot/device/detailForm.vue @@ -11,7 +11,7 @@ - + @@ -599,6 +599,9 @@ const resetDeviceAlarmQuery = () => { deviceAlarmQueryParams.pageNo = 1 getDeviceAlarmList() } +const changeClick = () => { + deviceTabActive.value==='deviceRule' ? getRuleList() : getDeviceAlarmList() +} const openCreateRuleForm = () => { if (!attributeDeviceId.value) { diff --git a/src/views/iot/runoverview/components/StatusDistributionChart.vue b/src/views/iot/runoverview/components/StatusDistributionChart.vue index 2dacea95..2b9ec06d 100644 --- a/src/views/iot/runoverview/components/StatusDistributionChart.vue +++ b/src/views/iot/runoverview/components/StatusDistributionChart.vue @@ -23,12 +23,17 @@
{{ t('DataCollection.RunOverview.summaryTitle') }}
- -
-
- - {{ statusLabelMap[item.status] }} - {{ item.percent.toFixed(2) }}% ({{ item.hours.toFixed(2) }}h) +
+ + +
+
+ + {{ statusLabelMap[item.status] }} + {{ item.percent.toFixed(2) }}% ({{ item.hours.toFixed(2) }}h) +
@@ -198,20 +203,34 @@ const pieOption = computed(() => ({ } .chart-panel__side { - padding: 8px 8px 0; + padding: 8px 12px 0; +} + +.chart-panel__summary-layout { + display: grid; + grid-template-columns: minmax(180px, 220px) minmax(180px, 1fr); + align-items: center; + gap: 8px 16px; + min-height: 280px; +} + +.chart-panel__pie { + display: flex; + align-items: center; + justify-content: center; } .chart-panel__legend { display: flex; flex-direction: column; - gap: 10px; - margin-top: -8px; + gap: 14px; + justify-content: center; } .chart-panel__legend-item { display: grid; - grid-template-columns: 12px 1fr auto; - gap: 8px; + grid-template-columns: 12px 52px 1fr; + gap: 10px; align-items: center; color: #344054; font-size: 13px; @@ -230,11 +249,22 @@ const pieOption = computed(() => ({ .value { color: #101828; font-weight: 600; + text-align: left; } @media (max-width: 1100px) { .chart-panel__body { grid-template-columns: 1fr; } + + .chart-panel__summary-layout { + grid-template-columns: 1fr; + justify-items: center; + } + + .chart-panel__legend { + width: 100%; + max-width: 320px; + } }