Пример #1
0
        /// <summary>
        /// 专线端添加报价并生成团队计划
        /// </summary>
        /// <param name="info">团队计划列表信息业务实体</param>
        /// <param name="LineInquireQuoteInfo">线路询价报价实体类</param>
        /// <returns></returns>
        public bool AddQuote(EyouSoft.Model.TourStructure.TourTeamInfo info, EyouSoft.Model.TourStructure.LineInquireQuoteInfo LineInquireQuoteInfo)
        {
            if (LineInquireQuoteInfo.CompanyId == 0 || LineInquireQuoteInfo.Id == 0)
            {
                return(false);
            }

            if (QuoteSuccessInsertPlan(LineInquireQuoteInfo.Id, info))
            {
                //同步组团询价游客信息到团队计划订单
                dal.SyncQuoteTravellerToTourTeamOrder(LineInquireQuoteInfo.Id, info.TourId);

                LineInquireQuoteInfo.QuoteState = EyouSoft.Model.EnumType.TourStructure.QuoteState.已成功;
                if (dal.UpdateQuote(LineInquireQuoteInfo))
                {
                    #region LGWR
                    EyouSoft.Model.CompanyStructure.SysHandleLogs logInfo = new EyouSoft.Model.CompanyStructure.SysHandleLogs();
                    logInfo.CompanyId    = 0;
                    logInfo.DepatId      = 0;
                    logInfo.EventCode    = EyouSoft.Model.CompanyStructure.SysHandleLogsNO.EventCode;
                    logInfo.EventIp      = string.Empty;
                    logInfo.EventMessage = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "{0}在" + EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.团队计划_组团社询价.ToString() + "添加了一条报价,编号:" + LineInquireQuoteInfo.Id;
                    logInfo.EventTime    = DateTime.Now;
                    logInfo.EventTitle   = "添加报价";
                    logInfo.ModuleId     = EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.团队计划_组团社询价;
                    logInfo.OperatorId   = 0;
                    this.Logwr(logInfo);
                    return(true);

                    #endregion
                }
            }
            return(false);
        }
Пример #2
0
        /// <summary>
        /// 组团端添加一个询价
        /// </summary>
        /// <param name="LineInquireQuoteInfo"></param>
        /// <returns></returns>
        public bool AddInquire(EyouSoft.Model.TourStructure.LineInquireQuoteInfo LineInquireQuoteInfo)
        {
            if (LineInquireQuoteInfo.CompanyId == 0 || LineInquireQuoteInfo.CustomerId == 0)
            {
                return(false);
            }
            LineInquireQuoteInfo.QuoteState = EyouSoft.Model.EnumType.TourStructure.QuoteState.未处理;
            if (dal.AddInquire(LineInquireQuoteInfo))
            {
                #region LGWR
                //EyouSoft.Model.CompanyStructure.SysHandleLogs logInfo = new EyouSoft.Model.CompanyStructure.SysHandleLogs();
                //logInfo.CompanyId = 0;
                //logInfo.DepatId = 0;
                //logInfo.EventCode = EyouSoft.Model.CompanyStructure.SysHandleLogsNO.EventCode;
                //logInfo.EventIp = string.Empty;
                //logInfo.EventMessage = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "{0}在" + EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.团队计划_组团社询价.ToString() + "添加了一条询价";
                //logInfo.EventTime = DateTime.Now;
                //logInfo.EventTitle = "添加询价";
                //logInfo.ModuleId = EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.团队计划_组团社询价;
                //logInfo.OperatorId = 0;
                //this.Logwr(logInfo);
                return(true);

                #endregion
            }
            return(false);
        }
Пример #3
0
        protected void lkBtn_save_Click(object sender, EventArgs e)
        {
            EyouSoft.Model.TourStructure.LineInquireQuoteInfo lineInfo = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo();
            int id = 0;

            id       = Convert.ToInt32(Utils.GetQueryStringValue("id"));
            lineInfo = SaveInfo(id);
            TheResult(lineQuoteBll.UpdateQuote(lineInfo), "save");
        }
Пример #4
0
 //根据状态屏蔽按钮
 protected void CheckBtn(EyouSoft.Model.TourStructure.LineInquireQuoteInfo lineInfo)
 {
     if (lineInfo.QuoteState == EyouSoft.Model.EnumType.TourStructure.QuoteState.已成功)
     {
         this.lkBtn_save.Visible = false;
         this.submit.Visible     = false;
     }
     else
     {
         this.lkBtn_save.Visible = true;
         this.submit.Visible     = true;
     }
 }
