瀏覽代碼

坐席调整,上下班时间调整,大屏修改

duhongyu 6 年之前
父節點
當前提交
6ce5c0f473

+ 8 - 1
codegit/CallCenterApi/CallCenterApi.BLL/T_Sys_SeatGroup.cs

@@ -52,12 +52,19 @@ namespace CallCenterApi.BLL
52 52
         /// <summary>
53 53
         /// 得到一个对象实体
54 54
         /// </summary>
55
+        public CallCenterApi.Model.T_Sys_SeatGroup GetModel(string F_ZXZCode)
56
+        {
57
+
58
+            return dal.GetModel(F_ZXZCode);
59
+        }
60
+        /// <summary>
61
+        /// 得到一个对象实体
62
+        /// </summary>
55 63
         public CallCenterApi.Model.T_Sys_SeatGroup GetModel(int F_ZXZID)
56 64
         {
57 65
 
58 66
             return dal.GetModel(F_ZXZID);
59 67
         }
60
-
61 68
         /// <summary>
62 69
         /// 获得数据列表
63 70
         /// </summary>

+ 27 - 2
codegit/CallCenterApi/CallCenterApi.DAL/T_Sys_SeatGroup.cs

@@ -162,6 +162,31 @@ namespace CallCenterApi.DAL
162 162
                 return false;
163 163
             }
164 164
         }
165
+        /// <summary>
166
+        /// 得到一个对象实体
167
+        /// </summary>
168
+        public CallCenterApi.Model.T_Sys_SeatGroup GetModel(string F_ZXZCode)
169
+        {
170
+
171
+            StringBuilder strSql = new StringBuilder();
172
+            strSql.Append("select  top 1 F_ZXZID,F_ZXZCode,F_ZXZName,F_IVRKey,F_WHBDKey,F_WHWDKey,F_ZXAtt,F_Des,F_CreateTime,F_CreateBy,F_CreateByName ,F_Region from T_Sys_SeatGroup ");
173
+            strSql.Append(" where F_ZXZCode=@F_ZXZCode");
174
+            SqlParameter[] parameters = {
175
+                    new SqlParameter("@F_ZXZCode", SqlDbType.NVarChar,50)
176
+            };
177
+            parameters[0].Value = F_ZXZCode;
178
+
179
+            CallCenterApi.Model.T_Sys_SeatGroup model = new CallCenterApi.Model.T_Sys_SeatGroup();
180
+            DataSet ds = DbHelperSQL.Query(strSql.ToString(), parameters);
181
+            if (ds.Tables[0].Rows.Count > 0)
182
+            {
183
+                return DataRowToModel(ds.Tables[0].Rows[0]);
184
+            }
185
+            else
186
+            {
187
+                return null;
188
+            }
189
+        }
165 190
 
166 191
 
167 192
         /// <summary>
@@ -257,7 +282,7 @@ namespace CallCenterApi.DAL
257 282
         public DataSet GetList(string strWhere)
