protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         WOrderProcessRightJsonData right = WOrderProcessRightJsonData.GetWOrderProcessRightJsonData(Right);
         if (ValidateRight(right))
         {
             ucCustInfoView.CustID            = WOrderInfo.CBID_Value;
             ucCustInfoView.Telphone          = WOrderInfo.Phone_Value;
             ucCustInfoView.CanSeeTelImg      = true;
             ucWOrderBasicInfo.WOrderInfo     = WOrderInfo;
             ucWOrderBasicInfo.CustCategoryID = ucCustInfoView.CustType;
             ucWOrderBasicInfo.CanSeeTelImg   = true;
             CustTypeId = (int)ucCustInfoView.CustType;
             //审核+处理
             if (WOrderStatus == WorkOrderStatus.Pending ||
                 WOrderStatus == WorkOrderStatus.Untreated ||
                 WOrderStatus == WorkOrderStatus.Processing)
             {
                 var c = this.LoadControl("~/WOrderV2/UserControl/WOrderDealControl/WOrderProcess.ascx", this.OrderID, this.WOrderStatus);
                 this.ucPlaceHolder.Controls.Add(c);
             }
             //回访
             else if (WOrderStatus == WorkOrderStatus.Processed)
             {
                 var c = this.LoadControl("~/WOrderV2/UserControl/WOrderDealControl/WOrderReturnVisit.ascx", this.OrderID);
                 this.ucPlaceHolder.Controls.Add(c);
             }
         }
     }
 }
        /// 工单处理
        /// <summary>
        /// 工单处理
        /// </summary>
        /// <param name="flag"></param>
        /// <param name="msg"></param>
        /// <returns></returns>
        private string SaveProcess(ref bool flag, ref string msg)
        {
            try
            {
                WOrderProcessJsonData jsondata = WOrderProcessJsonData.GetWOrderProcessJsonData(JsonData);
                if (jsondata == null)
                {
                    flag = false;
                    msg  = "参数错误!";
                    return("");
                }
                WOrderInfoInfo             worderinfo = null;
                WOrderOperTypeEnum         oper       = WOrderOperTypeEnum.None;
                WOrderProcessRightJsonData right      = WOrderProcessRightJsonData.GetWOrderProcessRightJsonData(RightData);
                flag = BLL.WOrderProcess.Instance.ValidateWOrderProcessRight(OrderID, ref msg, ref oper, out worderinfo, right);
                if (flag == false)
                {
                    return("");
                }
                int loginuserid          = BLL.Util.GetLoginUserID();
                SysRightUserInfo sysinfo = BLL.EmployeeSuper.Instance.GetSysRightUserInfo(loginuserid);
                if (sysinfo == null)
                {
                    flag = false;
                    msg  = "获取不到当前登录人信息!";
                    return("");
                }
                //处理工单
                BLL.WOrderProcess.Instance.WOrderProcessMain(jsondata, sysinfo, oper, worderinfo);

                flag = true;
                msg  = "";
                return(BLL.Util.GetEnumOptText(typeof(WOrderOperTypeEnum), (int)oper));
            }
            catch (Exception ex)
            {
                WOrderInfo.ErrorToLog4("工单处理", ex);
                flag = false;
                msg  = ex.Message;
                return("");
            }
        }