Пример #5
0
        /// <summary>
        /// 专线端修改报价
        /// </summary>
        /// <param name="LineInquireQuoteInfo"></param>
        /// <returns></returns>
        public bool UpdateQuote(EyouSoft.Model.TourStructure.LineInquireQuoteInfo LineInquireQuoteInfo)
        {
            DbCommand dc = this.DB.GetStoredProcCommand("proc_Inquire_UpdateQuote");

            this.DB.AddInParameter(dc, "CompanyId", DbType.Int32, LineInquireQuoteInfo.CompanyId);
            this.DB.AddInParameter(dc, "Id", DbType.Int32, LineInquireQuoteInfo.Id);
            this.DB.AddInParameter(dc, "RouteId", DbType.Int32, LineInquireQuoteInfo.RouteId);
            this.DB.AddInParameter(dc, "RouteName", DbType.String, LineInquireQuoteInfo.RouteName);
            this.DB.AddInParameter(dc, "ContactTel", DbType.String, LineInquireQuoteInfo.ContactTel);
            this.DB.AddInParameter(dc, "ContactName", DbType.String, LineInquireQuoteInfo.ContactName);
            this.DB.AddInParameter(dc, "LeaveDate", DbType.DateTime, LineInquireQuoteInfo.LeaveDate);
            this.DB.AddInParameter(dc, "AdultNumber", DbType.Int32, LineInquireQuoteInfo.PeopleNum);
            this.DB.AddInParameter(dc, "ChildNumber", DbType.Int32, LineInquireQuoteInfo.ChildNumber);
            this.DB.AddInParameter(dc, "SpecialClaim", DbType.String, LineInquireQuoteInfo.SpecialClaim);
            this.DB.AddInParameter(dc, "Remark", DbType.String, LineInquireQuoteInfo.Remark);

            this.DB.AddInParameter(dc, "TicketAgio", DbType.Decimal, LineInquireQuoteInfo.TicketAgio);
            this.DB.AddInParameter(dc, "QuoteState", DbType.Byte, (int)LineInquireQuoteInfo.QuoteState);
            this.DB.AddInParameter(dc, "XingCheng", DbType.String, CreateXingChengAskXML(LineInquireQuoteInfo.XingCheng));
            this.DB.AddInParameter(dc, "ASK", DbType.String, CreateQuoteAskXML(LineInquireQuoteInfo.Requirements));
            this.DB.AddInParameter(dc, "QuoteInfo", DbType.String, CreateQuoteListXML(LineInquireQuoteInfo.Services));
            this.DB.AddOutParameter(dc, "Result", DbType.Int32, 4);
            this.DB.AddInParameter(dc, "TotalAmount", DbType.Decimal, LineInquireQuoteInfo.TotalAmount);
            if (LineInquireQuoteInfo.Traveller != null)
            {
                this.DB.AddInParameter(dc, "TravellerDisplayType", DbType.Byte, LineInquireQuoteInfo.Traveller.TravellerDisplayType);
                this.DB.AddInParameter(dc, "TravellerFilePath", DbType.String, LineInquireQuoteInfo.Traveller.TravellerFilePath);
                this.DB.AddInParameter(dc, "Travellers", DbType.String, this.CreateQuoteTravellersXML(LineInquireQuoteInfo.Traveller.Travellers));
            }
            else
            {
                this.DB.AddInParameter(dc, "TravellerDisplayType", DbType.Byte, EyouSoft.Model.EnumType.TourStructure.CustomerDisplayType.None);
                this.DB.AddInParameter(dc, "TravellerFilePath", DbType.String, DBNull.Value);
                this.DB.AddInParameter(dc, "Travellers", DbType.String, DBNull.Value);
            }
            DbHelper.RunProcedure(dc, DB);
            object Result = this.DB.GetParameterValue(dc, "Result");

            return(int.Parse(Result.ToString()) > 0 ? true : false);
        }
Пример #6
0
        protected void Page_Load(object sender, EventArgs e)
        {
            tsModel = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo();
            string act = string.Empty;

            act = EyouSoft.Common.Utils.GetQueryStringValue("act");

            if (!IsPostBack)
            {
                switch (act)
                {
                case "del":

                    AreaDel();    //删除操作

                    break;

                default:
                    bind();
                    break;
                }
            }
        }
