Example #1
0
        protected string customlevtypeprice(string tourid)
        {
            if (userModel != null && userModel.ID > 0)
            {
                return(BindPricesList(tourid, userModel.TourCompany.CustomerLevel));
            }
            else
            {
                System.Text.StringBuilder stringPrice = new System.Text.StringBuilder();
                stringPrice.Append("<tr bgcolor=\"#dfedfc\">");
                stringPrice.Append("<td height=\"20\" align=\"center\" width=\"40%\" bgcolor=\"#d0eafb\">报价标准</td>");
                stringPrice.Append("<td style=\"text-align:left\" width=\"60%\" bgcolor=\"#d0eafb\">价格</td>");

                EyouSoft.BLL.TourStructure.TourEveryday       bl    = new EyouSoft.BLL.TourStructure.TourEveryday(userModel);
                EyouSoft.Model.TourStructure.TourEverydayInfo model = new EyouSoft.Model.TourStructure.TourEverydayInfo();
                //散客天天发信息业务实体
                model = bl.GetTourEverydayInfo(tourid);
                //报价等级集合
                IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = model.PriceStandards;
                IList <EyouSoft.Model.CompanyStructure.CustomStand>        list      = new List <EyouSoft.Model.CompanyStructure.CustomStand>();
                EyouSoft.BLL.CompanyStructure.CompanyCustomStand           bll       = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
                //根据公司编号获取客户等级信息
                if (userModel != null)
                {
                    list = bll.GetCustomStandByCompanyId(userModel.CompanyID);
                }
                else
                {
                    EyouSoft.Model.SysStructure.SystemDomain domain = new EyouSoft.BLL.SysStructure.SystemDomain().GetDomain(Request.Url.Host.ToLower());
                    if (domain != null)
                    {
                        list = bll.GetCustomStandByCompanyId(domain.CompanyId);
                    }
                }

                for (int i = 0; i < listStand.Count; i++)
                {
                    for (int j = 0; j < listStand[i].CustomerLevels.Count; j++)
                    {
                        if (listStand[i].CustomerLevels[j].LevelType == EyouSoft.Model.EnumType.CompanyStructure.CustomLevType.门市)
                        {
                            stringPrice.Append("<tr>");
                            stringPrice.AppendFormat("<td height=\"20\" width=\"50px\" align=\"center\" bgcolor=\"#f6fafd\">{0}&nbsp;&nbsp;</td>", listStand[i].StandardName);
                            stringPrice.Append("<td style=\"text-align:left\" bgcolor=\"#f6fafd\">");
                            stringPrice.AppendFormat("成人价:{0}&nbsp;&nbsp;<br/>", Utils.FilterEndOfTheZeroDecimal(listStand[i].CustomerLevels[j].AdultPrice));
                            stringPrice.AppendFormat("儿童价:{0}", Utils.FilterEndOfTheZeroDecimal(listStand[i].CustomerLevels[j].ChildrenPrice));
                            stringPrice.Append("</td></tr>");
                            break;
                        }
                    }
                }
                stringPrice.Append("</tr>");
                prices = stringPrice.ToString();
                return(prices);
            }
        }
Example #2
0
        /// <summary>
        /// 绑定客户等级
        /// </summary>
        void BindCustomers()
        {
            IList <EyouSoft.Model.CompanyStructure.CustomStand> list = new List <EyouSoft.Model.CompanyStructure.CustomStand>();

            EyouSoft.BLL.CompanyStructure.CompanyCustomStand bll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
            //int kkk = 0;
            list = bll.GetCustomStandByCompanyId(SiteUserInfo.CompanyID);
            rpt_Customer.DataSource = list;
            rpt_Customer.DataBind();
        }