258 283
         {
259 284
             StringBuilder strSql = new StringBuilder();
260
-            strSql.Append("select F_ZXZID,F_ZXZCode,F_ZXZName,F_IVRKey,F_WHBDKey,F_WHWDKey,F_ZXAtt,F_Des,F_CreateTime,F_CreateBy,F_CreateByName ");
285
+            strSql.Append("select F_ZXZID,F_ZXZCode,F_ZXZName,F_IVRKey,F_WHBDKey,F_WHWDKey,F_ZXAtt,F_Des,F_CreateTime,F_CreateBy,F_CreateByName,F_Region ");
261 286
             strSql.Append(" FROM T_Sys_SeatGroup ");
262 287
             if (strWhere.Trim() != "")
263 288
             {
@@ -277,7 +302,7 @@ namespace CallCenterApi.DAL
277 302
             {
278 303
                 strSql.Append(" top " + Top.ToString());
279 304
             }
280
-            strSql.Append(" F_ZXZID,F_ZXZCode,F_ZXZName,F_IVRKey,F_WHBDKey,F_WHWDKey,F_ZXAtt,F_Des,F_CreateTime,F_CreateBy,F_CreateByName ");
305
+            strSql.Append(" F_ZXZID,F_ZXZCode,F_ZXZName,F_IVRKey,F_WHBDKey,F_WHWDKey,F_ZXAtt,F_Des,F_CreateTime,F_CreateBy,F_CreateByName,F_Region ");
281 306
             strSql.Append(" FROM T_Sys_SeatGroup ");
282 307
             if (strWhere.Trim() != "")
283 308
             {

+ 86 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/customer/RegionCategoryController.cs

@@ -16,7 +16,23 @@ namespace CallCenterApi.Interface.Controllers.customer
16 16
     public class RegionCategoryController : BaseController
17 17
     {
18 18
         private BLL.T_RegionCategory regionBLL = new BLL.T_RegionCategory();
19
+        public ActionResult GetProvinces()
20
+        {
21
+          //  if (Request.IsAuthenticated)
22
+          //  {
23
+                list = new BLL.T_RegionCategory().GetModelList(" F_DeleteFlag=0 ");
24
+                var list_p = list.Where(x => x.F_ParentId == 0).ToList();
25
+                List<Model.TreeModel> modelList = BindTreeRegion (list_p, "0");
19 26
 
27
+                if (modelList != null)
28
+                {
29
+                    if (modelList.Count > 0)
30
+                        return Success("加载成功", modelList);
31
+                }
32
+                return Error("加载失败");
33
+          //  }
34
+          //  return NoToken("未知错误,请重新登录");
35
+        }
20 36
         /// <summary>
21 37
         /// 获取省市县乡镇
22 38
         /// </summary>
@@ -392,6 +408,76 @@ namespace CallCenterApi.Interface.Controllers.customer
392 408
         /// <param name="tab"></param>
393 409
         /// <param name="parentid"></param>
394 410
         /// <returns></returns>
411
+        private List<Model.TreeModel> BindTreeRegion(List<T_RegionCategory> tab, string parentid)
412
+        {
413
+            if (tab.Count > 0)
414
+            {
415
+                List<Model.TreeModel> modelList = new List<Model.TreeModel>(tab.Count);
416
+                for (int i = 0; i < tab.Count; i++)
417
+                {
418
+                    Model.TreeModel model = new Model.TreeModel();
419
+                    int F_RegionId = tab[i].F_RegionId;
420
+                    string currentID = tab[i].F_RegionId.ToString();//当前功能ID
421
+                    model.id = currentID;
422
+                    model.IconCls = "";//图标
423
+                    if (tab[i].F_Layer != null)
424
+                    {
425
+                        model.headerid = int.Parse(tab[i].F_Layer.ToString());
426
+                    }
427
+                    model.text = tab[i].F_RegionName;
428
+                    var tab2 = list.Where(x => x.F_ParentId == F_RegionId).OrderByDescending(x => x.F_Sort).ToList();
429
+                    if (tab2.Count >0)
430
+                    {
431
+                        model.children = BindRegion(tab2, currentID);
432
+                    }
433
+                    modelList.Add(model);
434
+                }
435
+                return modelList;
436
+            }
437
+            else
438
+            {
439
+                return null;
440
+            }
441
+        }
442
+        /// <summary>
443
+        /// tree  树形地市
444
+        /// </summary>
445
+        /// <param name="tab"></param>
446
+        /// <param name="parentid"></param>
447
+        /// <returns></returns>
448
+        private List<Model.TreeModel> BindRegion(List<T_RegionCategory> tab, string parentid)
449
+        {
450
+            if (tab.Count > 0)
451
+            {
452
+                List<Model.TreeModel> modelList = new List<Model.TreeModel>(tab.Count);
453
+                for (int i = 0; i < tab.Count; i++)
454
+                {
455
+                    Model.TreeModel model = new Model.TreeModel();
456
+                    int F_RegionId = tab[i].F_RegionId;
457
+                    string currentID = tab[i].F_RegionId.ToString();//当前功能ID
458
+                    model.id = currentID;
459
+                    model.IconCls = "";//图标
460
+                    if (tab[i].F_Layer != null)
461
+                    {
462
+                        model.headerid = int.Parse(tab[i].F_Layer.ToString());
463
+                    }
464
+                    model.text = tab[i].F_RegionName;
465
+                    var tab2 = list.Where(x => x.F_ParentId == F_RegionId).OrderByDescending(x => x.F_Sort).ToList();
466
+                    modelList.Add(model);
467
+                }
468
+                return modelList;
469
+            }
470
+            else
471
+            {
472
+                return null;
473
+            }
474
+        }
475
+        /// <summary>
476
+        /// tree  树形地市
477
+        /// </summary>
478
+        /// <param name="tab"></param>
479
+        /// <param name="parentid"></param>
480
+        /// <returns></returns>
395 481
         private List<Model.TreeModel> BindTree(List<T_RegionCategory> tab, string parentid)
396 482
         {
397 483
             if (tab.Count > 0)

+ 11 - 1
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/report/WOReportController.cs

@@ -2098,6 +2098,7 @@ question, int page = 1, int limit = 10)
2098 2098
         public class Complainthandling
2099 2099
         {
2100 2100
             public string name;
2101
+            public int  typeid;
2101 2102
             public int number;//数量
2102 2103
             public string ongesttime="0h";//用时最长
2103 2104
             public string minimumtime = "0h";//用时最短
@@ -2933,7 +2934,15 @@ question, int page = 1, int limit = 10)
2933 2934
             string Queststr = "";
2934 2935
             if (questionName!="")
2935 2936
             {
2936
-                Queststr = " select * from T_Wo_QuestionManage where F_IsDelete=0 and F_Label in(3) and F_QuestionName='" + questionName+"'";
2937
+                try
2938
+                {
2939
+                    Queststr = " select * from T_Wo_QuestionManage where F_IsDelete=0 and F_Label in(3) and F_Id='" + questionName + "'";
2940
+                }
2941
+                catch
2942
+                {
2943
+                    Queststr = " select * from T_Wo_QuestionManage where F_IsDelete=0 and F_Label in(3) and F_QuestionName='" + questionName + "'";
2944
+                }
2945
+               
2937 2946
             }
2938 2947
             else
2939 2948
             {
@@ -2997,6 +3006,7 @@ question, int page = 1, int limit = 10)
2997 3006
                     List<float> timehource = new List<float>();
2998 3007
                     Complainthandling model = new Complainthandling();
2999 3008
                     model.name = categorylist[i].F_QuestionName;
3009
+                    model .typeid= categorylist[i].F_Id ;
3000 3010
                     model.number = 0;
3001 3011
                     int Overdue = 0;
3002 3012
                     int EndOverdue = 0;

+ 6 - 3
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/tel/WorkcalendarController.cs

@@ -189,7 +189,7 @@ namespace CallCenterApi.Interface.Controllers.tel
189 189
                     {
190 190
                         foreach (var iv in GroupIDList)
191 191
                         {
192
-                            Model.T_Sys_SeatGroup sm = new BLL.T_Sys_SeatGroup().GetModel(int.Parse(iv));
192
+                            Model.T_Sys_SeatGroup sm = new BLL.T_Sys_SeatGroup().GetModel(iv);
193 193
                             if (sm != null)
194 194
                             {
195 195
                                 if (msg!="")
@@ -204,7 +204,7 @@ namespace CallCenterApi.Interface.Controllers.tel
204 204
                             }
205 205
                         }
206 206
                     }
207
-                    it.F_GroupCode = msg;
207
+                    it.F_GroupCodeName = msg;
208 208
                     WorkTimes.Add(it);
209 209
                 }
210 210
                
@@ -222,9 +222,12 @@ namespace CallCenterApi.Interface.Controllers.tel
222 222
                 {
223 223
                     BLL.T_Sys_WorkTimes dBLL = new BLL.T_Sys_WorkTimes();
224 224
                     Model.T_Sys_WorkTimes dModel = dBLL.GetModel(int.Parse(id.Trim()));
225
+                    List<Model.T_Sys_WorkTimes> t_Sys_WorkTimes = new List<Model.T_Sys_WorkTimes>();
226
+                    t_Sys_WorkTimes.Add(dModel);
227
+                    List<Model.T_Sys_WorkTimes> Input = modeltooip(t_Sys_WorkTimes);
225 228
                     if (dModel != null)
226 229
                     {
227
-                        res = Success("获取成功", dModel);
230
+                        res = Success("获取成功", Input[0]);
228 231
                     }
229 232
                     else
230 233
                     {

+ 0 - 3
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkOrderNewController.cs

@@ -3612,7 +3612,6 @@ namespace CallCenterApi.Interface.Controllers.workorder
3612 3612
                             {
3613 3613
                                 return Error("生产批次号错误,生产日期不能大于当前时间!");
3614 3614
                             }
3615
-
3616 3615
                         }
3617 3616
                         catch
3618 3617
                         {
@@ -4953,7 +4952,6 @@ namespace CallCenterApi.Interface.Controllers.workorder
4953 4952
             {
4954 4953
                 string usercode = CurrentUser.UserData.F_UserCode;
4955 4954
                 Model.T_Sys_UserAccount ua = sysUserAccountBll.GetModel(userId);
4956
-
4957 4955
                 #region 添加验证判断
4958 4956
                 if (!(input.F_Type > 0 && input.F_Type < 5))
4959 4957
                     return Error("工单类型错误!");
@@ -4972,7 +4970,6 @@ namespace CallCenterApi.Interface.Controllers.workorder
4972 4970
                             {
4973 4971
                                 return Error("生产批次号错误,生产日期不能大于当前时间!");
4974 4972
                             }
4975
-
4976 4973
                         }
4977 4974
                         catch
4978 4975
                         {

+ 4 - 0
codegit/CallCenterApi/CallCenterApi.Model/T_Sys_WorkTimes.cs

@@ -67,6 +67,10 @@ namespace CallCenterApi.Model
67 67
             set { _f_holidayscode = value; }
68 68
             get { return _f_holidayscode; }
69 69
         }
70
+        public string F_GroupCodeName
71
+        {
72
+            get;set;
73
+        }
70 74
         /// <summary>
71 75
         /// 坐席组
72 76
         /// </summary>