コード例 #1
0
ファイル: jipiaoUpdate.ascx.cs プロジェクト: windygu/bbl
        /// <summary>
        /// 提交事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void lbtn_submit_Click(object sender, EventArgs e)
        {
            //    DateTime date = DateTime.Parse(txt_date.Value);
            //    string leg = txt_Leg.Value;
            //    string gotime = txt_gotime.Value;
            //    string backLeg = txt_backLeg.Value;
            //    string backTime = txt_backTime.Value;
            //    string company = ddl_Com.SelectedValue;
            //    string PNG = txt_PNG.Value;
            //    decimal PiaoKuang = decimal.Parse(txt_PiaoKuang.Value);
            //    decimal dailifei = decimal.Parse( txt_DaiLiFei.Value);
            //    int pepoleNum = int.Parse( txt_Pepole.Value );
            //    decimal sumPrice = decimal.Parse(txt_SumPrice.Value);
            //    string Order = txt_Order.Value;
            //    for (int i = 0; i < Utils.GetFormValues("txt_code").Length; i++)
            //    {
            //        //do something...
            //    }
            EyouSoft.Model.TourStructure.TourBaseInfo mb = new EyouSoft.BLL.TourStructure.Tour().GetTourInfo(Utils.GetQueryStringValue("tourid"));
            if (mb != null)
            {
                if (!Utils.PlanIsUpdateOrDelete(mb.Status.ToString()))
                {
                    Response.Write("<script>alert('该团已提交财务,不能对它操作!');location.href=location.href;</script>");
                    return;
                }
            }
            UserInfo userInfo = null;
            bool     _IsLogin = EyouSoft.Security.Membership.UserProvider.IsUserLogin(out userInfo);

            EyouSoft.BLL.PlanStruture.PlaneTicket          bll   = new EyouSoft.BLL.PlanStruture.PlaneTicket();
            EyouSoft.Model.PlanStructure.TicketOutListInfo model = new EyouSoft.Model.PlanStructure.TicketOutListInfo();
            if (this.hideId.Value != "")
            {
                model = bll.GetTicketOutListModel(this.hideId.Value);
            }
            if (model != null)
            {
                model.CompanyID = cur_companyId;
                model.Notice    = Utils.GetFormValue("txt_Order");
                model.OperateID = userInfo.ID;
                model.Operator  = userInfo.ContactInfo.ContactName;
                model.PayType   = (EyouSoft.Model.EnumType.TourStructure.RefundType)Utils.GetInt(Utils.GetFormValue("sel_paytype"));
                model.PNR       = Utils.GetFormValue("txt_Pnr");
                model.Remark    = Utils.GetFormValue("textRemark");
                model.State     = EyouSoft.Model.EnumType.PlanStructure.TicketState.机票申请;
                model.TourId    = this.hideTourId.Value;

                IList <EyouSoft.Model.PlanStructure.TicketFlight> ltf = new
                                                                        List <EyouSoft.Model.PlanStructure.TicketFlight>();
                IList <EyouSoft.Model.PlanStructure.TicketKindInfo> ltki = new
                                                                           List <EyouSoft.Model.PlanStructure.TicketKindInfo>();
                for (int i = 0; i < Utils.GetFormValues("txt_date").Length; i++)
                {
                    EyouSoft.Model.PlanStructure.TicketFlight tf = new EyouSoft.Model.PlanStructure.TicketFlight();
                    tf.TicketTime    = Utils.GetFormValues("txt_time")[i];
                    tf.AireLine      = (EyouSoft.Model.EnumType.PlanStructure.FlightCompany)(Utils.GetInt(Utils.GetFormValues("sel_com")[i]));
                    tf.DepartureTime = Utils.GetDateTime(Utils.GetFormValues("txt_date")[i]);
                    tf.Discount      = Utils.GetDecimal(Utils.GetFormValues("txt_Discount")[i]);
                    tf.FligthSegment = Utils.GetFormValues("sel_Flight")[i];
                    ltf.Add(tf);
                }

                ////成人票款
                EyouSoft.Model.PlanStructure.TicketKindInfo tki = new EyouSoft.Model.PlanStructure.TicketKindInfo();
                tki.OilFee      = Utils.GetDecimal(Utils.GetFormValue("txt_shui"));
                tki.PeopleCount = Utils.GetInt(Utils.GetFormValue("txt_pepoleNum"));
                tki.Price       = Utils.GetDecimal(Utils.GetFormValue("txt_piaomianjia"));
                tki.TotalMoney  = Utils.GetDecimal(Utils.GetFormValue("txt_piaokuan"));
                tki.TicketType  = EyouSoft.Model.EnumType.PlanStructure.KindType.成人;
                if (config_Agency.HasValue && EyouSoft.Model.EnumType.CompanyStructure.AgencyFeeType.公式三 == config_Agency.Value)
                {
                    tki.OtherPrice  = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei"));
                    tki.Discount    = Utils.GetDecimal(Utils.GetFormValue("txt_Percent"), 100) / 100;
                    tki.AgencyPrice = 0;
                }
                else
                {
                    tki.OtherPrice  = 0;
                    tki.Discount    = 1;
                    tki.AgencyPrice = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei"));
                }
                ltki.Add(tki);
                ///////儿童票款
                EyouSoft.Model.PlanStructure.TicketKindInfo tkirt = new EyouSoft.Model.PlanStructure.TicketKindInfo();
                tkirt.AgencyPrice = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei2"));
                tkirt.OilFee      = Utils.GetDecimal(Utils.GetFormValue("txt_shui2"));
                tkirt.PeopleCount = Utils.GetInt(Utils.GetFormValue("txt_pepoleNum2"));
                tkirt.Price       = Utils.GetDecimal(Utils.GetFormValue("txt_piaomianjia2"));
                tkirt.TotalMoney  = Utils.GetDecimal(Utils.GetFormValue("txt_piaokuan2"));
                tkirt.TicketType  = EyouSoft.Model.EnumType.PlanStructure.KindType.儿童;
                tkirt.OtherPrice  = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei2"));
                tkirt.Discount    = Utils.GetDecimal(Utils.GetFormValue("txt_Percent2"), 100) / 100;
                ltki.Add(tkirt);
                ////
                model.Total = Utils.GetDecimal(Utils.GetFormValue("txt_SumPrice"));
                model.TicketKindInfoList = ltki;
                model.TicketFlightList   = ltf;
                EyouSoft.BLL.RouteStructure.Route routbll = new EyouSoft.BLL.RouteStructure.Route(userInfo);
                EyouSoft.BLL.TourStructure.Tour   tourbll = new EyouSoft.BLL.TourStructure.Tour(userInfo);

                model.RouteName = tourbll.GetTourInfo(Utils.GetQueryStringValue("tourId")).RouteName;

                IList <EyouSoft.Model.PlanStructure.TicketOutCustomerInfo> listorder = new List <EyouSoft.Model.PlanStructure.TicketOutCustomerInfo>();
                if (Utils.GetFormValues("chk_md").Length == 0)
                {
                    Utils.Show("请选择游客!");
                    return;
                }
                IList <EyouSoft.Model.TourStructure.TourOrderCustomer> listcus = new
                                                                                 List <EyouSoft.Model.TourStructure.TourOrderCustomer>();
                //for (int i = 0; i < Utils.GetFormValues("chk_md").Length; i++)
                //{
                //    EyouSoft.Model.PlanStructure.TicketOutCustomerInfo m = new EyouSoft.Model.PlanStructure.TicketOutCustomerInfo();
                //    EyouSoft.Model.TourStructure.TourOrderCustomer c = new EyouSoft.Model.TourStructure.TourOrderCustomer();

                //    c.ID = Utils.GetFormValues("chk_md")[i];
                //    c.VisitorName = Utils.GetFormValues("txt_name")[i];
                //    c.CradType = (EyouSoft.Model.EnumType.TourStructure.CradType)Utils.GetInt(Utils.GetFormValues("sel_cred")[i]);
                //    c.CradNumber = Utils.GetFormValues("txt_code")[i];
                //    m.UserId = Utils.GetFormValues("chk_md")[i];
                //    listorder.Add(m);
                //    listcus.Add(c);
                //}
                for (int i = 0; i < Utils.GetFormValues("chk_md").Length; i++)
                {
                    EyouSoft.Model.PlanStructure.TicketOutCustomerInfo m = new EyouSoft.Model.PlanStructure.TicketOutCustomerInfo();
                    EyouSoft.Model.TourStructure.TourOrderCustomer     c = new EyouSoft.Model.TourStructure.TourOrderCustomer();
                    c.ID = Utils.GetFormValues("chk_md")[i];
                    for (int j = 0; j < Utils.GetFormValues("txt_name").Length; j++)
                    {
                        if (c.ID == Utils.GetFormValues("hd_uid")[j])
                        {
                            c.VisitorName = Utils.GetFormValues("txt_name")[j];
                            c.CradType    = (EyouSoft.Model.EnumType.TourStructure.CradType)Utils.GetInt(Utils.GetFormValues("sel_cred")[j]);
                            c.CradNumber  = Utils.GetFormValues("txt_code")[j];
                            break;
                        }
                    }
                    m.UserId = Utils.GetFormValues("chk_md")[i];
                    listorder.Add(m);
                    listcus.Add(c);
                }
                model.CustomerInfoList          = listcus;
                model.TicketOutCustomerInfoList = listorder;

                //if (Utils.GetInt(Utils.GetQueryStringValue("type")) == 1)
                //{
                //    ///散拼计划机票计调
                //    model.TicketType = EyouSoft.Model.EnumType.PlanStructure.TicketType.订单申请机票;
                //}
                //else
                //{
                ///团队计划机票计调
                model.TicketType = EyouSoft.Model.EnumType.PlanStructure.TicketType.团队申请机票;
                //}
                //model.TicketOutId = "0";
                model.RegisterOperatorId = userInfo.ID;
                //售票处
                model.TicketOffice   = this.txtSalePlace.Value;
                model.TicketOfficeId = Utils.GetInt(this.hd_PiaoWuSuppId.Value);
                if (this.hideId.Value != "")
                {
                    //修改
                    model.TicketOutId = this.hideId.Value;

                    if (bll.UpdateTicketOutListModel(model))
                    {
                        Utils.ShowAndRedirect("修改成功!", Request.Url.ToString());
                    }
                    else
                    {
                        Utils.ShowAndRedirect("修改失败!", Request.Url.ToString());
                    }
                }
                else
                {
                    //添加
                    if (bll.addTicketOutListModel(model))
                    {
                        Utils.ShowAndRedirect("添加成功!", Request.Url.ToString());
                    }
                    else
                    {
                        Utils.ShowAndRedirect("添加失败!", Request.Url.ToString());
                    }
                }
            }
        }