Example #3
0
        /// <summary>
        /// 绑定客户等级
        /// </summary>
        void BindCustomers()
        {
            //List<Customers> list = new List<Customers>();
            //list.Add(new Customers(3, "客户等级"));
            //rpt_Customer.DataSource = list;
            //rpt_Customer.DataBind();

            EyouSoft.BLL.TourStructure.Tour       tour  = new EyouSoft.BLL.TourStructure.Tour();
            EyouSoft.Model.TourStructure.TourInfo binfo = new EyouSoft.Model.TourStructure.TourInfo();
            binfo = (EyouSoft.Model.TourStructure.TourInfo)tour.GetTourInfo(Request.QueryString["tourId"]);
            EyouSoft.BLL.TourStructure.Tour bl = new EyouSoft.BLL.TourStructure.Tour();
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = binfo.PriceStandards;

            IList <EyouSoft.Model.TourStructure.TourPriceCustomerLevelInfo> listCust = listStand.First().CustomerLevels;



            IList <EyouSoft.Model.CompanyStructure.CustomStand> list = new List <EyouSoft.Model.CompanyStructure.CustomStand>();

            EyouSoft.BLL.CompanyStructure.CompanyCustomStand bll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();

            list = bll.GetCustomStandByCompanyId(CurrentUserCompanyID);
            int kkk = list.Count;
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> plist = binfo.PriceStandards;

            for (int i = 0; i < listStand.Count; i++)
            {
                for (int j = 0; j < list.Count; j++)
                {
                    //if(listStand[i].CustomerLevels[i].LevelId == list.sel)
                    if (listStand[i].CustomerLevels.Count > j)
                    {
                        var vn = list.Where(x => x.Id == listStand[i].CustomerLevels[j].LevelId).FirstOrDefault();
                        if (vn != null)
                        {
                            listStand[i].CustomerLevels[j].LevelName = vn.CustomStandName;
                        }
                        else
                        {
                            listStand[i].CustomerLevels.RemoveAt(j);
                        }
                    }
                    var xn = listStand[i].CustomerLevels.Where(x => x.LevelId == list[j].Id).FirstOrDefault();
                    if (xn == null)
                    {
                        listStand[i].CustomerLevels.Add(new EyouSoft.Model.TourStructure.TourPriceCustomerLevelInfo()
                        {
                            LevelId = list[j].Id, LevelType = list[j].LevType, LevelName = list[j].CustomStandName, AdultPrice = 0, ChildrenPrice = 0
                        });
                    }
                }
            }
            sinfo = plist;
        }
Example #4
0
        /// <summary>
        /// 绑定信息
        /// </summary>
        void BindInfo()
        {
            EyouSoft.BLL.TourStructure.TourEveryday bl = new EyouSoft.BLL.TourStructure.TourEveryday(SiteUserInfo);
            string tourId  = Utils.GetQueryStringValue("tourid");
            string ApplyId = Utils.GetQueryStringValue("ApplyId");

            EyouSoft.Model.TourStructure.TourEverydayInfo model = bl.GetTourEverydayInfo(tourId);

            #region 价格绑定
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = model.PriceStandards;

            IList <EyouSoft.Model.CompanyStructure.CustomStand> list = new List <EyouSoft.Model.CompanyStructure.CustomStand>();
            EyouSoft.BLL.CompanyStructure.CompanyCustomStand    bll  = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();

            list = bll.GetCustomStandByCompanyId(CurrentUserCompanyID);
            int kkk = list.Count;

            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> plist = model.PriceStandards;
            for (int i = 0; i < listStand.Count; i++)
            {
                for (int j = 0; j < list.Count; j++)
                {
                    //if(listStand[i].CustomerLevels[i].LevelId == list.sel)
                    if (listStand[i].CustomerLevels.Count > j)
                    {
                        var vn = list.Where(x => x.Id == listStand[i].CustomerLevels[j].LevelId).FirstOrDefault();
                        if (vn != null)
                        {
                            listStand[i].CustomerLevels[j].LevelName = vn.CustomStandName;
                        }
                        else
                        {
                            listStand[i].CustomerLevels.RemoveAt(j);
                        }
                    }
                    var xn = listStand[i].CustomerLevels.Where(x => x.LevelId == list[j].Id).FirstOrDefault();
                    if (xn == null)
                    {
                        listStand[i].CustomerLevels.Add(new EyouSoft.Model.TourStructure.TourPriceCustomerLevelInfo()
                        {
                            LevelId = list[j].Id, LevelType = list[j].LevType, LevelName = list[j].CustomStandName, AdultPrice = 0, ChildrenPrice = 0
                        });
                    }
                }
            }
            sinfo = plist;
            #endregion
            hd_area.Value = model.AreaId.ToString();//线路区域
            EyouSoft.Model.TourStructure.TourEverydayApplyInfo applyModel = new EyouSoft.Model.TourStructure.TourEverydayApplyInfo();
            applyModel     = bl.GetTourEverydayApplyInfo(ApplyId);
            hd_Ldate.Value = applyModel.LDate.ToShortDateString();
            txt_ykrs.Value = applyModel.PeopleNumber.ToString();
            hd_num.Value   = applyModel.PeopleNumber.ToString();
        }
