瀏覽代碼

超时时限,短信推送

duhongyu 5 年之前
父節點
當前提交
7dca7c40fc

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

@@ -2751,7 +2751,7 @@ question, int page = 1, int limit = 10)
2751 2751
         /// <returns></returns>
2752 2752
         private bool TimeforOver(int id)
2753 2753
         {
2754
-            var itemlasts = itembll.GetModelList("  F_WoID=" + id + " order by F_ID desc");
2754
+            var itemlasts = itembll.GetModelList("  F_WoID=" + id );
2755 2755
             string time1 = "", time2 = ""; int x = 0, y = 0;
2756 2756
             float time = 0;
2757 2757
             if (itemlasts.Count > 0)

+ 63 - 4
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/weixin/WxLoginController.cs

@@ -1760,6 +1760,60 @@ namespace CallCenterApi.Interface.Controllers.weixin
1760 1760
         /// 查询工单详情
1761 1761
         /// </summary>
1762 1762
         [WechatActionFilter]
1763
+        public ActionResult GetCustomDetails(string OpenId, int id)
1764
+        {
1765
+            if (!string.IsNullOrEmpty(OpenId))
1766
+            {
1767
+                if (id <= 0)
1768
+                {
1769
+                    return Error("请输入正确的id");
1770
+                }
1771
+                DataTable FileUrl = new DataTable();
1772
+                var list = new List<Model.T_Wo_WorkOrder>();
1773
+                var model = woBLL.GetModel(id);
1774
+                if (model != null)
1775
+                    list.Add(model);
1776
+                var itemlasts = itembll.GetModelList("  F_WoID=" + +id + " ");
1777
+                ; var configfj = new BLL.T_Sys_SystemConfig().GetModelList(" F_ParamCode='FileUrlPath' ").FirstOrDefault();
1778
+                if (!string.IsNullOrEmpty(model.F_Files))
1779
+                {
1780
+                    FileUrl = GetFileData(model.F_Files, configfj.F_ParamValue);
1781
+                }
1782
+                var ua = userAccountBLL.GetModelList(" F_WxOpenId='" + OpenId + "'").FirstOrDefault();
1783
+                if (list.Count > 0)
1784
+                {
1785
+                    List<WorkOrderNewInput> Input = modeltooip(list, ua);
1786
+                    if (Input != null)
1787
+                    {
1788
+                        var obj = new
1789
+                        {
1790
+                            state = "success",
1791
+                            message = "成功",
1792
+                            rows = Input,
1793
+                            FileUrl,
1794
+                            total = itemlasts,
1795
+                        };
1796
+
1797
+                        return Content(obj.ToJson());
1798
+                    }
1799
+                    else
1800
+                    {
1801
+                        return Error("没有查询到此工单");
1802
+                    }
1803
+                }
1804
+                else
1805
+                    return Error("没有查询到此工单");
1806
+
1807
+            }
1808
+            else
1809
+            {
1810
+                return Error("无操作权限!");
1811
+            }
1812
+        }
1813
+        /// <summary>
1814
+        /// 查询工单详情
1815
+        /// </summary>
1816
+        [WechatActionFilter]
1763 1817
         public ActionResult GetDetails(string OpenId, int id)
1764 1818
         {
1765 1819
             if (!string.IsNullOrEmpty(OpenId))
@@ -2995,7 +3049,7 @@ namespace CallCenterApi.Interface.Controllers.weixin
2995 3049
                 model.F_MaterialID = input.F_MaterialID.ToString();//物料编码为11为纯数字
2996 3050
             }
2997 3051
             model.F_Source = input.F_Source.ToString();//工单来源
2998
-            model.F_WxOpenId = input.F_WxOpenId;
3052
+          
2999 3053
             model.F_Type = input.F_Type.ToString();//工单类型:咨询及需求、投诉、抽检、其他(其它手动输入别的点选)
3000 3054
             model.F_CusName = input.F_CusName;//客户姓名
3001 3055
             model.F_CusPhone = input.F_CusPhone;//客户电话
@@ -3041,7 +3095,7 @@ namespace CallCenterApi.Interface.Controllers.weixin
3041 3095
             model.F_CJ_Tonnage = input.F_CJ_Tonnage;//抽检-抽检吨数
3042 3096
             model.F_CJ_BagNo = input.F_CJ_BagNo;//抽检-抽检袋数
3043 3097
             model.F_CJ_Outlay = input.F_CJ_Outlay;//抽检-公关费用金额:单位元】
3044
-                                                  //     model.F_VisitRemarks = input.F_VisitRemarks;//回访备注
3098
+            model.F_WxOpenId = input.F_WxOpenId;                                    //     model.F_VisitRemarks = input.F_VisitRemarks;//回访备注
3045 3099
             if (!string.IsNullOrEmpty(input.F_BatchNumber))
3046 3100
             {
3047 3101
                 if (type == 1)
@@ -3565,6 +3619,8 @@ namespace CallCenterApi.Interface.Controllers.weixin
3565 3619
         public bool AssignWO(Model.T_Sys_UserAccount nowUser, Model.T_Wo_WorkOrder model, WorkOrderNewInput input, string cont, string F_Files, int clbm = 0, int clid = 0, int overtime = 0, int sms = 0, int isApprovalp = 0, int hclbm = 0, int hclid = 0, string creat = "",int  isbl=0)
3566 3620
         {
3567 3621
 
3622
+            if (model.F_limit > 0)
3623
+                overtime = model.F_limit;
3568 3624
             string smscont = "";
3569 3625
             if (model.F_Type == "1")
3570 3626
             {
@@ -3701,7 +3757,8 @@ namespace CallCenterApi.Interface.Controllers.weixin
3701 3757
                 //工单完结要更新工单的状态
3702 3758
                 //   model.F_DealBy = touser;
3703 3759
                 model.F_State = wostate;
3704
-                model.F_limit = overtime;
3760
+                if (model.F_limit == 0)
3761
+                    model.F_limit = overtime;
3705 3762
                 if (!string.IsNullOrEmpty(F_Files))
3706 3763
                 {
3707 3764
                     if (!string .IsNullOrEmpty(model.F_Files))
@@ -3907,7 +3964,7 @@ namespace CallCenterApi.Interface.Controllers.weixin
3907 3964
         /// <returns></returns>
3908 3965
         private bool TimeforOver(int id)
3909 3966
         {
3910
-            var itemlasts = itembll.GetModelList("  F_WoID=" + id + " order by F_ID desc");
3967
+            var itemlasts = itembll.GetModelList("  F_WoID=" + id );
3911 3968
             string time1 = "", time2 = ""; int x = 0, y = 0;
3912 3969
             float time = 0;
3913 3970
             if (itemlasts.Count > 0)
@@ -4598,6 +4655,8 @@ namespace CallCenterApi.Interface.Controllers.weixin
4598 4655
                         }
4599 4656
                     }
4600 4657
                 }
4658
+                if (!string.IsNullOrEmpty(model.F_WxOpenId))
4659
+                    sendwxmsg(model, model.F_WxOpenId, nowUser, "处理");
4601 4660
                 #endregion
4602 4661
                 #endregion
4603 4662
                 return true;

+ 12 - 4
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkOrderNewController.cs

@@ -4678,7 +4678,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
4678 4678
         /// <returns></returns>
4679 4679
         private float TimeToOver(int id, int limit)
4680 4680
         {
4681
-            var itemlasts = itembll.GetModelList("  F_ItemType=" + (int)EnumItemType.deal + " and  F_WoID=" + id + "order by F_ID desc ");
4681
+            var itemlasts = itembll.GetModelList("  F_ItemType=" + (int)EnumItemType.deal + " and  F_WoID=" + id );
4682 4682
             string time1 = "", time2 = ""; int x = 0, y = 0;
4683 4683
             if (itemlasts.Count > 0)
4684 4684
             {
@@ -4751,7 +4751,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
4751 4751
         /// <returns></returns>
4752 4752
         private bool  TimeforOver(int id)
4753 4753
         {
4754
-            var itemlasts = itembll.GetModelList("  F_WoID=" + id + " order by F_ID desc");
4754
+            var itemlasts = itembll.GetModelList("  F_WoID=" + id );
4755 4755
            // var itemlasts = itembll.GetModelList("  F_ItemType=" + (int)EnumItemType.deal + " and  F_WoID=" + id + " ");
4756 4756
             string  time1="", time2="" ;int x=0, y=0;
4757 4757
             float  time = 0;
@@ -6483,6 +6483,8 @@ namespace CallCenterApi.Interface.Controllers.workorder
6483 6483
                     if (lastUser != null && !string.IsNullOrEmpty(lastUser.F_WxOpenId))
6484 6484
                         sendwxmsg(model, lastUser.F_WxOpenId, nowUser, opt);
6485 6485
                 }
6486
+                if (!string.IsNullOrEmpty(model.F_WxOpenId))
6487
+                    sendwxmsg(model, model.F_WxOpenId, nowUser, "完结");
6486 6488
                 #endregion
6487 6489
                 #endregion
6488 6490
                 return true;
@@ -6599,7 +6601,9 @@ namespace CallCenterApi.Interface.Controllers.workorder
6599 6601
                           sendwxmsg(model, cusmodel.F_WxOpenId, nowUser, opt);
6600 6602
                       }
6601 6603
                    }
6602
-               }
6604
+                   if (!string .IsNullOrEmpty(model.F_WxOpenId))
6605
+                    sendwxmsg(model, model.F_WxOpenId, nowUser, "处理");
6606
+                }
6603 6607
                 #endregion
6604 6608
                 #endregion
6605 6609
                 return true;
@@ -6742,6 +6746,8 @@ namespace CallCenterApi.Interface.Controllers.workorder
6742 6746
         /// </summary>
6743 6747
         public bool AssignWO(Model.T_Sys_UserAccount nowUser, Model.T_Wo_WorkOrder model, WorkOrderNewInput input, string cont, string F_Files, int clbm = 0, int clid = 0, int  overtime = 0, int sms = 0, int isApprovalp = 0, int hclbm = 0, int hclid = 0, string creat = "",int isbl=0)
6744 6748
         {
6749
+            if (model.F_limit > 0)
6750
+                overtime = model.F_limit;
6745 6751
             string smscont = "";
6746 6752
             if (model.F_Type == "1")
6747 6753
             {
@@ -6880,7 +6886,8 @@ namespace CallCenterApi.Interface.Controllers.workorder
6880 6886
                 //工单完结要更新工单的状态
6881 6887
              //   model.F_DealBy = touser;
6882 6888
                 model.F_State = wostate;
6883
-                model.F_limit  = overtime ;
6889
+                if (model.F_limit==0)
6890
+                    model.F_limit  = overtime;
6884 6891
                 //处理内容
6885 6892
                 if (!string.IsNullOrEmpty(cont))
6886 6893
                     model.F_DealContent += cont + ";";
@@ -6973,6 +6980,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
6973 6980
             catch { }
6974 6981
             #endregion
6975 6982
         }
6983
+
6976 6984
     }
6977 6985
 }
6978 6986
 public class WorkOrdeDeptment