コード例 #2
0
        protected void lbtnSave_Click1(object sender, EventArgs e)
        {
            #region 判断是否提交财务
            EyouSoft.Model.TourStructure.TourBaseInfo m = new EyouSoft.BLL.TourStructure.Tour().GetTourInfo(Utils.GetQueryStringValue("tourid"));
            if (m != null)
            {
                if (!Utils.PlanIsUpdateOrDelete(m.Status.ToString()))
                {
                    Response.Write("<script>alert('该团已提交财务,不能对它操作!');location.href=location.href;</script>");
                    return;
                }
            }
            #endregion
            string msg = "";
            string id  = Utils.GetQueryStringValue("id");
            if (checkData(ref msg))
            {
                EyouSoft.BLL.PlanStruture.PlaneTicket          bll   = new EyouSoft.BLL.PlanStruture.PlaneTicket();
                EyouSoft.Model.PlanStructure.TicketOutListInfo model = new EyouSoft.Model.PlanStructure.TicketOutListInfo();
                #region 航班,名单,票款
                #region 航班
                //航班列表长度
                int ariLength = Utils.GetFormValues("txtAirTime").Length;
                //客户列表长度
                int cusLength = Utils.GetFormValues("txtCusName").Length;
                System.Collections.Generic.IList <EyouSoft.Model.PlanStructure.TicketFlight> TicketFlightList = new
                                                                                                                System.Collections.Generic.List <EyouSoft.Model.PlanStructure.TicketFlight>();
                for (int i = 0; i < ariLength; i++)
                {
                    EyouSoft.Model.PlanStructure.TicketFlight cusModel = new EyouSoft.Model.PlanStructure.TicketFlight();
                    //航班日期
                    string txtAirTime = Utils.GetFormValues("txtAirTime")[i];
                    //航班线路
                    string selAirLine = Utils.GetFormValues("selAirLine")[i];
                    //航空公司
                    string selAirCompany = Utils.GetFormValues("SelAirCompany")[i];
                    //折扣
                    string txtZheKo = Utils.GetFormValues("txtZheKo")[i];
                    //航班日期
                    cusModel.DepartureTime = Utils.GetDateTime(txtAirTime);
                    //航班线路
                    cusModel.FligthSegment = selAirLine;
                    //航空公司
                    cusModel.AireLine = (EyouSoft.Model.EnumType.PlanStructure.FlightCompany)(Utils.GetInt(selAirCompany));
                    //折扣
                    cusModel.Discount   = Utils.GetDecimal(txtZheKo);
                    cusModel.TicketTime = Utils.GetFormValues("txt_hbh_date")[i];
                    //添加到航班列表
                    TicketFlightList.Add(cusModel);
                    cusModel = null;
                }
                //航班列表
                model.TicketFlightList = TicketFlightList;
                #endregion
                #region  单
                System.Collections.Generic.IList <EyouSoft.Model.PlanStructure.TicketOutCustomerInfo> TicketOutCustomerInfoList = new
                                                                                                                                  System.Collections.Generic.List <EyouSoft.Model.PlanStructure.TicketOutCustomerInfo>();
                for (int i = 0; i < cusLength; i++)
                {
                    EyouSoft.Model.PlanStructure.TicketOutCustomerInfo cusModel = new EyouSoft.Model.PlanStructure.TicketOutCustomerInfo();
                    //是否勾选
                    string cusID = "";
                    try
                    {
                        cusID = Utils.GetFormValues("chkOper")[i];
                    }
                    catch
                    {
                        continue;
                    }
                    //客户姓名
                    string txtCusName = Utils.GetFormValues("txtCusName")[i];
                    //客户证件类型
                    string selCardType = Utils.GetFormValues("SelCardType")[i];
                    //证件号码
                    string txtCardNumber = Utils.GetFormValues("txtCardNumber")[i];
                    cusModel.TicketOutId = id;
                    cusModel.UserId      = cusID;
                    //添加至客户列表
                    TicketOutCustomerInfoList.Add(cusModel);
                    cusModel = null;
                }
                //客户列表对应关系
                model.TicketOutCustomerInfoList = TicketOutCustomerInfoList;
                #endregion
                #region 票款
                System.Collections.Generic.IList <EyouSoft.Model.PlanStructure.TicketKindInfo> TicketKindInfoList = new
                                                                                                                    System.Collections.Generic.List <EyouSoft.Model.PlanStructure.TicketKindInfo>();
                EyouSoft.Model.PlanStructure.TicketKindInfo TicketKindInfoModel = new EyouSoft.Model.PlanStructure.TicketKindInfo();
                //成人票面价
                TicketKindInfoModel.Price = Utils.GetDecimal(this.txtAdultPrice.Value);
                //成人税/机建
                TicketKindInfoModel.OilFee = Utils.GetDecimal(this.txtAdultShui.Value);
                //成人人数
                TicketKindInfoModel.PeopleCount = Utils.GetInt(this.txtAdultCount.Value);
                //成人代理费
                TicketKindInfoModel.AgencyPrice = Utils.GetDecimal(this.txtAdultProxyPrice.Value);
                //成人票款
                TicketKindInfoModel.TotalMoney = Utils.GetDecimal(this.txtAdultSum.Value);
                //其它费用
                TicketKindInfoModel.OtherPrice = Utils.GetDecimal(this.txt_OtherMoney.Value);
                //百分比
                TicketKindInfoModel.Discount = Utils.GetDecimal(this.txt_Percent.Value, 100) / 100;
                //票款类型
                TicketKindInfoModel.TicketType = EyouSoft.Model.EnumType.PlanStructure.KindType.成人;
                TicketKindInfoModel.TicketId   = id;

                TicketKindInfoList.Add(TicketKindInfoModel);

                EyouSoft.Model.PlanStructure.TicketKindInfo TicketKindInfoModel1 = new EyouSoft.Model.PlanStructure.TicketKindInfo();
                //儿童票面价
                TicketKindInfoModel1.Price = Utils.GetDecimal(this.txtChildPrice.Value);
                //儿童税/机建
                TicketKindInfoModel1.OilFee = Utils.GetDecimal(this.txtChildShui.Value);
                //儿童人数
                TicketKindInfoModel1.PeopleCount = Utils.GetInt(this.txtChildCount.Value);
                //儿童代理费
                TicketKindInfoModel1.AgencyPrice = Utils.GetDecimal(this.txtChildProxyPrice.Value);
                //儿童票款
                TicketKindInfoModel1.TotalMoney = Utils.GetDecimal(this.txtChildSum.Value);
                //其它费用
                TicketKindInfoModel1.OtherPrice = Utils.GetDecimal(this.txt_OtherMoneyChild.Value);
                //百分比
                TicketKindInfoModel1.Discount = Utils.GetDecimal(this.txt_PercentChild.Value, 100) / 100;
                //票款类型
                TicketKindInfoModel1.TicketType = EyouSoft.Model.EnumType.PlanStructure.KindType.儿童;
                TicketKindInfoModel1.TicketId   = id;

                TicketKindInfoList.Add(TicketKindInfoModel1);

                TicketKindInfoModel1     = null;
                TicketKindInfoModel      = null;
                model.TicketKindInfoList = TicketKindInfoList;
                #endregion
                #endregion
                #region 基本信息
                //总费用
                model.Total = EyouSoft.Common.Utils.GetDecimal(this.txtSumMoney.Value);
                //支付方式
                model.PayType = (EyouSoft.Model.EnumType.TourStructure.RefundType)EyouSoft.Common.Utils.GetInt(Utils.GetFormValue("ddlPayType"));
                //
                model.OperateID = SiteUserInfo.ID;
                model.CompanyID = SiteUserInfo.CompanyID;
                model.Operator  = SiteUserInfo.ContactInfo.ContactName;
                model.RefundId  = id;
                //出票表ID
                model.TicketOutId = id;
                //订单ID
                model.OrderId = this.hdOrderID.Value;
                //团号ID
                model.TourId = this.hdTourID.Value;
                //订票须知
                model.Notice = this.txtOrderPiaoMust.Value;
                //PNR
                model.PNR = this.txtPNR.Value;
                //售票处
                model.TicketOffice   = this.txtSalePlace.Value;
                model.TicketOfficeId = Utils.GetInt(this.hd_PiaoWuSuppId.Value);
                //票号
                model.TicketNum = this.txtPiaoHao.Value;
                //备注
                model.Remark = this.txtMemo.Value;
                //线路名称
                model.RouteName = this.hd_LineName.Value;

                #endregion
                if (this.IsOk.Checked)
                {
                    model.State = EyouSoft.Model.EnumType.PlanStructure.TicketState.已出票;
                    if (bll.ToTicketOut(model))
                    {
                        TicketFlightList          = null;
                        TicketKindInfoList        = null;
                        TicketOutCustomerInfoList = null;
                        printSuccMsg("保存成功!");
                    }
                    else
                    {
                        TicketFlightList          = null;
                        TicketKindInfoList        = null;
                        TicketOutCustomerInfoList = null;
                        printFaiMsg("保存失败");
                    }
                }
                else
                {
                    model.State = EyouSoft.Model.EnumType.PlanStructure.TicketState.审核通过;
                    if (bll.UpdateTicketOutListModel(model))
                    {
                        TicketFlightList          = null;
                        TicketKindInfoList        = null;
                        TicketOutCustomerInfoList = null;
                        printSuccMsg("修改成功!");
                    }
                    else
                    {
                        TicketFlightList          = null;
                        TicketKindInfoList        = null;
                        TicketOutCustomerInfoList = null;
                        printFaiMsg("修改失败!");
                    }
                }

                model = null;
            }
            else
            {
                onInit();
                printFaiMsg(msg);
            }
        }