Example #5
0
        protected void BindPrices()
        {
            EyouSoft.BLL.TourStructure.TourEveryday       bl    = new EyouSoft.BLL.TourStructure.TourEveryday(SiteUserInfo);
            EyouSoft.Model.TourStructure.TourEverydayInfo model = new EyouSoft.Model.TourStructure.TourEverydayInfo();
            model = bl.GetTourEverydayInfo(Request.QueryString["tourid"]);
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = model.PriceStandards;
            IList <EyouSoft.Model.CompanyStructure.CustomStand>        list      = new List <EyouSoft.Model.CompanyStructure.CustomStand>();

            EyouSoft.BLL.CompanyStructure.CompanyCustomStand bll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
            list = bll.GetCustomStandByCompanyId(SiteUserInfo.CompanyID);
            int kkk = list.Count;
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> plist = model.PriceStandards;

            for (int i = 0; i < listStand.Count; i++)
            {
                for (int j = 0; j < list.Count; j++)
                {
                    if (listStand[i].CustomerLevels.Count > j)
                    {
                        var vn = list.Where(x => x.Id == listStand[i].CustomerLevels[j].LevelId).FirstOrDefault();
                        if (vn != null)
                        {
                            listStand[i].CustomerLevels[j].LevelName = vn.CustomStandName;
                        }
                        else
                        {
                            listStand[i].CustomerLevels.RemoveAt(j);
                        }
                    }
                    var xn = listStand[i].CustomerLevels.Where(x => x.LevelId == list[j].Id).FirstOrDefault();
                    if (xn == null)
                    {
                        listStand[i].CustomerLevels.Add(new EyouSoft.Model.TourStructure.TourPriceCustomerLevelInfo()
                        {
                            LevelId = list[j].Id, LevelType = list[j].LevType, LevelName = list[j].CustomStandName, AdultPrice = 0, ChildrenPrice = 0
                        });
                    }
                }
            }
            sinfo = plist;
        }
