Przeglądaj źródła

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

duhongyu 6 lat temu
rodzic
commit
6ce5c0f473

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

52
         /// <summary>
52
         /// <summary>
53
         /// 得到一个对象实体
53
         /// 得到一个对象实体
54
         /// </summary>
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
         public CallCenterApi.Model.T_Sys_SeatGroup GetModel(int F_ZXZID)
63
         public CallCenterApi.Model.T_Sys_SeatGroup GetModel(int F_ZXZID)
56
         {
64
         {
57
 
65
 
58
             return dal.GetModel(F_ZXZID);
66
             return dal.GetModel(F_ZXZID);
59
         }
67
         }
60
-
61
         /// <summary>
68
         /// <summary>
62
         /// 获得数据列表
69
         /// 获得数据列表
63
         /// </summary>
70
         /// </summary>

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

162
                 return false;
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
         /// <summary>
192
         /// <summary>
257
         public DataSet GetList(string strWhere)
282
         public DataSet GetList(string strWhere)
258
         {
283
         {
259
             StringBuilder strSql = new StringBuilder();
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
             strSql.Append(" FROM T_Sys_SeatGroup ");
286
             strSql.Append(" FROM T_Sys_SeatGroup ");
262
             if (strWhere.Trim() != "")
287
             if (strWhere.Trim() != "")
263
             {
288
             {
277
             {
302
             {
278
                 strSql.Append(" top " + Top.ToString());
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
             strSql.Append(" FROM T_Sys_SeatGroup ");
306
             strSql.Append(" FROM T_Sys_SeatGroup ");
282
             if (strWhere.Trim() != "")
307
             if (strWhere.Trim() != "")
283
             {
308
             {

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

16
     public class RegionCategoryController : BaseController
16
     public class RegionCategoryController : BaseController
17
     {
17
     {
18
         private BLL.T_RegionCategory regionBLL = new BLL.T_RegionCategory();
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
         /// <summary>
36
         /// <summary>
21
         /// 获取省市县乡镇
37
         /// 获取省市县乡镇
22
         /// </summary>
38
         /// </summary>
392
         /// <param name="tab"></param>
408
         /// <param name="tab"></param>
393
         /// <param name="parentid"></param>
409
         /// <param name="parentid"></param>
394
         /// <returns></returns>
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
         private List<Model.TreeModel> BindTree(List<T_RegionCategory> tab, string parentid)
481
         private List<Model.TreeModel> BindTree(List<T_RegionCategory> tab, string parentid)
396
         {
482
         {
397
             if (tab.Count > 0)
483
             if (tab.Count > 0)

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

2098
         public class Complainthandling
2098
         public class Complainthandling
2099
         {
2099
         {
2100
             public string name;
2100
             public string name;
2101
+            public int  typeid;
2101
             public int number;//数量
2102
             public int number;//数量
2102
             public string ongesttime="0h";//用时最长
2103
             public string ongesttime="0h";//用时最长
2103
             public string minimumtime = "0h";//用时最短
2104
             public string minimumtime = "0h";//用时最短
2933
             string Queststr = "";
2934
             string Queststr = "";
2934
             if (questionName!="")
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
             else
2947
             else
2939
             {
2948
             {
2997
                     List<float> timehource = new List<float>();
3006
                     List<float> timehource = new List<float>();
2998
                     Complainthandling model = new Complainthandling();
3007
                     Complainthandling model = new Complainthandling();
2999
                     model.name = categorylist[i].F_QuestionName;
3008
                     model.name = categorylist[i].F_QuestionName;
3009
+                    model .typeid= categorylist[i].F_Id ;
3000
                     model.number = 0;
3010
                     model.number = 0;
3001
                     int Overdue = 0;
3011
                     int Overdue = 0;
3002
                     int EndOverdue = 0;
3012
                     int EndOverdue = 0;

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

189
                     {
189
                     {
190
                         foreach (var iv in GroupIDList)
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
                             if (sm != null)
193
                             if (sm != null)
194
                             {
194
                             {
195
                                 if (msg!="")
195
                                 if (msg!="")
204
                             }
204
                             }
205
                         }
205
                         }
206
                     }
206
                     }
207
-                    it.F_GroupCode = msg;
207
+                    it.F_GroupCodeName = msg;
208
                     WorkTimes.Add(it);
208
                     WorkTimes.Add(it);
209
                 }
209
                 }
210
                
210
                
222
                 {
222
                 {
223
                     BLL.T_Sys_WorkTimes dBLL = new BLL.T_Sys_WorkTimes();
223
                     BLL.T_Sys_WorkTimes dBLL = new BLL.T_Sys_WorkTimes();
224
                     Model.T_Sys_WorkTimes dModel = dBLL.GetModel(int.Parse(id.Trim()));
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
                     if (dModel != null)
228
                     if (dModel != null)
226
                     {
229
                     {
227
-                        res = Success("获取成功", dModel);
230
+                        res = Success("获取成功", Input[0]);
228
                     }
231
                     }
229
                     else
232
                     else
230
                     {
233
                     {

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

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

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

67
             set { _f_holidayscode = value; }
67
             set { _f_holidayscode = value; }
68
             get { return _f_holidayscode; }
68
             get { return _f_holidayscode; }
69
         }
69
         }
70
+        public string F_GroupCodeName
71
+        {
72
+            get;set;
73
+        }
70
         /// <summary>
74
         /// <summary>
71
         /// 坐席组
75
         /// 坐席组
72
         /// </summary>
76
         /// </summary>