From 7b9049d62d646420f06e14e9374bf7cee8d50e40 Mon Sep 17 00:00:00 2001 From: zhouxin Date: Tue, 21 May 2024 13:39:02 +0800 Subject: [PATCH] * Fix bug #49913. --- module/metric/model.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/metric/model.php b/module/metric/model.php index 18649dbd28..fb8def5d2b 100755 --- a/module/metric/model.php +++ b/module/metric/model.php @@ -62,7 +62,7 @@ class metricModel extends model if(empty($result)) return array(); $scope = $metric->scope; - $dateType = $metric->dateType; + $dateType = $this->getDateTypeByCode($metric->code); if($scope != 'system') $objectPairs = $this->getPairsByScope($scope); $tableData = array(); @@ -628,7 +628,7 @@ class metricModel extends model protected function getMetricRecordDateField(object $metric): array { $dataFields = array(); - $dateType = $metric->dateType; + $dateType = $this->getDateTypeByCode($metric->code); if($dateType != 'nodate') $dataFields[] = 'year'; if($dateType == 'month') $dataFields[] = 'month';