|
|
@@ -554,7 +554,8 @@ namespace CallCenterApi.Interface.Controllers.tel
|
|
554
|
554
|
#endregion
|
|
555
|
555
|
|
|
556
|
556
|
#region 服务水平
|
|
557
|
|
- string sql1 = "select isnull(SUM(case when isnull(RingLongTime,0)<=20 and Callstate='1' then 1 else 0 end),0) as InTime,isnull(SUM(case when RingLongTime>20 and Callstate='1' then 1 else 0 end),0) as Delay,isnull(SUM(case when Callstate='1' then 1 else 0 end),0) as total from T_Call_CallRecords where calltype=0 and BeginTime BETWEEN '" + starttime + "' AND '" + endtime + "'";
|
|
|
557
|
+ //string sql1 = "select isnull(SUM(case when isnull(RingLongTime,0)<=20 and Callstate='1' then 1 else 0 end),0) as InTime,isnull(SUM(case when RingLongTime>20 and Callstate='1' then 1 else 0 end),0) as Delay,isnull(SUM(case when Callstate='1' then 1 else 0 end),0) as total from T_Call_CallRecords where calltype=0 and BeginTime BETWEEN '" + starttime + "' AND '" + endtime + "'";
|
|
|
558
|
+ string sql1 = "select isnull(SUM(case when isnull(RingLongTime,0)<=5 and Callstate='1' then 1 else 0 end),0) as InTime,isnull(SUM(case when RingLongTime>5 and Callstate='1' then 1 else 0 end),0) as Delay,isnull(SUM(case when Callstate='1' then 1 else 0 end),0) as total from T_Call_CallRecords where calltype=0 and BeginTime BETWEEN '" + starttime + "' AND '" + endtime + "'";
|
|
558
|
559
|
DataRow dr1 = dtnew.NewRow();
|
|
559
|
560
|
DataSet ds1 = DbHelperSQL.Query(sql1);
|
|
560
|
561
|
if (ds1 != null && ds1.Tables.Count > 0)
|
|
|
@@ -568,10 +569,12 @@ namespace CallCenterApi.Interface.Controllers.tel
|
|
568
|
569
|
if (totalnum == 0)
|
|
569
|
570
|
{ totalnum = 1; }
|
|
570
|
571
|
//添加呼入20s内接通数据
|
|
|
572
|
+ //添加呼入5s内接通数据
|
|
571
|
573
|
dr1["num"] = intime;
|
|
572
|
574
|
dr1["percent"] = Math.Round(Convert.ToDecimal(intime) / totalnum * 100, 2).ToString() + "%";
|
|
573
|
575
|
dtnew.Rows.Add(dr1);
|
|
574
|
576
|
//添加呼入非20s内接通数据
|
|
|
577
|
+ //添加呼入非5s内接通数据
|
|
575
|
578
|
dr1 = dtnew.NewRow();
|
|
576
|
579
|
dr1["num"] = delay;
|
|
577
|
580
|
dr1["percent"] = Math.Round(Convert.ToDecimal(delay) / totalnum * 100, 2).ToString() + "%";
|