Пример #7
0
        protected EyouSoft.Model.TourStructure.LineInquireQuoteInfo InitInfo(int id)
        {
            //记录我社报价价格
            decimal price = 0;

            //询价实体类
            EyouSoft.Model.TourStructure.LineInquireQuoteInfo lineInfo = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo();
            lineQuoteBll = new EyouSoft.BLL.TourStructure.LineInquireQuoteInfo(SiteUserInfo);
            lineInfo     = lineQuoteBll.GetQuoteModel(id, SiteUserInfo.CompanyID, 0, false);
            if (lineInfo != null)
            {
                //为类赋值
                //折扣
                this.txt_agio.Value = Utils.FilterEndOfTheZeroString(EyouSoft.Common.Utils.GetDecimal(lineInfo.TicketAgio.ToString()).ToString("0.00"));
                //出团日期
                this.txt_BegTime.Value = ((DateTime)(lineInfo.LeaveDate)).ToString("yyyy-MM-dd");
                //联系人姓名
                this.txt_contactName.Value = Utils.GetString(lineInfo.ContactName, "");
                //联系人电话
                this.txt_contactTel.Value = Utils.GetString(lineInfo.ContactTel, "");
                //总人数
                this.txt_peopleCount.Value = Utils.GetString(Convert.ToString(lineInfo.PeopleNum), "");
                //询价单位名称
                this.txt_quoteCompany.Value = Utils.GetString(lineInfo.CustomerName, "");
                //询价单位编号
                this.hid_QuoteCompanyId.Value = Convert.ToString(lineInfo.CustomerId);
                //客户要求用户控件赋值
                this.ConProjectControl1.SetList = lineInfo.Requirements;
                ConProjectControl1.SetDataList();
                //价格组成用户控件赋值
                this.PriceControl1.SetList     = lineInfo.Services;
                this.PriceControl1.TotalAmount = lineInfo.TotalAmount;
                //行程要求
                if (lineInfo.XingCheng != null)
                {
                    this.txtRoutingNeed.Text = Utils.GetString(lineInfo.XingCheng.QuotePlan, "");
                    file = Utils.GetString(lineInfo.XingCheng.PlanAccessory, "");
                    this.hid_img_name.Value = Utils.GetString(lineInfo.XingCheng.PlanAccessoryName, "");
                    this.hid_img_path.Value = Utils.GetString(lineInfo.XingCheng.PlanAccessory, "");
                }
                //状态
                this.lblResult.Text = Convert.ToString(lineInfo.QuoteState);
                //特殊需求
                this.txt_need.Value = Utils.GetString(lineInfo.SpecialClaim, "");
                //线路用户控件赋值
                this.xianluWindow1.Name        = lineInfo.RouteName;
                this.xianluWindow1.Id          = Convert.ToString(lineInfo.RouteId);
                this.xianluWindow1.publishType = 1;
                //备注
                this.txt_remark.Value = lineInfo.Remark;

                #region 订单游客数据
                EyouSoft.BLL.TourStructure.TourOrder TourOrderBll = new EyouSoft.BLL.TourStructure.TourOrder(SiteUserInfo);
                System.Collections.Generic.IList <EyouSoft.Model.TourStructure.TourOrderCustomer> curList = lineInfo.Traveller.Travellers;
                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\" MaxLength=\"50\" valid=\"required\" errmsg=\"请填写姓名!\" 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\" title=\"请选择\" id=\"cusType\" name=\"cusType\">");
                            stringBuilder.Append("<option value=\"\">请选择</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\" title=\"请选择\"  id=\"cusType\" name=\"cusType\">");
                            stringBuilder.Append("<option value=\"\">请选择</option>");
                            stringBuilder.Append("<option value=\"1\" >成人</option>");
                            stringBuilder.Append("<option value=\"2\" selected=\"selected\">儿童</option>");
                            stringBuilder.Append(" </select>");
                        }
                        //其它
                        else
                        {
                            stringBuilder.Append("<select id=\"cusType\" title=\"请选择\"  name=\"cusType\">");
                            stringBuilder.Append("<option value=\"\"  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("<option value=\"6\">户口本</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("<option value=\"6\">户口本</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("<option value=\"6\">户口本</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("<option value=\"6\">户口本</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("<option value=\"6\">户口本</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\" >港澳通行证</option>");
                            stringBuilder.Append("<option value=\"6\" 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\" MaxLength=\"150\" 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 class='ddlSex' id=\"cusSex\" 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 class='ddlSex' id=\"cusSex\" 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 class='ddlSex' id=\"cusSex\" 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\" MaxLength=\"50\" 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 ? "0" : "1"));
                            stringBuilder.AppendFormat("<input id=\"spe{0}\" type=\"hidden\" name=\"specive\" value=\"{1}\" />", curList[i].ID, str);
                        }
                        else
                        {
                            string special = "";
                            if (curList[i].SpecialServiceInfo != null)
                            {
                                string isadd = curList[i].SpecialServiceInfo.IsAdd ? "0" : "1";
                                special = "txtItem=" + curList[i].SpecialServiceInfo.ProjectName + "&txtServiceContent=" + curList[i].SpecialServiceInfo.ServiceDetail + "&ddlOperate=" + isadd + "&txtCost=" + Utils.FilterEndOfTheZeroDecimal(curList[i].SpecialServiceInfo.Fee);
                            }
                            stringBuilder.AppendFormat("<input id=\"spe{0}\" type=\"hidden\" name=\"specive\" value=\"{1}\" />", curList[i].ID, special);
                        }
                        stringBuilder.AppendFormat("<a sign=\"speService\" href=\"javascript:void(0)\" onclick=\"OrderEdit.OpenSpecive('spe{0}')\">特服</a></td>", curList[i].ID);
                        stringBuilder.Append("<td bgcolor=\"#e3f1fc\" align=\"center\" width=\"15%\">");
                        stringBuilder.AppendFormat("<input type=\"hidden\" name=\"cusID\" value=\"{0}\" />", curList[i].ID);
                        stringBuilder.Append("<a sign=\"add\" href=\"javascript:void(0)\" onclick=\"OrderEdit.AddCus()\">添加</a>&nbsp;");
                        stringBuilder.Append("<input type=\"hidden\" name=\"cusState\" value=\"EDIT\" />");
                        string msg = "";
                        if (TourOrderBll.IsDoDelete(curList[i].ID, ref msg))
                        {
                            stringBuilder.Append("<a sign=\"del\" href=\"javascript:void(0)\" onclick=\"OrderEdit.DelCus($(this))\">删除</a></td></tr>");
                        }
                        else
                        {
                            stringBuilder.AppendFormat("<span>{0}</span>", msg);
                        }
                    }
                }
                cusHtml = stringBuilder.ToString();
                #endregion
            }
            CheckBtn(lineInfo);
            return(lineInfo);
        }
