duhongyu 4 lat temu
rodzic
commit
004d2de36b

+ 55 - 6
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/WebChart/InfoNewController.cs

@@ -490,7 +490,7 @@ namespace CallCenterApi.Interface.Controllers.WebChart
490 490
         /// 获取当日问题分类受理量
491 491
         /// </summary>
492 492
         /// <returns></returns>
493
-        public ActionResult GetKeyCountByNow(int pid = 38)
493
+        public ActionResult GetKeyCountByNow(int pid = 38 )
494 494
         {
495 495
             var date = DateTime.Now;
496 496
             string sql = $" select F_Key keyid,count(1) count from dbo.T_Bus_WorkOrder where F_IsDelete=0 and F_CreateTime>='{date.ToString("yyyy-MM-dd")} 00:00:00' group by F_Key ";
@@ -584,12 +584,61 @@ namespace CallCenterApi.Interface.Controllers.WebChart
584 584
                 RedisHelper.StringSet("InfoNewGetAreaCount", obj.ToJson(), new TimeSpan(0, 5, 0));
585 585
                 return Content(obj.ToJson());
586 586
             }
587
-
588
-           
589
-          
590 587
         }
591
-
592
-
588
+        /// <summary>
589
+        /// 获取当日问题分类受理量
590
+        /// </summary>
591
+        /// <returns></returns>
592
+        public ActionResult GetMapByNow(int type=0,string areaid = "")
593
+        {
594
+            if (RedisHelper.StringGet("InfoNewMapByNow" + type+ areaid) != null)
595
+            {
596
+                Task.Run(() =>
597
+                {
598
+                    Dictionary<string, string> paras = new Dictionary<string, string>();
599
+                    var ob = DbHelperSQL.RunProcedure("P_MapByNow", paras, "MapByNow").Tables[0];
600
+                    paras.Add("@type", type.ToString());
601
+                    RedisHelper.KeyDelete("InfoNewMapByNow" + type + areaid);
602
+                    RedisHelper.StringSet("InfoNewMapByNow" + type + areaid, ob.ToJson(), new TimeSpan(0, 5, 0));
603
+                });
604
+                return Content(RedisHelper.StringGet("InfoNewMapByNow" + type + areaid).ToString());
605
+            }
606
+            else
607
+            {
608
+                Dictionary<string, string> paras = new Dictionary<string, string>();
609
+                var obj = DbHelperSQL.RunProcedure("P_MapByNow", paras, "MapByNow").Tables[0];
610
+                RedisHelper.StringSet("InfoNewMapByNow" + type + areaid, obj.ToJson(), new TimeSpan(0, 5, 0));
611
+                return Content(obj.ToJson());
612
+            }
613
+        }
614
+        /// <summary>
615
+        /// 获取办理情况三级
616
+        /// </summary>
617
+        /// <param name="date"></param>
618
+        /// <param name="isdc"></param>
619
+        /// <returns></returns>
620
+        public ActionResult GetHandleCount( int type=0)
621
+        {
622
+            if (RedisHelper.StringGet("InfoNewHandleCount"+ type) != null)
623
+            {
624
+                Task.Run(() =>
625
+                {
626
+                    Dictionary<string, string> paras = new Dictionary<string, string>();
627
+                    var ob = DbHelperSQL.RunProcedure("P_Handle", paras, "Handle").Tables[0];
628
+                    paras.Add("@type", type.ToString());
629
+                    RedisHelper.KeyDelete("InfoNewHandleCount"+ type);
630
+                    RedisHelper.StringSet("InfoNewHandleCount"+ type, ob.ToJson(), new TimeSpan(0, 5, 0));
631
+                });
632
+                return Content(RedisHelper.StringGet("InfoNewHandleCount"+ type).ToString());
633
+            }
634
+            else
635
+            {
636
+                Dictionary<string, string> paras = new Dictionary<string, string>();
637
+                var obj = DbHelperSQL.RunProcedure("P_Handle", paras, "Handle").Tables[0];
638
+                RedisHelper.StringSet("InfoNewHandleCount"+ type, obj.ToJson(), new TimeSpan(0, 5, 0));
639
+                return Content(obj.ToJson());
640
+            }
641
+        }
593 642
         /// <summary>
594 643
         /// 获取平均办理时长
595 644
         /// </summary>

+ 1 - 1
CallCenterCommon/CallCenter.QuartzService/SatisfactionClose.cs

@@ -19,7 +19,7 @@ namespace CallCenter.QuartzService
19 19
         private readonly CallCenterApi.BLL.T_Bus_WorkOrder  workorder = new CallCenterApi.BLL.T_Bus_WorkOrder();
20 20
         private void MyWork_DoWork(object sender, EventArgs e)
21 21
         {
22
-            string sql = "and F_WorkState = 6 and F_IsSms = 1  and F_IsDelete = 0 and(datediff(hh, (select top 1  RecvTime  from T_SMS_RecvSMS where   Content = '您反映的诉求已办理完成,请前往安阳政务服务官网(https://zwfw.anyang.gov.cn),登录后查看办结结果并对办理情况进行评价,谢谢' and CallerNum = b.F_CusPhone and F_Name = b.F_WorkOrderId order by    RecvTime desc), GETDATE()) >= 15) and F_DealTime is not null";
22
+            string sql = "and F_WorkState = 6 and F_IsSms = 1  and F_IsDelete = 0 and(datediff(dd, (select top 1  RecvTime  from T_SMS_RecvSMS where   Content = '您反映的诉求已办理完成,请前往安阳政务服务官网(https://zwfw.anyang.gov.cn),登录后查看办结结果并对办理情况进行评价,谢谢' and CallerNum = b.F_CusPhone and F_Name = b.F_WorkOrderId order by    RecvTime desc), GETDATE()) >= 15) and F_DealTime is not null";
23 23
             DataTable dt = new DataTable();
24 24
             int recordCount = 0;
25 25
               dt = CallCenterApi.BLL.PagerBLL.GetListPager(