Просмотр исходного кода

通话记录调整
修改用户无法修改坐席组名称BUG

yuqian лет назад: 8
Родитель
Сommit
e62166c04b

+ 3 - 0
CallCenterApi/CallCenterApi.BLL/T_Sys_Department.cs

@@ -130,6 +130,9 @@ namespace CallCenterApi.BLL
130 130
                 {
131 131
                     model = new Model.T_Sys_DepartmentLevel();
132 132
                     model.DeptId = row["F_DeptId"] == DBNull.Value ? 0 : Convert.ToInt32(row["F_DeptId"]);
133
+                    model.ParentId = row["F_ParentId"] == DBNull.Value ? 0 : Convert.ToInt32(row["F_ParentId"]);
134
+                    model.DeptName = row["F_DeptName"] == DBNull.Value ? "" : row["F_DeptName"].ToString();
135
+                    model.DeptCode = row["F_DeptCode"] == DBNull.Value ? "" : row["F_DeptCode"].ToString();
133 136
                     model.Layer = row["F_Layer"] == DBNull.Value ? 0 : Convert.ToInt32(row["F_Layer"]);
134 137
                     model.Level = row["lvl"] == DBNull.Value ? 0 : Convert.ToInt32(row["lvl"]);
135 138
                     modelList.Add(model);

+ 8 - 8
CallCenterApi/CallCenterApi.DAL/T_Call_CallRecords.cs

@@ -413,7 +413,7 @@ namespace CallCenterApi.DAL
413 413
         {
414 414
 
415 415
             StringBuilder strSql = new StringBuilder();
416
-            strSql.Append("select  top 1 * from T_Call_CallRecords WHTH(NOLOCK)");
416
+            strSql.Append("select  top 1 * from T_Call_CallRecords WITH(NOLOCK)");
417 417
             strSql.Append(" where CallRecordsId=@CallRecordsId");
418 418
             SqlParameter[] parameters = {
419 419
                     new SqlParameter("@CallRecordsId", SqlDbType.Int,4)
@@ -671,7 +671,7 @@ namespace CallCenterApi.DAL
671 671
         {
672 672
             StringBuilder strSql = new StringBuilder();
673 673
             strSql.Append("select * ");
674
-            strSql.Append(" FROM T_Call_CallRecords WHTH(NOLOCK)");
674
+            strSql.Append(" FROM T_Call_CallRecords WITH(NOLOCK)");
675 675
             if (strWhere.Trim() != "")
676 676
             {
677 677
                 strSql.Append(" where " + strWhere);
@@ -691,7 +691,7 @@ namespace CallCenterApi.DAL
691 691
                 strSql.Append(" top " + Top.ToString());
692 692
             }
693 693
             strSql.Append(" * ");
694
-            strSql.Append(" FROM T_Call_CallRecords WHTH(NOLOCK)");
694
+            strSql.Append(" FROM T_Call_CallRecords WITH(NOLOCK)");
695 695
             if (strWhere.Trim() != "")
696 696
             {
697 697
                 strSql.Append(" where " + strWhere);
@@ -706,7 +706,7 @@ namespace CallCenterApi.DAL
706 706
         public int GetRecordCount(string strWhere)
707 707
         {
708 708
             StringBuilder strSql = new StringBuilder();
709
-            strSql.Append("select count(1) FROM T_Call_CallRecords WHTH(NOLOCK)");
709
+            strSql.Append("select count(1) FROM T_Call_CallRecords WITH(NOLOCK)");
710 710
             if (strWhere.Trim() != "")
711 711
             {
712 712
                 strSql.Append(" where " + strWhere);
@@ -912,7 +912,7 @@ namespace CallCenterApi.DAL
912 912
         public Model.T_Call_CallRecords GetModelByTelphone(string CallNumber)
913 913
         {
914 914
             StringBuilder strSql = new StringBuilder();
915
-            strSql.Append("select  top 1 * from T_Call_CallRecords  WHTH(NOLOCK) ");
915
+            strSql.Append("select  top 1 * from T_Call_CallRecords  WITH(NOLOCK) ");
916 916
             strSql.Append(" where CallNumber=@CallNumber order by BeginTime desc");
917 917
             SqlParameter[] parameters = {
918 918
                     new SqlParameter("@CallNumber", SqlDbType.VarChar,100)
@@ -936,7 +936,7 @@ namespace CallCenterApi.DAL
936 936
         public Model.T_Call_CallRecords GetModelByCallId(string CallId)
937 937
         {
938 938
             StringBuilder strSql = new StringBuilder();
939
-            strSql.Append("select  top 1 * from T_Call_CallRecords  WHTH(NOLOCK) ");
939
+            strSql.Append("select  top 1 * from T_Call_CallRecords  WITH(NOLOCK) ");
940 940
             strSql.Append(" where CallId=@CallId order by BeginTime desc");
941 941
             SqlParameter[] parameters = {
942 942
                     new SqlParameter("@CallId", SqlDbType.VarChar,50)
@@ -957,7 +957,7 @@ namespace CallCenterApi.DAL
957 957
         public Model.T_Call_CallRecords GetModelByRecordId(string CallId)
958 958
         {
959 959
             StringBuilder strSql = new StringBuilder();
960
-            strSql.Append("select  top 1 * from T_Call_CallRecords  WHTH(NOLOCK) ");
960
+            strSql.Append("select  top 1 * from T_Call_CallRecords  WITH(NOLOCK) ");
961 961
             strSql.Append(" where CallRecordsId=@CallRecordsId order by BeginTime desc");
962 962
             SqlParameter[] parameters = {
963 963
                     new SqlParameter("@CallRecordsId", SqlDbType.Int)
@@ -1026,7 +1026,7 @@ namespace CallCenterApi.DAL
1026 1026
             strSql.Append(" case isdeal when 0 then '未处理' when 1 then '已处理' else '注销' end isdeals, ");
1027 1027
             strSql.Append(" usercode, (select F_UserName from T_Sys_UserAccount where F_UserCode= c.UserCode) username, ");
1028 1028
             strSql.Append(" begintime, talkstarttime, talkendtime, endtime, talklongtime");
1029
-            strSql.Append(" FROM T_Call_CallRecords c   WHTH(NOLOCK) ");
1029
+            strSql.Append(" FROM T_Call_CallRecords c   WITH(NOLOCK) ");
1030 1030
             if (strWhere.Trim() != "")
1031 1031
             {
1032 1032
                 strSql.Append(" where " + strWhere);

+ 1 - 0
CallCenterApi/CallCenterApi.DAL/T_Sys_UserAccount.cs

@@ -165,6 +165,7 @@ namespace CallCenterApi.DAL
165 165
             strSql.Append("F_DeptCode=@F_DeptCode,");
166 166
             strSql.Append("F_WXNo=@F_WXNo,");
167 167
             strSql.Append("F_SeartGroupID=@F_SeartGroupID,");
168
+            strSql.Append("F_SeartGroup=@F_SeartGroup,");
168 169
             strSql.Append("F_StartTime1=@F_StartTime1,");
169 170
             strSql.Append("F_StartTime2=@F_StartTime2, ");
170 171
             strSql.Append("F_EndTime1=@F_EndTime1, ");

+ 1 - 1
CallCenterApi/CallCenterApi.DAL/T_Sys_WorkTimes.cs

@@ -217,7 +217,7 @@ namespace CallCenterApi.DAL
217 217
         public DataSet GetList(string strWhere)
218 218
         {
219 219
             StringBuilder strSql = new StringBuilder();
220
-            strSql.Append("select F_ID,F_WorkStartTimes,F_WorkEndTimes,F_TimeName,F_Remark,F_DeptId ");
220
+            strSql.Append("select F_WorkStartTimes,F_WorkEndTimes,F_TimeName,F_Remark,F_DeptId ");
221 221
             strSql.Append(" FROM T_Sys_WorkTimes ");
222 222
             if (strWhere.Trim() != "")
223 223
             {

+ 2 - 1
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/CallCenterApi.Interface.csproj

@@ -283,8 +283,9 @@
283 283
     </Compile>
284 284
     <Compile Include="Models\Common\FormsPrincipal.cs" />
285 285
     <Compile Include="Models\Common\ListBase.cs" />
286
-    <Compile Include="Models\Dto\AutoCallResordDto.cs" />
286
+    <Compile Include="Models\Dto\AutoCallRecordDto.cs" />
287 287
     <Compile Include="Models\Dto\CallPlan.cs" />
288
+    <Compile Include="Models\Dto\CallRecordDto.cs" />
288 289
     <Compile Include="Models\Dto\CategoryDto.cs" />
289 290
     <Compile Include="Models\Dto\CustomerDto.cs" />
290 291
     <Compile Include="Models\Dto\ModuleInfoDto.cs" />

+ 76 - 51
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/tel/CallrecordsController.cs

@@ -2,6 +2,7 @@
2 2
 using CallCenterApi.Common;
3 3
 using CallCenterApi.DB;
4 4
 using CallCenterApi.Interface.Controllers.Base;
5
+using CallCenterApi.Interface.Models.Dto;
5 6
 using System;
6 7
 using System.Collections.Generic;
7 8
 using System.Data;
@@ -17,6 +18,7 @@ namespace CallCenterApi.Interface.Controllers.tel
17 18
     public class CallrecordsController : BaseController
18 19
     {
19 20
         private readonly BLL.T_Sys_Department deptBLL = new BLL.T_Sys_Department();
21
+        private readonly BLL.T_Call_CallRecords callRecordBLL = new BLL.T_Call_CallRecords();
20 22
         //获取通话记录列表
21 23
         public ActionResult GetList(string phone, string usercode)
22 24
         {
@@ -40,12 +42,12 @@ namespace CallCenterApi.Interface.Controllers.tel
40 42
                 string strpagesize = RequestString.GetQueryString("pagesize");
41 43
                 int pagesize = 10;
42 44
 
43
-                //17=系统管理员,36=客服,37=组长,38=组员,39=业主,40=话务员,41=客服主管,43=分公司市场部主任,45=业务稽核,46=集团客户部,
44
-                //47 =网络部,48=市场部经理,50=业务支撑中心,51=市场部,52=客户服务中心,53=总经理,54=副总经理,55=业务负责人,56=投诉处理员,57=基础业务主管,
45
+                //36 = 旗区分公司客户经理,37 = 组长,38 = 组员,39 = 分公司社会渠道业主,40 = 分公司自营渠道话务员,41 = 分公司客服主管,43 = 分公司市场部主任,
46
+                //45 = 分公司业务稽核,46 = 市公司集团客户部,47 = 市公司网络部,48 = 市场部客服中心经理,50 = 市公司业务支撑中心,51 = 市公司业务负责人,52 = 客户服务中心,
47
+                //53 = 分公司总经理,54 = 分公司副总经理,55 = 分公司业务负责人,56 = 分公司投诉处理员,57 = 分公司基础业务主管,58 = 社会渠道话务员,60 = 市公司市场部经理,
45 48
 
46
-                //var deptCodeObj = DbHelperSQL.GetSingle($"with cte(F_DeptId,F_ParentId,F_DeptCode,F_Layer,lvl) as( select F_DeptId,F_ParentId,F_DeptCode,F_Layer,0 lvl from T_Sys_Department where F_DeptId={deptid} union all select dept.F_DeptId,dept.F_ParentId,dept.F_DeptCode,dept.F_Layer,lvl+1 from T_Sys_Department dept inner join cte on dept.F_DeptId = cte.F_ParentId) select top 1 F_DeptId,F_DeptCode from  cte where F_Layer=1 order by lvl");
47
-                //var deptCurrentCompany = deptList.Where(x => x.Layer == 1).OrderByDescending(x => x.Level).FirstOrDefault();
48
-                //var deptModelCode = deptCodeObj?.ToString() ?? "";
49
+                var depts = deptBLL.DataTableToListForLevel(DbHelperSQL.Query($"with cte(F_DeptId,F_DeptName,F_ParentId,F_DeptCode,F_Layer,lvl) as( select F_DeptId,F_DeptName,F_ParentId,F_DeptCode,F_Layer,0 lvl from T_Sys_Department union all select dept.F_DeptId,dept.F_DeptName,dept.F_ParentId,dept.F_DeptCode,dept.F_Layer,lvl+1 from T_Sys_Department dept inner join cte on dept.F_DeptId = cte.F_ParentId) select F_DeptId,F_ParentId,F_DeptName,F_DeptCode,F_Layer,lvl from  cte ").Tables[0]);
50
+                var deptCompany = depts.Where(x => x.Layer == 1).OrderBy(x => x.Level).FirstOrDefault();
49 51
                 if (roleid != 0)
50 52
                 {
51 53
                     if (roleid != 17)
@@ -53,14 +55,13 @@ namespace CallCenterApi.Interface.Controllers.tel
53 55
                         //各分公司
54 56
                         if (deptCode.Replace("|0|1|", "").Length > 0)
55 57
                         {
56
-                            if (roleid == 36 || roleid == 38 || roleid == 40)
58
+                            if (roleid == 36 || roleid == 38 || roleid == 40 || roleid == 58)
57 59
                             {
58
-                                usercode = CurrentUser.UserData.F_UserCode;
59
-                                sql += " and UserCode='" + usercode + "'";
60
+                                sql += " and UserCode='" + CurrentUser.UserData.F_UserCode + "'";
60 61
                             }
61 62
                             else
62 63
                             {
63
-                                sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptID in (select F_DeptId from T_Sys_Department where F_DeptCode like '" + deptCode + "%')) ";
64
+                                sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptID in (select F_DeptId from T_Sys_Department where F_DeptCode like '" + (deptCompany?.DeptCode ?? deptCode) + "%')) ";
64 65
                             }
65 66
                         }
66 67
                         //总公司
@@ -124,21 +125,23 @@ namespace CallCenterApi.Interface.Controllers.tel
124 125
                 }
125 126
                 int recordCount = 0;
126 127
                 dt = BLL.PagerBLL.GetListPager(
127
-                    "T_Call_CallRecords left join T_Sys_UserAccount ON T_Sys_UserAccount.F_UserCode=T_Call_CallRecords.UserCode  left join T_Sys_Department ON T_Sys_UserAccount.F_DeptId=T_Sys_Department.F_DeptId ",
128
+                    "T_Call_CallRecords",
128 129
                     "CallRecordsId",
129
-                    "*,T_Sys_UserAccount.F_UserName,T_Sys_Department.F_DeptName,(SELECT F_DeptName from T_Sys_Department t where t.F_DeptId=T_Sys_Department.F_ParentId) as ParentName ",
130
+                    "*",
130 131
                     sql,
131 132
                     "ORDER BY CallRecordsId desc",
132 133
                     pagesize,
133 134
                     pageindex,
134 135
                     true,
135 136
                     out recordCount);
136
-
137
+                var callRecordList = callRecordBLL.DataTableToList(dt);
137 138
                 var config = new BLL.T_Sys_SystemConfig().GetModelList(" F_ParamCode='PlayPath' ").FirstOrDefault();
138 139
                 var users = new BLL.T_Sys_UserAccount().GetModelList("");
139
-                foreach (DataRow dr in dt.Rows)
140
+                var deptList = deptBLL.DataTableToListForLevel(DbHelperSQL.Query("select F_DeptId,F_ParentId,F_DeptName,F_DeptCode,F_Layer,0 lvl FROM T_Sys_Department ").Tables[0]);
141
+                var resList = new List<CallRecordDto>();
142
+                foreach (var item in callRecordList)
140 143
                 {
141
-                    string path = dr["FilePath"] != null ? dr["FilePath"].ToString() : "";
144
+                    string path = item.FilePath ?? "";
142 145
                     if (path != "" && config != null && !string.IsNullOrEmpty(config.F_ParamValue))
143 146
                     {
144 147
                         var ym = config.F_ParamValue;
@@ -146,26 +149,58 @@ namespace CallCenterApi.Interface.Controllers.tel
146 149
                         {
147 150
                             ym = ym.Substring(0, ym.Length - 1);
148 151
                         }
149
-                        dr["FilePath"] = ym + path.Substring(path.IndexOf(':') + 1).Replace('\\', '/');
152
+                        item.FilePath = ym + path.Substring(path.IndexOf(':') + 1).Replace('\\', '/');
150 153
                     }
151
-                    string ucode = dr["UserCode"] != null ? dr["UserCode"].ToString() : "";
152
-                    string uname = dr["UserName"] != null ? dr["UserName"].ToString() : "";
153
-                    if (ucode != "")
154
+                    string ucode = item.UserCode ?? "";
155
+                    string uname = item.UserName ?? "";
156
+                    Model.T_Sys_UserAccount uu = null;
157
+                    uu = users.Where(u => u.F_UserCode.Equals(item.UserCode)).FirstOrDefault();
158
+                    if (uu != null)
159
+                        item.UserName = uu.F_UserName;
160
+
161
+                    Model.T_Sys_DepartmentLevel deptCategory = new Model.T_Sys_DepartmentLevel();
162
+                    Model.T_Sys_DepartmentLevel channelCategory = new Model.T_Sys_DepartmentLevel();
163
+                    if (uu != null)
154 164
                     {
155
-                        if (uname == "")
156
-                        {
157
-                            var uu = users.Where(u => u.F_UserCode.Equals(ucode)).FirstOrDefault();
158
-                            if (uu != null)
159
-                                dr["UserName"] = uu.F_UserName;
160
-                        }
165
+                        var depId = uu.F_DeptId;
166
+                        channelCategory = deptList.SingleOrDefault(x => x.Layer == 3 && x.DeptId == depId);
167
+                        deptCategory = deptList.SingleOrDefault(x => x.Layer == 2 && (channelCategory?.ParentId ?? 0) == x.DeptId);
168
+
169
+
161 170
                     }
171
+
172
+
173
+                    resList.Add(new CallRecordDto
174
+                    {
175
+                        CallId = item.CallId,
176
+                        CallNumber = item.CallNumber,
177
+                        FilePath = item.FilePath,
178
+                        CallType = item.CallType,
179
+                        DealType = item.DealType,
180
+                        CallState = item.CallState,
181
+                        IsDeal = item.IsDeal,
182
+                        UserCode = item.UserCode,
183
+                        UserName = item.UserName,
184
+                        BeginTime = item.BeginTime,
185
+                        RingStartTime = item.RingStartTime,
186
+                        TalkStartTime = item.TalkStartTime,
187
+                        TalkEndTime = item.TalkEndTime,
188
+                        RingLongTime = item.RingLongTime,
189
+                        TalkLongTime = item.TalkLongTime,
190
+                        CompanyName = deptCompany?.DeptName ?? "",
191
+                        CategoryName = deptCategory?.DeptName ?? "",
192
+                        ChannelName = channelCategory?.DeptName ?? "",
193
+                    });
194
+
162 195
                 }
163 196
 
197
+
198
+
164 199
                 var obj = new
165 200
                 {
166 201
                     state = "success",
167 202
                     message = "成功",
168
-                    rows = dt,
203
+                    rows = resList,
169 204
                     total = recordCount
170 205
                 };
171 206
 
@@ -195,43 +230,28 @@ namespace CallCenterApi.Interface.Controllers.tel
195 230
                 string endtime = HttpUtility.UrlDecode(RequestString.GetQueryString("endtime"));
196 231
                 string dept = HttpUtility.UrlDecode(RequestString.GetQueryString("dept"));
197 232
 
233
+
234
+                //36 = 旗区分公司客户经理,37 = 组长,38 = 组员,39 = 分公司社会渠道业主,40 = 分公司自营渠道话务员,41 = 分公司客服主管,43 = 分公司市场部主任,
235
+                //45 = 分公司业务稽核,46 = 市公司集团客户部,47 = 市公司网络部,48 = 市场部客服中心经理,50 = 市公司业务支撑中心,51 = 市公司业务负责人,52 = 客户服务中心,
236
+                //53 = 分公司总经理,54 = 分公司副总经理,55 = 分公司业务负责人,56 = 分公司投诉处理员,57 = 分公司基础业务主管,58 = 社会渠道话务员,60 = 市公司市场部经理,
237
+
238
+                var depts = deptBLL.DataTableToListForLevel(DbHelperSQL.Query($"with cte(F_DeptId,F_DeptName,F_ParentId,F_DeptCode,F_Layer,lvl) as( select F_DeptId,F_DeptName,F_ParentId,F_DeptCode,F_Layer,0 lvl from T_Sys_Department union all select dept.F_DeptId,dept.F_DeptName,dept.F_ParentId,dept.F_DeptCode,dept.F_Layer,lvl+1 from T_Sys_Department dept inner join cte on dept.F_DeptId = cte.F_ParentId) select F_DeptId,F_ParentId,F_DeptName,F_DeptCode,F_Layer,lvl from  cte ").Tables[0]);
239
+                var deptCompany = depts.Where(x => x.Layer == 1).OrderBy(x => x.Level).FirstOrDefault();
240
+
198 241
                 if (roleid != 0)
199 242
                 {
200 243
                     if (roleid != 17)
201 244
                     {
202
-                        //if (deptcode.IndexOf("|533|") > 0)
203
-                        //{
204
-                        //    sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptId=" + deptid + ")";
205
-                        //}
206
-                        //if (deptcode.IndexOf("|531|") > 0)
207
-                        //{
208
-                        //    if (roleid == 32)
209
-                        //    {
210
-                        //        usercode = CurrentUser.UserData.F_UserCode;
211
-                        //        sql += " and UserCode='" + usercode + "'";
212
-                        //    }
213
-                        //    else
214
-                        //    {
215
-                        //        sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptID in (select F_DeptId from T_Sys_Department where F_DeptCode like '" + deptcode + "%')) ";
216
-                        //    }
217
-                        //}
218
-                        //else
219
-                        //{
220
-                        //    sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptId=" + deptid + ")";
221
-                        //}
222
-
223
-
224 245
                         //各分公司
225 246
                         if (deptCode.Replace("|0|1|", "").Length > 0)
226 247
                         {
227
-                            if (roleid == 36 || roleid == 38 || roleid == 40)
248
+                            if (roleid == 36 || roleid == 38 || roleid == 40 || roleid == 50)
228 249
                             {
229
-                                usercode = CurrentUser.UserData.F_UserCode;
230
-                                sql += " and UserCode='" + usercode + "'";
250
+                                sql += " and UserCode='" + CurrentUser.UserData.F_UserCode + "'";
231 251
                             }
232 252
                             else
233 253
                             {
234
-                                sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptID in (select F_DeptId from T_Sys_Department where F_DeptCode like '" + deptCode + "%')) ";
254
+                                sql += " and UserCode in (select F_UserCode from T_Sys_UserAccount where F_DeptID in (select F_DeptId from T_Sys_Department where F_DeptCode like '" + (deptCompany?.DeptCode ?? deptCode) + "%')) ";
235 255
                             }
236 256
                         }
237 257
                     }
@@ -291,6 +311,11 @@ namespace CallCenterApi.Interface.Controllers.tel
291 311
             string[] ccc = {
292 312
                    "电话号码","呼叫方向","呼叫状态","是否处理","坐席工号","坐席姓名",
293 313
                   "开始时间","通话开始时间","通话结束时间","结束时间","通话时长"
314
+                   //号码、呼叫方向、呼叫状态、坐席工号、坐席姓名、
315
+                  //分机号、所属公司、分类、渠道名称、
316
+                  //开始通话时间、结束通话时间、通话时长。
317
+
318
+
294 319
             };
295 320
             return ccc;
296 321
         }

+ 1 - 1
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/tel/WorkcalendarController.cs

@@ -342,7 +342,7 @@ namespace CallCenterApi.Interface.Controllers.tel
342 342
         {
343 343
             var deptId = CurrentUser.UserData.F_DeptId;
344 344
             var list = workTimesBLL.DataTableToList(workTimesBLL.GetList($" F_DeptId={deptId} ").Tables[0]);
345
-            var isOnDutyTime = false;
345
+            var isOnDutyTime = true;
346 346
             var now = DateTime.Now.TimeOfDay;
347 347
             foreach (var item in list)
348 348
             {

CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Dto/AutoCallResordDto.cs → CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Dto/AutoCallRecordDto.cs


+ 238 - 0
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Dto/CallRecordDto.cs

@@ -0,0 +1,238 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Web;
5
+
6
+namespace CallCenterApi.Interface.Models.Dto
7
+{
8
+    public class CallRecordDto
9
+    {
10
+        /// <summary>
11
+        /// 呼叫编号
12
+        /// </summary>
13
+        public string CallId { get; set; }
14
+
15
+        /// <summary>
16
+        /// 来电号码
17
+        /// </summary>
18
+        public string CallNumber { get; set; }
19
+        /// <summary>
20
+        /// 客户id
21
+        /// </summary>
22
+        public string CusId { get; set; }
23
+        /// <summary>
24
+        /// 客户编号
25
+        /// </summary>
26
+        public string CusCode { get; set; }
27
+        /// <summary>
28
+        /// 呼叫类型,0呼入1呼出
29
+        /// </summary>
30
+        public int? CallType { get; set; }
31
+        /// <summary>
32
+        /// 呼叫状态,0:未接通电话1已接通电话
33
+        /// </summary>
34
+        public int? CallState { get; set; }
35
+        /// <summary>
36
+        /// 处理方式0:IVR处理1骚扰电话2自助服务3转值班电话4留言5呼损6人工处理
37
+        /// </summary>
38
+        public int? DealType { get; set; }
39
+        /// <summary>
40
+        /// 开始时间
41
+        /// </summary>
42
+        public DateTime? BeginTime { get; set; }
43
+        /// <summary>
44
+        /// ivr开始时间
45
+        /// </summary>
46
+        public DateTime? IvrStartTime { get; set; }
47
+        /// <summary>
48
+        /// ivr结束时间
49
+        /// </summary>
50
+        public DateTime? IvrEndTime { get; set; }
51
+        /// <summary>
52
+        /// 振铃开始时间
53
+        /// </summary>
54
+        public DateTime? RingStartTime { get; set; }
55
+        /// <summary>
56
+        /// 振铃结束时间
57
+        /// </summary>
58
+        public DateTime? RingEndTime { get; set; }
59
+        /// <summary>
60
+        /// 通话开始时间
61
+        /// </summary>
62
+        public DateTime? TalkStartTime { get; set; }
63
+        /// <summary>
64
+        /// 通话结束时间
65
+        /// </summary>
66
+        public DateTime? TalkEndTime { get; set; }
67
+        /// <summary>
68
+        /// 结束时间
69
+        /// </summary>
70
+        public DateTime? EndTime { get; set; }
71
+        /// <summary>
72
+        /// 总时长(s)
73
+        /// </summary>
74
+        public int? LongTime { get; set; }
75
+        /// <summary>
76
+        /// IVR时长(s)
77
+        /// </summary>
78
+        public int? IvrLongTime { get; set; }
79
+        /// <summary>
80
+        /// 振铃时长(s)
81
+        /// </summary>
82
+        public int? RingLongTime { get; set; }
83
+        /// <summary>
84
+        /// 通话时长(s)
85
+        /// </summary>
86
+        public int? TalkLongTime { get; set; }
87
+        /// <summary>
88
+        /// 坐席id
89
+        /// </summary>
90
+        public int? UserId { get; set; }
91
+        /// <summary>
92
+        /// 坐席工号
93
+        /// </summary>
94
+        public string UserCode { get; set; }
95
+        /// <summary>
96
+        /// 坐席姓名
97
+        /// </summary>
98
+        public string UserName { get; set; }
99
+        /// <summary>
100
+        /// 坐席分机号
101
+        /// </summary>
102
+        public string ExtNumber { get; set; }
103
+        /// <summary>
104
+        /// 用于获取录音的编号
105
+        /// </summary>
106
+        public string FilePath { get; set; }
107
+        /// <summary>
108
+        /// 是否录入工单
109
+        /// </summary>
110
+        public bool IsExitWorkOrder { get; set; }
111
+        /// <summary>
112
+        /// 是否处理0未处理1已处理2注销
113
+        /// </summary>
114
+        public int? IsDeal { get; set; }
115
+        /// <summary>
116
+        /// 操作类型,0正常1转移2三方通话
117
+        /// </summary>
118
+        public int? OperateType { get; set; }
119
+        /// <summary>
120
+        /// 操作目标
121
+        /// </summary>
122
+        public string OperateObject { get; set; }
123
+        /// <summary>
124
+        /// 操作时间
125
+        /// </summary>
126
+        public DateTime? OperateTime { get; set; }
127
+        /// <summary>
128
+        /// 备注
129
+        /// </summary>
130
+        public string Remark { get; set; }
131
+        /// <summary>
132
+        /// 满意度,1非常满意、2基本满意、3不满意
133
+        /// </summary>
134
+        public int? MYD { get; set; }
135
+        /// <summary>
136
+        /// IVR中选择的业务类型
137
+        /// </summary>
138
+        public int? BusinessType { get; set; }
139
+        /// <summary>
140
+        /// 
141
+        /// </summary>
142
+        public string Location { get; set; }
143
+        /// <summary>
144
+        /// 来电自增Id
145
+        /// </summary>
146
+        public int CallRecordsId { get; set; }
147
+        /// <summary>
148
+		/// 排队开始时间
149
+		/// </summary>
150
+		public DateTime? WaitStartTime { get; set; }
151
+        /// <summary>
152
+        /// 排队结束时间
153
+        /// </summary>
154
+        public DateTime? WaitEndTime { get; set; }
155
+        /// <summary>
156
+        /// 排队时长
157
+        /// </summary>
158
+        public int? WaitLongTime { get; set; }
159
+        /// <summary>
160
+        /// 未接通状态(0其他、1坐席未登录、2坐席忙、3振铃)
161
+        /// </summary>
162
+        public int? NoCallState { get; set; }
163
+        /// <summary>
164
+        /// 与工作时间间隔秒数
165
+        /// </summary>
166
+        public int? WorkTimesDiff { get; set; }
167
+        /// <summary>
168
+        /// 质检状态(0未质检、1已质检)
169
+        /// </summary>
170
+        public int? F_QCState { get; set; }
171
+        /// <summary>
172
+        /// 质检分值
173
+        /// </summary>
174
+        public decimal? F_QCScore { get; set; }
175
+        /// <summary>
176
+        /// 质检备注
177
+        /// </summary>
178
+        public string F_QCRemark { get; set; }
179
+        /// <summary>
180
+        /// 质检人Id
181
+        /// </summary>
182
+        public int? F_QCUserId { get; set; }
183
+        /// <summary>
184
+        /// 质检人名称
185
+        /// </summary>
186
+        public string F_QCUserName { get; set; }
187
+        /// <summary>
188
+        /// 质检时间
189
+        /// </summary>
190
+        public DateTime? F_QCTime { get; set; }
191
+        /// <summary>
192
+        /// 是否推荐
193
+        /// </summary>
194
+        public int? F_QCIsSelect { get; set; }
195
+        /// <summary>
196
+        /// 
197
+        /// </summary>
198
+        public int? F_HJJGId { get; set; }
199
+        /// <summary>
200
+        /// 
201
+        /// </summary>
202
+        public string F_HJJGName { get; set; }
203
+        /// <summary>
204
+        /// 质检客服-存在的问题
205
+        /// </summary>
206
+        public string F_QCQuestion { get; set; }
207
+        /// <summary>
208
+        /// 质检客服-修改意见
209
+        /// </summary>
210
+        public string F_QCAdvise { get; set; }
211
+        /// <summary>
212
+		/// 拨号类型:0:拨号外呼;1:95005回访外呼;2:电销回访外呼
213
+		/// </summary>
214
+		public string TaskType { get; set; }
215
+        /// <summary>
216
+        /// 回访的电话ID
217
+        /// </summary>
218
+        public string TaskPhoneID { get; set; }
219
+        /// <summary>
220
+        /// 回访记录编号:GUID编号唯一
221
+        /// </summary>
222
+        public string TaskID { get; set; }
223
+
224
+        /// <summary>
225
+        /// 所属公司名称
226
+        /// </summary>
227
+        public string CompanyName { get; set; }
228
+        /// <summary>
229
+        /// 所属公司下分类名称
230
+        /// </summary>
231
+        public string CategoryName { get; set; }
232
+        /// <summary>
233
+        /// 所属公司下分类下渠道名称
234
+        /// </summary>
235
+        public string ChannelName { get; set; }
236
+
237
+    }
238
+}

+ 13 - 0
CallCenterApi/CallCenterApi.Model/T_Sys_DepartmentLevel.cs

@@ -13,6 +13,18 @@ namespace CallCenterApi.Model
13 13
         /// </summary>
14 14
         public int DeptId { get; set; }
15 15
         /// <summary>
16
+        /// 父级部门ID
17
+        /// </summary>
18
+        public int ParentId { get; set; }
19
+        /// <summary>
20
+        /// 部门Name
21
+        /// </summary>
22
+        public string DeptName { get; set; }
23
+        /// <summary>
24
+        /// 部门Code
25
+        /// </summary>
26
+        public string DeptCode { get; set; }
27
+        /// <summary>
16 28
         /// 级别
17 29
         /// </summary>
18 30
         public int Layer { get; set; }
@@ -21,5 +33,6 @@ namespace CallCenterApi.Model
21 33
         /// </summary>
22 34
         public int Level { get; set; }
23 35
 
36
+
24 37
     }
25 38
 }