Пример #8
0
        protected void CreatQuicklyTeam()
        {
            int id = Convert.ToInt32(Utils.GetQueryStringValue("id"));

            EyouSoft.Model.TourStructure.LineInquireQuoteInfo lineInfo = SaveInfo(id);                                    //生成页面上取值后的lineInfo
            EyouSoft.Model.RouteStructure.RouteInfo           route    = new EyouSoft.Model.RouteStructure.RouteInfo();   //生成线路信息
            EyouSoft.BLL.RouteStructure.Route         routeBll         = new EyouSoft.BLL.RouteStructure.Route();         //routeBll类
            EyouSoft.Model.TourStructure.TourTeamInfo tourTeamInfo     = new EyouSoft.Model.TourStructure.TourTeamInfo(); //生成团队计划类
            //获取线路
            route = routeBll.GetRouteInfo(lineInfo.RouteId);
            //客户单位编号
            tourTeamInfo.BuyerCId = lineInfo.CustomerId;
            //客户单位名称
            tourTeamInfo.BuyerCName = lineInfo.CustomerName;
            //公司编号
            tourTeamInfo.CompanyId = lineInfo.CompanyId;
            //出团日期
            tourTeamInfo.LDate = (DateTime)lineInfo.LeaveDate;
            //线路编号
            tourTeamInfo.RouteId = lineInfo.RouteId;
            //线路名称
            tourTeamInfo.RouteName = lineInfo.RouteName;
            //客户单位编号
            tourTeamInfo.BuyerCId = lineInfo.CustomerId;
            //客户单位名称
            tourTeamInfo.BuyerCName = lineInfo.CustomerName;
            //公司编号
            tourTeamInfo.CompanyId = lineInfo.CompanyId;
            //发布人编号
            tourTeamInfo.OperatorId = SiteUserInfo.ID;
            //总人数
            tourTeamInfo.PlanPeopleNumber = lineInfo.PeopleNum;
            //团队计划发布类型
            tourTeamInfo.ReleaseType = EyouSoft.Model.EnumType.TourStructure.ReleaseType.Quick;

            if (new EyouSoft.BLL.CompanyStructure.CompanySetting().GetTeamNumberOfPeople(SiteUserInfo.CompanyID) == EyouSoft.Model.EnumType.CompanyStructure.TeamNumberOfPeople.PartNumber)
            {
                tourTeamInfo.TourTeamUnit = new EyouSoft.Model.TourStructure.MTourTeamUnitInfo()
                {
                    NumberCr     = tourTeamInfo.PlanPeopleNumber,
                    NumberEt     = 0,
                    NumberQp     = 0,
                    UnitAmountCr = 0,
                    UnitAmountEt = 0,
                    UnitAmountQp = 0
                };
            }
            else
            {
                tourTeamInfo.TourTeamUnit = null;
            }


            //生成快速发布信息实体
            tourTeamInfo.TourQuickInfo = new EyouSoft.Model.TourStructure.TourQuickPrivateInfo();
            if (lineInfo.XingCheng != null)
            {
                //快速发布——行程内容
                tourTeamInfo.TourQuickInfo.QuickPlan = lineInfo.XingCheng.QuotePlan;
            }
            //快速发布——备注
            tourTeamInfo.TourQuickInfo.Remark = lineInfo.Remark;
            //快速发布——服务标准
            tourTeamInfo.TourQuickInfo.Service = lineInfo.SpecialClaim;



            //销售员ID
            tourTeamInfo.SellerId = SiteUserInfo.ID;
            //我社报价
            tourTeamInfo.TotalAmount = PriceControl1.TotalAmount;
            //团号
            tourTeamInfo.TourCode = this.hid_tourCode.Value;
            //天数
            tourTeamInfo.TourDays = Utils.GetInt(this.hid_dayCount.Value, 1);
            //计调员
            tourTeamInfo.Coordinator = new EyouSoft.Model.TourStructure.TourCoordinatorInfo();
            tourTeamInfo.Coordinator.CoordinatorId = Utils.GetInt(this.hid_peopleId.Value, 0);
            tourTeamInfo.Coordinator.Name          = this.hid_peopleName.Value;
            //包含项目集合
            tourTeamInfo.Services = this.PriceControl1.GetList;
            //区域路线编号
            tourTeamInfo.AreaId = Utils.GetInt(this.hid_areaId.Value, 0);
            TheResult(lineQuoteBll.AddQuote(tourTeamInfo, lineInfo), "Submit");
        }
