tangjiang 10 months ago
parent
commit
7aa6b72f24
2 changed files with 4 additions and 4 deletions
  1. 2 2
      src/Hotline.Api/Controllers/TestController.cs
  2. 2 2
      src/Hotline/Orders/Order.cs

+ 2 - 2
src/Hotline.Api/Controllers/TestController.cs

@@ -229,7 +229,7 @@ public class TestController : BaseController
                 if (item.ActualHandleTime.HasValue)
                 {
                     var count = Math.Round((item.ActualHandleTime - item.CreationTime).Value.TotalSeconds);
-                    item.CreationTimeHandleDuration = count == 0 ? 1 : count;
+                    item.CreationTimeHandleDuration = count <= 0 ? 1 : count;
                 }
                 else
                     item.CreationTimeHandleDuration = 0;
@@ -237,7 +237,7 @@ public class TestController : BaseController
                 if (item.ActualHandleTime.HasValue && item.CenterToOrgTime.HasValue)
                 {
                     var count = Math.Round((item.ActualHandleTime - item.CenterToOrgTime).Value.TotalSeconds);
-                    item.CenterToOrgHandleDuration = count == 0 ? 1 : count;
+                    item.CenterToOrgHandleDuration = count <= 0 ? 1 : count;
                 }
                 else
                     item.CenterToOrgHandleDuration = 0;

+ 2 - 2
src/Hotline/Orders/Order.cs

@@ -1068,7 +1068,7 @@ namespace Hotline.Orders
             else
             {
                 var count = Math.Round((ActualHandleTime - CreationTime).Value.TotalSeconds);
-                CreationTimeHandleDuration = count == 0 ? 1 : count;
+                CreationTimeHandleDuration = count <= 0 ? 1 : count;
             }
 
         }
@@ -1081,7 +1081,7 @@ namespace Hotline.Orders
             if (ActualHandleTime.HasValue && CenterToOrgTime.HasValue)
             {
                 var count = Math.Round((ActualHandleTime - CenterToOrgTime).Value.TotalSeconds);
-                CenterToOrgHandleDuration = count == 0 ? 1 : count;
+                CenterToOrgHandleDuration = count <= 0 ? 1 : count;
             }
             else
                 CenterToOrgHandleDuration = 0;