Example #6
0
        protected string BindPricesList(string Tourid, int CustomerLevel)
        {
            System.Text.StringBuilder stringPrice               = new System.Text.StringBuilder();
            EyouSoft.BLL.TourStructure.TourEveryday       bl    = new EyouSoft.BLL.TourStructure.TourEveryday(userModel);
            EyouSoft.Model.TourStructure.TourEverydayInfo model = new EyouSoft.Model.TourStructure.TourEverydayInfo();
            //散客天天发信息业务实体
            model = bl.GetTourEverydayInfo(Tourid);
            //报价等级集合
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = model.PriceStandards;
            IList <EyouSoft.Model.CompanyStructure.CustomStand>        list      = new List <EyouSoft.Model.CompanyStructure.CustomStand>();

            EyouSoft.BLL.CompanyStructure.CompanyCustomStand bll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
            //根据公司编号获取客户等级信息
            list = bll.GetCustomStandByCompanyId(userModel.CompanyID);
            stringPrice.Append("<tr bgcolor=\"#dfedfc\">");
            stringPrice.Append("<td height=\"20\" align=\"center\" width=\"40%\" bgcolor=\"#d0eafb\">报价标准</td>");
            stringPrice.Append("<td style=\"text-align:left\" width=\"60%\" bgcolor=\"#d0eafb\">价格</td>");
            for (int i = 0; i < listStand.Count; i++)
            {
                for (int j = 0; j < listStand[i].CustomerLevels.Count; j++)
                {
                    if (listStand[i].CustomerLevels[j].LevelId == CustomerLevel)
                    {
                        stringPrice.Append("<tr>");
                        stringPrice.AppendFormat("<td height=\"20\" width=\"50px\" align=\"center\" bgcolor=\"#f6fafd\">{0}&nbsp;&nbsp;</td>", listStand[i].StandardName);
                        stringPrice.Append("<td style=\"text-align:left\" bgcolor=\"#f6fafd\">");
                        stringPrice.AppendFormat("成人价:{0}&nbsp;&nbsp;<br/>", Utils.FilterEndOfTheZeroDecimal(listStand[i].CustomerLevels[j].AdultPrice));
                        stringPrice.AppendFormat("儿童价:{0}", Utils.FilterEndOfTheZeroDecimal(listStand[i].CustomerLevels[j].ChildrenPrice));
                        stringPrice.Append("</td></tr>");
                        break;
                    }
                }
            }
            stringPrice.Append("</tr>");
            prices = stringPrice.ToString();
            return(prices);
        }
Example #7
0
        protected string getPeoPlePrice(string Tourid)
        {
            string Prices = "";

            EyouSoft.BLL.TourStructure.TourEveryday       bl    = new EyouSoft.BLL.TourStructure.TourEveryday(userModel);
            EyouSoft.Model.TourStructure.TourEverydayInfo model = new EyouSoft.Model.TourStructure.TourEverydayInfo();
            //散客天天发信息业务实体
            model = bl.GetTourEverydayInfo(Tourid);
            //报价等级集合
            IList <EyouSoft.Model.TourStructure.TourPriceStandardInfo> listStand = model.PriceStandards;
            IList <EyouSoft.Model.CompanyStructure.CustomStand>        list      = new List <EyouSoft.Model.CompanyStructure.CustomStand>();

            EyouSoft.BLL.CompanyStructure.CompanyCustomStand bll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
            //根据公司编号获取客户等级信息
            if (userModel != null)
            {
                list = bll.GetCustomStandByCompanyId(userModel.CompanyID);
            }
            else
            {
                EyouSoft.Model.SysStructure.SystemDomain domain = new EyouSoft.BLL.SysStructure.SystemDomain().GetDomain(Request.Url.Host.ToLower());
                if (domain != null)
                {
                    list = bll.GetCustomStandByCompanyId(domain.CompanyId);
                }
            }

            #region 登录状态
            if (userModel != null && userModel.ID > 0)
            {
                if (listStand != null && listStand.Count > 0)
                {
                    for (int i = 0; i < listStand.Count; i++)
                    {
                        if (listStand[0].CustomerLevels != null)
                        {
                            for (int j = 0; j < listStand[0].CustomerLevels.Count; j++)
                            {
                                if (listStand[0].CustomerLevels[j].LevelId == userModel.TourCompany.CustomerLevel)
                                {
                                    Prices = Utils.FilterEndOfTheZeroString(listStand[0].CustomerLevels[j].AdultPrice.ToString("0.00")) + "/" + Utils.FilterEndOfTheZeroString(listStand[0].CustomerLevels[j].ChildrenPrice.ToString("0.00"));
                                    break;
                                }
                                else
                                {
                                    Prices = "";
                                }
                            }
                        }
                    }
                }
            }
            #endregion

            #region 未登录
            if (userModel == null)
            {
                for (int i = 0; i < listStand.Count; i++)
                {
                    if (listStand[i].CustomerLevels != null)
                    {
                        for (int j = 0; j < listStand[i].CustomerLevels.Count; j++)
                        {
                            if (listStand[i].CustomerLevels[j].LevelType == EyouSoft.Model.EnumType.CompanyStructure.CustomLevType.门市)
                            {
                                Prices = Utils.FilterEndOfTheZeroString(listStand[i].CustomerLevels[j].AdultPrice.ToString("0.00")) + "/" + Utils.FilterEndOfTheZeroString(listStand[i].CustomerLevels[j].ChildrenPrice.ToString("0.00"));
                            }
                        }
                    }
                }
            }
            #endregion

            return(Prices);
        }