Пример #9
0
        protected EyouSoft.Model.TourStructure.LineInquireQuoteInfo SaveInfo(int id)
        {
            EyouSoft.Model.TourStructure.LineInquireQuoteInfo lineInfo = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo();
            //预计出团日期
            lineInfo.LeaveDate = Utils.GetDateTime(Utils.GetFormValue(this.txt_BegTime.UniqueID));
            //总人数
            lineInfo.PeopleNum = Utils.GetInt(Utils.GetFormValue(this.txt_peopleCount.UniqueID), 0);
            //状态
            lineInfo.QuoteState = EyouSoft.Model.EnumType.TourStructure.QuoteState.已处理;
            //备注
            lineInfo.Remark = Utils.GetFormValue(this.txt_remark.UniqueID);
            //客人要求集合
            lineInfo.Requirements = ConProjectControl1.GetDataList();
            //线路编号
            lineInfo.RouteId = Utils.GetInt(xianluWindow1.Id);
            //线路名称
            lineInfo.RouteName = xianluWindow1.Name;
            //价格组成集合
            lineInfo.Services = PriceControl1.GetList;
            //总价
            lineInfo.TotalAmount = PriceControl1.TotalAmount;
            //行程
            lineInfo.XingCheng           = new EyouSoft.Model.TourStructure.XingChengMust();
            lineInfo.XingCheng.QuotePlan = Request.Form[this.txtRoutingNeed.UniqueID];
            lineInfo.XingCheng.QuoteId   = id;
            //行程_附件
            string filepath    = string.Empty;
            string oldfilename = string.Empty;
            bool   file_result = EyouSoft.Common.Function.UploadFile.FileUpLoad(Request.Files["routingFile"], "TourQuotePriceFile", out filepath, out oldfilename);

            if (filepath != "")
            {
                lineInfo.XingCheng.PlanAccessory     = filepath;
                lineInfo.XingCheng.PlanAccessoryName = oldfilename;
            }
            else
            {
                if (hid_img_path.Value != "null")
                {
                    lineInfo.XingCheng.PlanAccessory     = hid_img_path.Value;
                    lineInfo.XingCheng.PlanAccessoryName = hid_img_name.Value;
                }
                else
                {
                    lineInfo.XingCheng.PlanAccessoryName = "";
                    lineInfo.XingCheng.PlanAccessory     = "";
                }
            }
            //机票折扣
            lineInfo.TicketAgio = Utils.GetDecimal(Utils.GetFormValue(this.txt_agio.UniqueID));
            //特殊要求
            lineInfo.SpecialClaim = Utils.GetFormValue(this.txt_need.UniqueID);
            //编号
            lineInfo.Id = id;
            //公司ID
            lineInfo.CompanyId = SiteUserInfo.CompanyID;
            //联系人姓名
            lineInfo.ContactTel = Utils.GetFormValue(this.txt_contactTel.UniqueID);
            //联系人电话
            lineInfo.ContactName = Utils.GetFormValue(this.txt_contactName.UniqueID);
            //询价单位编号
            lineInfo.CustomerId = Utils.GetInt(this.hid_QuoteCompanyId.Value, 0);
            //询价单位名称
            lineInfo.CustomerName = Utils.GetFormValue(this.txt_quoteCompany.UniqueID);
            ///////////////////////////////////////游客信息

            int cusLength = Utils.GetFormValues("cusName").Length;

            lineInfo.Traveller            = new EyouSoft.Model.TourStructure.TourEverydayApplyTravellerInfo();
            lineInfo.Traveller.Travellers = new List <EyouSoft.Model.TourStructure.TourOrderCustomer>();
            for (int i = 0; i < cusLength; i++)
            {
                //游客id
                string cusID = Utils.GetFormValues("cusID")[i];
                EyouSoft.Model.TourStructure.TourOrderCustomer toc = new EyouSoft.Model.TourStructure.TourOrderCustomer();
                toc.VisitorName = Utils.GetFormValues("cusName")[i];
                toc.VisitorType = (EyouSoft.Model.EnumType.TourStructure.VisitorType)(Utils.GetInt(Utils.GetFormValues("cusType")[i]));
                toc.CradType    = (EyouSoft.Model.EnumType.TourStructure.CradType)(Utils.GetInt(Utils.GetFormValues("cusCardType")[i]));
                toc.CradNumber  = Utils.GetFormValues("cusCardNo")[i];

                //游客性别
                int cusSex = Utils.GetInt(Utils.GetFormValues("cusSex")[i]);

                #region 性别
                if (cusSex == 1)
                {
                    toc.Sex = EyouSoft.Model.EnumType.CompanyStructure.Sex.男;
                }
                else if (cusSex == 2)
                {
                    toc.Sex = EyouSoft.Model.EnumType.CompanyStructure.Sex.女;
                }
                else
                {
                    toc.Sex = EyouSoft.Model.EnumType.CompanyStructure.Sex.未知;
                }
                #endregion

                toc.ContactTel = Utils.GetFormValues("cusPhone")[i];

                toc.IssueTime = DateTime.Now;
                EyouSoft.Model.TourStructure.CustomerSpecialService specModel = new EyouSoft.Model.TourStructure.CustomerSpecialService();
                if (string.IsNullOrEmpty(cusID))
                {
                    toc.ID = System.Guid.NewGuid().ToString();
                }
                else
                {
                    toc.ID = cusID;
                }

                if (Utils.GetFormValues("cusState")[i] == "DEL")
                {
                    toc.IsDelete = true;
                }
                else
                {
                    toc.IsDelete = false;
                }
                //特服
                string specive = Utils.GetFormValues("specive")[i];
                if (!string.IsNullOrEmpty(specive))
                {
                    if (specive.LastIndexOf(',') + 1 == specive.Length)
                    {
                        specive = specive.Substring(0, specive.Length - 1);
                    }
                    specModel.CustormerId   = toc.ID;
                    specModel.ProjectName   = Server.UrlDecode(Utils.GetFromQueryStringByKey(specive, "txtItem"));
                    specModel.ServiceDetail = Server.UrlDecode(Utils.GetFromQueryStringByKey(specive, "txtServiceContent"));
                    specModel.IsAdd         = Utils.GetFromQueryStringByKey(specive, "ddlOperate") == "0" ? true : false;
                    specModel.Fee           = Utils.GetDecimal(Utils.GetFromQueryStringByKey(specive,
                                                                                             "txtCost"));
                    specModel.IssueTime = DateTime.Now;
                    //特服项目名不能为空,否则不添加该条特服信息
                    if (!string.IsNullOrEmpty(specModel.ProjectName))
                    {
                        toc.SpecialServiceInfo = specModel;
                    }
                }
                lineInfo.Traveller.Travellers.Add(toc);
            }
            ///
            return(lineInfo);
        }
