|
|
@@ -165,7 +165,7 @@ import Box from '@/components/box.vue'
|
|
|
import SelectDate from '@/components/selectDate.vue'
|
|
|
|
|
|
import {
|
|
|
- Ref, computed, onMounted, ref, watch
|
|
|
+ Ref, computed, onMounted, onUnmounted, ref, watch
|
|
|
} from 'vue'
|
|
|
import Echart from '@/components/chart.vue'
|
|
|
import MaintenanceDynamicsService from '../services/maintenanceDynamics.Service'
|
|
|
@@ -722,12 +722,33 @@ getMaintenanceDetail()
|
|
|
|
|
|
watch(() => leftContent.value.bottom.range, getMaintenanceDetail)
|
|
|
|
|
|
+const statisticsType = ref(1)
|
|
|
function selectDatechange(type: any) {
|
|
|
+ statisticsType.value = type
|
|
|
getMaintenanceStatistics(type)
|
|
|
}
|
|
|
onMounted(() => {
|
|
|
selectDatechange(1)
|
|
|
})
|
|
|
+
|
|
|
+const timer = setInterval(() => {
|
|
|
+ getBusLineDetailAll()
|
|
|
+ getMaintenanceStatistics(statisticsType.value)
|
|
|
+
|
|
|
+ getMaintenanceCarOperate()
|
|
|
+ getMaintenanceCarStatus()
|
|
|
+
|
|
|
+ getMaintenanceRidingDistance()
|
|
|
+ getMaintenanceLocationNum()
|
|
|
+ getMaintenanceConsumption()
|
|
|
+
|
|
|
+ getMaintenanceCheckupProblem()
|
|
|
+ getMaintenanceImplementation()
|
|
|
+}, 5 * 1000)
|
|
|
+
|
|
|
+onUnmounted(() => {
|
|
|
+ clearInterval(timer)
|
|
|
+})
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|