Example #8
0
        //销售列表详细数据初始化
        private void onInit()
        {
            if (OrderID != "")
            {
                EyouSoft.BLL.TourStructure.TourOrder   TourOrderBll   = new EyouSoft.BLL.TourStructure.TourOrder();
                EyouSoft.Model.TourStructure.TourOrder TourOrderModel = TourOrderBll.GetOrderModel(CurrentUserCompanyID, OrderID);
                System.Text.StringBuilder stringPrice = new System.Text.StringBuilder();

                if (TourOrderModel != null)
                {
                    #region 结算价绑定
                    //只有散拼有报价标准,单项服务与团队计划都没有报价标准
                    if (TourOrderModel.TourClassId == EyouSoft.Model.EnumType.TourStructure.TourType.散拼计划)
                    {
                        EyouSoft.BLL.CompanyStructure.CompanyPriceStand  CompanyPriceStandBll  = new EyouSoft.BLL.CompanyStructure.CompanyPriceStand();
                        EyouSoft.BLL.CompanyStructure.CompanyCustomStand CompanyCustomStandBll = new EyouSoft.BLL.CompanyStructure.CompanyCustomStand();
                        EyouSoft.BLL.TourStructure.Tour tourBLl = new EyouSoft.BLL.TourStructure.Tour();
                        PriceList             = tourBLl.GetPriceStandards(TourOrderModel.TourId);
                        CompanyPriceStandList = CompanyPriceStandBll.GetPriceStandByCompanyId(SiteUserInfo.CompanyID);
                        CustomStandList       = CompanyCustomStandBll.GetCustomStandByCompanyId(SiteUserInfo.CompanyID);
                        for (int j = 0; j < CompanyPriceStandList.Count; j++)
                        {
                            if (j == 0)
                            {
                                stringPrice.Append("<tr><td align=\"center\">报价标准</td>");
                                for (int i = 0; i < CustomStandList.Count; i++)
                                {
                                    EyouSoft.Model.CompanyStructure.CustomStand CustomStand = CustomStandList[i];
                                    stringPrice.AppendFormat("<td><div style=\"text-align: center;\">{0}</div></td>", CustomStand.CustomStandName);
                                }
                                stringPrice.Append("</tr>");
                            }
                            EyouSoft.Model.CompanyStructure.CompanyPriceStand CompanyPriceStand = CompanyPriceStandList[j];
                            stringPrice.Append("<tr>");
                            stringPrice.AppendFormat("<td><div class=\"divPrice\" val=\"{0}\">", CompanyPriceStand.Id);
                            stringPrice.AppendFormat("<div style=\"text-align: center;\">{0}</div></td>", CompanyPriceStand.PriceStandName);
                            for (int i = 0; i < CustomStandList.Count; i++)
                            {
                                EyouSoft.Model.CompanyStructure.CustomStand CustomStand = CustomStandList[i];
                                stringPrice.Append("<td>");

                                stringPrice.AppendFormat("<input type=\"radio\" name=\"radio\" id=\"radio{0}\" value=\"{0}\" />", CustomStand.Id);
                                stringPrice.AppendFormat("成人价:<span name=\"sp_cr_price\">{0}</span>", FilterEndOfTheZeroDecimal(GetPriceBy(CompanyPriceStand.Id, CustomStand.Id, true)));
                                stringPrice.AppendFormat("儿童价:<span name=\"sp_et_price\">{0}</span>", FilterEndOfTheZeroDecimal(GetPriceBy(CompanyPriceStand.Id, CustomStand.Id, false)));
                            }
                            stringPrice.Append("</td></tr>");
                        }
                        price = stringPrice.ToString();
                    }
                    //如果该订单是团队计划订单,则不显示成人数与儿童数,显示总人数
                    else if (TourOrderModel.TourClassId == EyouSoft.Model.EnumType.TourStructure.TourType.团队计划)
                    {
                        this.SanPingPersonNum.Visible = false;
                        this.lblTeamPersonNum.Visible = true;
                        this.lblTeamPersonNum.Enabled = false;
                    }
                    PriceStandId  = TourOrderModel.PriceStandId.ToString();
                    CustomerLevId = TourOrderModel.CustomerLevId.ToString();
                    #endregion
                    #region 订单基本数据
                    //线路名称
                    this.lblLineName.Text = TourOrderModel.RouteName;
                    //出团日期
                    this.lblChuTuanDate.Text = TourOrderModel.LeaveDate.ToString("yyyy-MM-dd");
                    //当前空位
                    this.lblCurFreePosi.Text = TourOrderModel.RemainNum.ToString();
                    //出发交通
                    this.lblChuFanTra.Text = TourOrderModel.LeaveTraffic;
                    //返回交通
                    this.lblBackTra.Text = TourOrderModel.ReturnTraffic;
                    //联系人
                    this.lblContactName.Text = TourOrderModel.ContactName;
                    //电话
                    this.lblContactPhone.Text = TourOrderModel.ContactTel;
                    //手机
                    this.lblContactMobile.Text = TourOrderModel.ContactMobile;
                    //传真
                    this.lblContactFax.Text = TourOrderModel.ContactFax;
                    //特殊要求说明
                    this.txtSpecialRe.Text = TourOrderModel.SpecialContent;
                    //操作留言
                    this.txtOperMes.Text = TourOrderModel.OperatorContent;
                    //人数(成人)
                    this.txtDdultCount.Text = TourOrderModel.AdultNumber.ToString();
                    //人数(儿童)
                    this.txtChildCount.Text = TourOrderModel.ChildNumber.ToString();
                    //总金额
                    this.txtTotalMoney.Text = Utils.FilterEndOfTheZeroString(TourOrderModel.SumPrice.ToString());
                    //总人数
                    this.lblTeamPersonNum.Text = TourOrderModel.PeopleNumber.ToString();
                    if (!string.IsNullOrEmpty(TourOrderModel.CustomerFilePath))
                    {
                        this.hykCusFile.NavigateUrl = TourOrderModel.CustomerFilePath;
                        this.hykCusFile.Visible     = true;
                    }

                    ltrBuyerTourCode.Text = TourOrderModel.BuyerTourCode;
                    #endregion
                    #region 订单游客数据
                    System.Collections.Generic.IList <EyouSoft.Model.TourStructure.TourOrderCustomer> curList = TourOrderModel.CustomerList;
                    System.Text.StringBuilder stringBuilder = new System.Text.StringBuilder();
                    if (curList != null && curList.Count > 0)
                    {
                        for (int i = 0; i < curList.Count; i++)
                        {
                            if (curList[i].VisitorType == EyouSoft.Model.EnumType.TourStructure.VisitorType.成人)
                            {
                                stringBuilder.AppendFormat("<tr itemtype=\"{0}\">", "adult");
                            }
                            else if (curList[i].VisitorType == EyouSoft.Model.EnumType.TourStructure.VisitorType.儿童)
                            {
                                stringBuilder.AppendFormat("<tr itemtype=\"{0}\">", "child");
                            }
                            else
                            {
                                stringBuilder.AppendFormat("<tr itemtype=\"{0}\">", "other");
                            }
                            stringBuilder.AppendFormat("<td style=\"width: 5%\" bgcolor=\"#e3f1fc\" index=\"{0}\" align=\"center\">{0}</td><td height=\"25\" bgcolor=\"#e3f1fc\" align=\"center\">", i + 1);
                            stringBuilder.AppendFormat("<input type=\"text\" class=\"searchinput\" id=\"cusName\" name=\"cusName\" value=\"{0}\" /></td>", curList[i].VisitorName);
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\">");

                            #region 游客类型
                            if (curList[i].VisitorType == EyouSoft.Model.EnumType.TourStructure.VisitorType.成人)
                            {
                                stringBuilder.Append("<select disabled=\"disabled\" id=\"cusType\" name=\"cusType\">");
                                stringBuilder.Append("<option value=\"0\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\" selected=\"selected\">成人</option>");
                                stringBuilder.Append("<option value=\"2\">儿童</option>");
                                stringBuilder.Append(" </select>");
                            }
                            //儿童
                            else if (curList[i].VisitorType == EyouSoft.Model.EnumType.TourStructure.VisitorType.儿童)
                            {
                                stringBuilder.Append("<select disabled=\"disabled\" id=\"cusType\" name=\"cusType\">");
                                stringBuilder.Append("<option value=\"0\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\" >成人</option>");
                                stringBuilder.Append("<option value=\"2\" selected=\"selected\">儿童</option>");
                                stringBuilder.Append(" </select>");
                            }
                            //其它
                            else
                            {
                                stringBuilder.Append("<select disabled=\"disabled\" id=\"cusType\" name=\"cusType\">");
                                stringBuilder.Append("<option value=\"0\"  selected=\"selected\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\" >成人</option>");
                                stringBuilder.Append("<option value=\"2\">儿童</option>");
                                stringBuilder.Append(" </select>");
                            }
                            #endregion

                            stringBuilder.Append("</td>");
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\">");

                            #region 游客证件类型
                            switch (curList[i].CradType)
                            {
                            case EyouSoft.Model.EnumType.TourStructure.CradType.身份证:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\" selected=\"selected\">身份证</option>");
                                stringBuilder.Append("<option value=\"2\">护照</option>");
                                stringBuilder.Append("<option value=\"3\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            case EyouSoft.Model.EnumType.TourStructure.CradType.护照:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\">身份证</option>");
                                stringBuilder.Append("<option value=\"2\" selected=\"selected\">护照</option>");
                                stringBuilder.Append("<option value=\"3\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            case EyouSoft.Model.EnumType.TourStructure.CradType.军官证:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\">身份证</option>");
                                stringBuilder.Append("<option value=\"2\">护照</option>");
                                stringBuilder.Append("<option value=\"3\" selected=\"selected\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            case EyouSoft.Model.EnumType.TourStructure.CradType.台胞证:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\">身份证</option>");
                                stringBuilder.Append("<option value=\"2\">护照</option>");
                                stringBuilder.Append("<option value=\"3\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\" selected=\"selected\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            case EyouSoft.Model.EnumType.TourStructure.CradType.港澳通行证:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\">身份证</option>");
                                stringBuilder.Append("<option value=\"2\">护照</option>");
                                stringBuilder.Append("<option value=\"3\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\" selected=\"selected\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            default:
                            {
                                stringBuilder.Append("<select id=\"cusCardType\" name=\"cusCardType\">");
                                stringBuilder.Append("<option value=\"0\" selected=\"selected\">请选择证件</option>");
                                stringBuilder.Append("<option value=\"1\" >身份证</option>");
                                stringBuilder.Append("<option value=\"2\">护照</option>");
                                stringBuilder.Append("<option value=\"3\">军官证</option>");
                                stringBuilder.Append("<option value=\"4\">台胞证</option>");
                                stringBuilder.Append("<option value=\"5\">港澳通行证</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }
                            }
                            #endregion

                            stringBuilder.Append("</td>");
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\">");
                            stringBuilder.AppendFormat("<input type=\"text\" class=\"searchinput searchinput02\" id=\"cusCardNo\" onblur='getSex(this)' name=\"cusCardNo\" value=\"{0}\">", curList[i].CradNumber);
                            stringBuilder.Append("</td>");
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\">");

                            #region 游客性别
                            switch (curList[i].Sex)
                            {
                            case EyouSoft.Model.EnumType.CompanyStructure.Sex.男:
                            {
                                stringBuilder.Append("<select id=\"cusSex\" class='ddlSex' name=\"cusSex\">");
                                stringBuilder.Append("<option value=\"0\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\" selected=\"selected\">男</option>");
                                stringBuilder.Append("<option value=\"2\">女</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            case EyouSoft.Model.EnumType.CompanyStructure.Sex.女:
                            {
                                stringBuilder.Append("<select id=\"cusSex\" class='ddlSex' name=\"cusSex\">");
                                stringBuilder.Append("<option value=\"0\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\">男</option>");
                                stringBuilder.Append("<option value=\"2\" selected=\"selected\">女</option>");
                                stringBuilder.Append("</select>");
                                break;
                            }

                            default:
                            {
                                stringBuilder.Append("<select id=\"cusSex\" class='ddlSex' name=\"cusSex\">");
                                stringBuilder.Append("<option value=\"0\" selected=\"selected\">请选择</option>");
                                stringBuilder.Append("<option value=\"1\">男</option>");
                                stringBuilder.Append("<option value=\"2\">女</option>");
                                break;
                            }
                            }

                            #endregion

                            stringBuilder.Append("</td>");
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\">");
                            stringBuilder.AppendFormat("<input type=\"text\" class=\"searchinput\" id=\"cusPhone\" name=\"cusPhone\" value=\"{0}\">", curList[i].ContactTel);
                            stringBuilder.Append("</td>");
                            stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\"  width=\"6%\">");
                            if (curList[i].SpecialServiceInfo != null)
                            {
                                string str = string.Format("txtItem={0}&txtServiceContent={1}&txtCost={2}&ddlOperate={3}", curList[i].SpecialServiceInfo.ProjectName, curList[i].SpecialServiceInfo.ServiceDetail, curList[i].SpecialServiceInfo.Fee, (curList[i].SpecialServiceInfo.IsAdd.ToString() == "true" ? "1" : "0"));
                                stringBuilder.AppendFormat("<input id=\"spe{0}\" type=\"hidden\" name=\"specive\" value=\"{1}\" />", curList[i].ID, str);
                            }
                            else
                            {
                                stringBuilder.AppendFormat("<input id=\"spe{0}\" type=\"hidden\" name=\"specive\" value=\"\" />", curList[i].ID);
                            }
                            stringBuilder.AppendFormat("<a sign=\"speService\" href=\"javascript:void(0)\" onclick=\"OrderEdit.OpenSpecive('spe{0}',$(this))\">特服</a></td>", curList[i].ID);
                            stringBuilder.Append("</tr>");
                        }
                    }
                    cusHtml = stringBuilder.ToString();
                    #endregion

                    if (TourOrderModel.BuyerContactId > 0)
                    {
                        var buyerContactInfo = new EyouSoft.BLL.CompanyStructure.Customer().GetCustomerContactModel(TourOrderModel.BuyerContactId);
                        if (buyerContactInfo != null)
                        {
                            this.ltrBuyerContact.Text = string.Format("姓名:{0}&nbsp;&nbsp;电话:{1}&nbsp;&nbsp;手机:{2}&nbsp;&nbsp;QQ:{3}", buyerContactInfo.Name
                                                                      , buyerContactInfo.Tel
                                                                      , buyerContactInfo.Mobile
                                                                      , buyerContactInfo.qq);
                            buyerContactInfo = null;
                        }
                    }
                }

                TourOrderBll   = null;
                TourOrderModel = null;
            }
        }