Пример #10
0
        /// <summary>
        /// <summary>
        /// 获取询价报价实体
        /// </summary>
        /// <param name="Id">主键编号</param>
        /// <param name="CompanyId">专线公司编号</param>
        /// <param name="CustomerId">组团公司编号</param>
        /// <param name="isZhuTuan">是否组团端,1是,0不是</param>
        /// <returns></returns>
        public EyouSoft.Model.TourStructure.LineInquireQuoteInfo GetQuoteModel(int Id, int CompanyId, int CustomerId, int isZhuTuan)
        {
            EyouSoft.Model.TourStructure.LineInquireQuoteInfo model = null;
            DbCommand dc = this.DB.GetStoredProcCommand("proc_Tour_GetInquireQuote");

            this.DB.AddInParameter(dc, "CompanyId", DbType.Int32, CompanyId);
            this.DB.AddInParameter(dc, "CustomerId", DbType.Int32, CustomerId);
            this.DB.AddInParameter(dc, "isZhuTuan", DbType.Int32, isZhuTuan);
            this.DB.AddInParameter(dc, "Id", DbType.Int32, Id);
            using (IDataReader dr = DbHelper.RunReaderProcedure(dc, this.DB))
            {
                if (dr.Read())
                {
                    #region 询价报价基本信息
                    model              = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo();
                    model.Id           = dr.GetInt32(dr.GetOrdinal("Id"));
                    model.CompanyId    = dr.IsDBNull(dr.GetOrdinal("CompanyId")) ? 0 : dr.GetInt32(dr.GetOrdinal("CompanyId"));
                    model.RouteId      = dr.IsDBNull(dr.GetOrdinal("RouteId")) ? 0 : dr.GetInt32(dr.GetOrdinal("RouteId"));
                    model.RouteName    = dr["RouteName"].ToString();
                    model.CustomerId   = dr.IsDBNull(dr.GetOrdinal("CustomerId")) ? 0 : dr.GetInt32(dr.GetOrdinal("CustomerId"));
                    model.CustomerName = dr["CustomerName"].ToString();
                    model.ContactName  = dr["ContactName"].ToString();
                    model.ContactTel   = dr["ContactTel"].ToString();
                    model.LeaveDate    = dr.IsDBNull(dr.GetOrdinal("LeaveDate")) ? System.DateTime.Now : dr.GetDateTime(dr.GetOrdinal("LeaveDate"));
                    model.AdultNumber  = dr.IsDBNull(dr.GetOrdinal("AdultNumber")) ? 0 : dr.GetInt32(dr.GetOrdinal("AdultNumber"));
                    model.ChildNumber  = dr.IsDBNull(dr.GetOrdinal("ChildNumber")) ? 0 : dr.GetInt32(dr.GetOrdinal("ChildNumber"));
                    model.PeopleNum    = model.AdultNumber + model.ChildNumber;
                    model.SpecialClaim = dr["SpecialClaim"].ToString();
                    model.TicketAgio   = dr.IsDBNull(dr.GetOrdinal("TicketAgio")) ? 0 : dr.GetDecimal(dr.GetOrdinal("TicketAgio"));
                    model.IssueTime    = dr.IsDBNull(dr.GetOrdinal("IssueTime")) ? System.DateTime.Now : dr.GetDateTime(dr.GetOrdinal("IssueTime"));
                    model.QuoteState   = (EyouSoft.Model.EnumType.TourStructure.QuoteState)dr.GetByte(dr.GetOrdinal("QuoteState"));
                    model.Remark       = dr["Remark"].ToString();
                    model.BuildTourId  = dr["BuildTourId"].ToString();
                    model.TotalAmount  = dr.GetDecimal(dr.GetOrdinal("TotalAmount"));
                    model.Traveller    = new EyouSoft.Model.TourStructure.TourEverydayApplyTravellerInfo();
                    model.Traveller.TravellerDisplayType = (EyouSoft.Model.EnumType.TourStructure.CustomerDisplayType)dr.GetByte(dr.GetOrdinal("TravellerDisplayType"));
                    model.Traveller.TravellerFilePath    = dr["TravellerFilePath"].ToString();
                    model.Traveller.Travellers           = new List <EyouSoft.Model.TourStructure.TourOrderCustomer>();
                    #endregion
                    #region 行程要求
                    EyouSoft.Model.TourStructure.XingChengMust XingChengMust = null;
                    dr.NextResult();
                    if (dr.Read())
                    {
                        XingChengMust = new EyouSoft.Model.TourStructure.XingChengMust()
                        {
                            QuoteId           = dr.IsDBNull(dr.GetOrdinal("QuoteId")) ? 0 : dr.GetInt32(dr.GetOrdinal("QuoteId")),
                            QuotePlan         = dr["QuotePlan"].ToString(),
                            PlanAccessory     = dr["PlanAccessory"].ToString(),
                            PlanAccessoryName = dr["PlanAccessoryName"].ToString()
                        };
                    }
                    model.XingCheng = XingChengMust;
                    #endregion
                    #region 客人要求信息集合
                    IList <EyouSoft.Model.TourStructure.TourServiceInfo> TourServiceInfoList = new List <EyouSoft.Model.TourStructure.TourServiceInfo>();
                    EyouSoft.Model.TourStructure.TourServiceInfo         TourServiceInfo     = null;
                    dr.NextResult();
                    while (dr.Read())
                    {
                        TourServiceInfo = new EyouSoft.Model.TourStructure.TourServiceInfo()
                        {
                            Service     = dr["ConcreteAsk"].ToString(),
                            ServiceType = (EyouSoft.Model.EnumType.TourStructure.ServiceType)dr.GetInt32(dr.GetOrdinal("ItemType"))
                        };
                        TourServiceInfoList.Add(TourServiceInfo);
                    }
                    model.Requirements = TourServiceInfoList;
                    #endregion
                    #region 价格组成信息集合
                    IList <EyouSoft.Model.TourStructure.TourTeamServiceInfo> TourTeamServiceInfoList = new List <EyouSoft.Model.TourStructure.TourTeamServiceInfo>();
                    EyouSoft.Model.TourStructure.TourTeamServiceInfo         TourTeamServiceInfo     = null;
                    dr.NextResult();
                    while (dr.Read())
                    {
                        TourTeamServiceInfo = new EyouSoft.Model.TourStructure.TourTeamServiceInfo()
                        {
                            Service           = dr["Reception"].ToString(),
                            LocalPrice        = dr.IsDBNull(dr.GetOrdinal("LocalQuote")) ? 0 : dr.GetDecimal(dr.GetOrdinal("LocalQuote")),
                            SelfPrice         = dr.IsDBNull(dr.GetOrdinal("MyQuote")) ? 0 : dr.GetDecimal(dr.GetOrdinal("MyQuote")),
                            ServiceType       = (EyouSoft.Model.EnumType.TourStructure.ServiceType)dr.GetInt32(dr.GetOrdinal("ItemId")),
                            LocalPeopleNumber = dr.GetInt32(dr.GetOrdinal("LocalPeopleNumber")),
                            LocalUnitPrice    = dr.GetDecimal(dr.GetOrdinal("LocalUnitPrice")),
                            SelfPeopleNumber  = dr.GetInt32(dr.GetOrdinal("SelfPeopleNumber")),
                            SelfUnitPrice     = dr.GetDecimal(dr.GetOrdinal("SelfUnitPrice"))
                        };
                        TourTeamServiceInfoList.Add(TourTeamServiceInfo);
                    }
                    model.Services = TourTeamServiceInfoList;
                    #endregion

                    #region 游客信息
                    if (dr.NextResult() && model != null)
                    {
                        while (dr.Read())
                        {
                            EyouSoft.Model.TourStructure.TourOrderCustomer traveller = new EyouSoft.Model.TourStructure.TourOrderCustomer()
                            {
                                ID          = dr.GetString(dr.GetOrdinal("TravellerId")),
                                VisitorName = dr["TravellerName"].ToString(),
                                CradType    = (EyouSoft.Model.EnumType.TourStructure.CradType)dr.GetByte(dr.GetOrdinal("CertificateType")),
                                CradNumber  = dr["CertificateCode"].ToString(),
                                Sex         = (EyouSoft.Model.EnumType.CompanyStructure.Sex)dr.GetByte(dr.GetOrdinal("Gender")),
                                VisitorType = (EyouSoft.Model.EnumType.TourStructure.VisitorType)dr.GetByte(dr.GetOrdinal("TravellerType")),
                                ContactTel  = dr["Telephone"].ToString(),
                            };
                            traveller.SpecialServiceInfo = new EyouSoft.Model.TourStructure.CustomerSpecialService()
                            {
                                CustormerId   = traveller.ID,
                                Fee           = !dr.IsDBNull(dr.GetOrdinal("Fee")) ? dr.GetDecimal(dr.GetOrdinal("Fee")) : 0,
                                IsAdd         = !dr.IsDBNull(dr.GetOrdinal("IsAdd")) ? dr.GetByte(dr.GetOrdinal("IsAdd")) == 1 ? true : false : false,
                                ProjectName   = dr["ServiceName"].ToString(),
                                ServiceDetail = dr["ServiceDetail"].ToString()
                            };

                            model.Traveller.Travellers.Add(traveller);
                        }
                    }
                    #endregion
                }
            }
            return(model);
        }
