Browse Source

order 新增 AllDurationHour

xf 5 months ago
parent
commit
32884df7e2
2 changed files with 15 additions and 12 deletions
  1. 12 12
      src/Hotline.Share/Dtos/Order/OrderDto.cs
  2. 3 0
      src/Hotline/Orders/Order.cs

+ 12 - 12
src/Hotline.Share/Dtos/Order/OrderDto.cs

@@ -133,18 +133,18 @@ namespace Hotline.Share.Dtos.Order
         public double AllDuration { get; set; }
 
 
-        public string AllDurationHour => GetAllDurationHour();
-
-
-        public string GetAllDurationHour()
-        {
-            if (Status >= EOrderStatus.Filed && FiledTime.HasValue)
-            {
-                return Math.Round(Math.Round((FiledTime - CreationTime).Value.TotalSeconds) / 60 / 60, 2).ToString() + "小时";
-            }
-
-            return "-";
-        }
+        public string AllDurationHour { get; set; }
+
+        //
+        // public string GetAllDurationHour()
+        // {
+        //     if (Status >= EOrderStatus.Filed && FiledTime.HasValue)
+        //     {
+        //         return Math.Round(Math.Round((FiledTime - CreationTime).Value.TotalSeconds) / 60 / 60, 2).ToString() + "小时";
+        //     }
+        //
+        //     return "-";
+        // }
 
         /// <summary>
         /// 办结时长(秒) 归档时间-受理时间(工单创建时间)

+ 3 - 0
src/Hotline/Orders/Order.cs

@@ -456,6 +456,9 @@ namespace Hotline.Orders
 
         [SugarColumn(ColumnDescription = "全流程工作日时长")]
         public double? AllDurationWorkday { get; set; }
+        
+        
+        public string AllDurationHour { get; set; }
 
         /// <summary>
         /// 办理时间限制(如:24小时、7个工作日)