コード例 #3
0
        /// <summary>
        /// 提交事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void lbtn_submit_Click(object sender, EventArgs e)
        {
            EyouSoft.Model.PlanStructure.TicketOutListInfo model = new EyouSoft.Model.PlanStructure.TicketOutListInfo();
            model.TourId    = Utils.GetQueryStringValue("tourId");
            model.CompanyID = this.SiteUserInfo.CompanyID;
            model.OperateID = SiteUserInfo.ID;
            if (SiteUserInfo.ContactInfo != null)
            {
                model.Operator = SiteUserInfo.ContactInfo.ContactName;
            }
            model.OrderId = orderId;
            #region 成人儿童票款
            IList <EyouSoft.Model.PlanStructure.TicketKindInfo> ltki = new
                                                                       List <EyouSoft.Model.PlanStructure.TicketKindInfo>();
            ////成人票款
            EyouSoft.Model.PlanStructure.TicketKindInfo tki = new EyouSoft.Model.PlanStructure.TicketKindInfo();
            tki.OilFee      = Utils.GetDecimal(Utils.GetFormValue("txt_shui"));
            tki.PeopleCount = Utils.GetInt(Utils.GetFormValue("txt_pepoleNum"));
            tki.Price       = Utils.GetDecimal(Utils.GetFormValue("txt_piaomianjia"));
            tki.TotalMoney  = Utils.GetDecimal(Utils.GetFormValue("txt_piaokuan"));
            tki.TicketType  = EyouSoft.Model.EnumType.PlanStructure.KindType.成人;
            if (config_Agency.HasValue && EyouSoft.Model.EnumType.CompanyStructure.AgencyFeeType.公式三 == config_Agency.Value)
            {
                tki.OtherPrice  = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei"));
                tki.Discount    = Utils.GetDecimal(Utils.GetFormValue("txt_Percent"), 100) / 100;
                tki.AgencyPrice = 0;
            }
            else
            {
                tki.OtherPrice  = 0;
                tki.Discount    = 1;
                tki.AgencyPrice = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei"));
            }
            ltki.Add(tki);
            ///////儿童票款
            EyouSoft.Model.PlanStructure.TicketKindInfo tkirt = new EyouSoft.Model.PlanStructure.TicketKindInfo();
            tkirt.AgencyPrice = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei2"));
            tkirt.OilFee      = Utils.GetDecimal(Utils.GetFormValue("txt_shui2"));
            tkirt.PeopleCount = Utils.GetInt(Utils.GetFormValue("txt_pepoleNum2"));
            tkirt.Price       = Utils.GetDecimal(Utils.GetFormValue("txt_piaomianjia2"));
            tkirt.TotalMoney  = Utils.GetDecimal(Utils.GetFormValue("txt_piaokuan2"));
            tkirt.TicketType  = EyouSoft.Model.EnumType.PlanStructure.KindType.儿童;
            tkirt.OtherPrice  = Utils.GetDecimal(Utils.GetFormValue("txt_DaiLiFei2"));
            tkirt.Discount    = Utils.GetDecimal(Utils.GetFormValue("txt_Percent2"), 100) / 100;
            ltki.Add(tkirt);
            #endregion
            model.TicketKindInfoList = ltki;
            model.PNR                = Utils.GetFormValue("txt_PNR");
            model.Total              = Utils.GetDecimal(Utils.GetFormValue("txt_SumPrice"));
            model.PayType            = (EyouSoft.Model.EnumType.TourStructure.RefundType)Utils.GetInt(Utils.GetFormValue(ddl_PayType.UniqueID));
            model.Notice             = Utils.GetFormValue("txt_Order");
            model.Remark             = Utils.GetFormValue("txt_Remark");
            model.RouteName          = Utils.GetFormValue("hidRouteName");
            model.OrderId            = Utils.GetFormValue("hidOrderId");
            model.CustomerInfoList   = null;
            model.State              = EyouSoft.Model.EnumType.PlanStructure.TicketState.机票申请;
            model.TicketType         = EyouSoft.Model.EnumType.PlanStructure.TicketType.团队申请机票;
            model.RegisterOperatorId = SiteUserInfo.ID;
            model.TicketOutTime      = DateTime.Now;

            EyouSoft.BLL.PlanStruture.PlaneTicket bll = new EyouSoft.BLL.PlanStruture.PlaneTicket();

            if (Utils.GetFormValue("hidIsExtsisTicket") == "1")
            {
                //修改
                model.TicketOutId = this.hideId.Value;

                if (bll.UpdateTicketOutListModel(model))
                {
                    EyouSoft.Common.Function.MessageBox.ResponseScript(this.Page, string.Format("alert('修改成功');window.parent.Boxy.getIframeDialog('{0}').hide();window.parent.location.reload();", Utils.GetQueryStringValue("iframeId")));
                }
                else
                {
                    EyouSoft.Common.Function.MessageBox.ResponseScript(this.Page, string.Format("alert('修改失败');"));
                }
            }
            else
            {
                //添加
                if (bll.addTicketOutListModel(model))
                {
                    EyouSoft.Common.Function.MessageBox.ResponseScript(this.Page, string.Format("alert('添加成功');window.parent.Boxy.getIframeDialog('{0}').hide();window.parent.location.reload();", Utils.GetQueryStringValue("iframeId")));
                }
                else
                {
                    EyouSoft.Common.Function.MessageBox.ResponseScript(this.Page, string.Format("alert('添加成功')"));
                }
            }
        }