Пример #11
0
        /// <summary>
        /// 获取询价列表
        /// </summary>
        /// <param name="companyId">公司编号(专线:专线公司编号,组团:组团公司编号)</param>
        /// <param name="pageSize">每页显示的记录数</param>
        /// <param name="pageIndex">返回第几页</param>
        /// <param name="recordCount">返回的记录数</param>
        /// <param name="isZhuTuan">专线:False,组团:True</param>
        /// <returns></returns>
        public IList <EyouSoft.Model.TourStructure.LineInquireQuoteInfo> GetInquireList(int companyId, int pageSize, int pageIndex, ref int recordCount, bool isZhuTuan, EyouSoft.Model.TourStructure.LineInquireQuoteSearchInfo SearchInfo)
        {
            IList <EyouSoft.Model.TourStructure.LineInquireQuoteInfo> items = new List <EyouSoft.Model.TourStructure.LineInquireQuoteInfo>();

            EyouSoft.Model.TourStructure.LineInquireQuoteInfo item = null;
            StringBuilder cmdQuery      = new StringBuilder();
            string        tableName     = "tbl_CustomerQuote";
            string        primaryKey    = "Id";
            string        orderByString = "IssueTime DESC";
            StringBuilder fields        = new StringBuilder();

            #region 要查询的字段
            fields.Append(" Id,LeaveDate,RouteName,CustomerId,AdultNumber+ChildNumber AS PeopleNum,(select name from tbl_Customer where Id=tbl_CustomerQuote.CustomerId) as CustomerName,ContactName,ContactTel,QuoteState,");
            fields.Append("(select TourCode from tbl_Tour where TourId=tbl_CustomerQuote.BuildTourId) as TourCode,");
            //fields.Append("(select RouteName from tbl_Tour where TourId=tbl_CustomerQuote.BuildTourId) as RouteName,");
            fields.Append("(select TourDays from tbl_Tour where TourId=tbl_CustomerQuote.BuildTourId) as TourDays");
            //fields.Append("(select LeaveDate from tbl_Tour where TourId=tbl_CustomerQuote.BuildTourId) as ChuTuanDate");
            fields.Append(" ,IssueTime ");
            #endregion
            #region 拼接查询条件
            if (isZhuTuan)
            {
                cmdQuery.AppendFormat(" CustomerId={0} AND IsDelete=0", companyId);
            }
            else
            {
                cmdQuery.AppendFormat(" CompanyId={0} AND IsDelete=0", companyId);
            }
            if (SearchInfo != null)
            {
                if (!string.IsNullOrEmpty(SearchInfo.TourNo) || SearchInfo.DayNum != 0)
                {
                    cmdQuery.Append(" AND EXISTS(SELECT 1 FROM tbl_Tour AS A WHERE A.TourId=tbl_CustomerQuote.BuildTourId ");

                    if (!string.IsNullOrEmpty(SearchInfo.TourNo))
                    {
                        cmdQuery.AppendFormat(" AND A.TourCode LIKE '%{0}%' ", SearchInfo.TourNo);
                    }
                    if (SearchInfo.DayNum != 0)
                    {
                        cmdQuery.AppendFormat(" AND A.TourDays={0} ", SearchInfo.DayNum);
                    }

                    cmdQuery.Append(" ) ");
                }
                if (!String.IsNullOrEmpty(SearchInfo.RouteName))
                {
                    cmdQuery.AppendFormat(" AND RouteName like  '%{0}%'", SearchInfo.RouteName);
                }
                if (SearchInfo.SDate.HasValue && SearchInfo.SDate != DateTime.MinValue)
                {
                    cmdQuery.AppendFormat(" AND LeaveDate>'{0}' ", SearchInfo.SDate.Value.AddDays(-1));
                }
                if (SearchInfo.EDate.HasValue && SearchInfo.EDate != DateTime.MinValue)
                {
                    cmdQuery.AppendFormat(" AND LeaveDate<'{0}' ", SearchInfo.EDate.Value.AddDays(1));
                }
                if (SearchInfo.XunTuanETime.HasValue)
                {
                    cmdQuery.AppendFormat(" AND IssueTime<'{0}' ", SearchInfo.XunTuanETime.Value.AddDays(1));
                }
                if (SearchInfo.XunTuanSTime.HasValue)
                {
                    cmdQuery.AppendFormat(" AND IssueTime>'{0}' ", SearchInfo.XunTuanSTime.Value);
                }
            }
            #endregion
            using (IDataReader rdr = DbHelper.ExecuteReader(this.DB, pageSize, pageIndex, ref recordCount, tableName, primaryKey, fields.ToString(), cmdQuery.ToString(), orderByString))
            {
                while (rdr.Read())
                {
                    item = new EyouSoft.Model.TourStructure.LineInquireQuoteInfo()
                    {
                        Id           = rdr.GetInt32(rdr.GetOrdinal("Id")),
                        CustomerId   = rdr.GetInt32(rdr.GetOrdinal("CustomerId")),
                        RouteName    = rdr["RouteName"].ToString(),
                        LeaveDate    = rdr.IsDBNull(rdr.GetOrdinal("LeaveDate")) ? System.DateTime.Now : rdr.GetDateTime(rdr.GetOrdinal("LeaveDate")),
                        PeopleNum    = rdr.IsDBNull(rdr.GetOrdinal("PeopleNum")) ? 0 : rdr.GetInt32(rdr.GetOrdinal("PeopleNum")),
                        CustomerName = rdr["CustomerName"].ToString(),
                        ContactName  = rdr["ContactName"].ToString(),
                        ContactTel   = rdr["ContactTel"].ToString(),
                        QuoteState   = (EyouSoft.Model.EnumType.TourStructure.QuoteState)rdr.GetByte(rdr.GetOrdinal("QuoteState")),
                        IssueTime    = rdr.GetDateTime(rdr.GetOrdinal("IssueTime"))
                    };
                    items.Add(item);
                }
            }
            return(items);
        }