/// <summary> /// 订单下面的游客信息汇总 /// </summary> /// <param name="orderId">订单编号</param> /// <param name="tourId">团队编号</param> protected void InitPageForOrder(string orderId) { EyouSoft.BLL.TourStructure.BTourOrder BLL = new EyouSoft.BLL.TourStructure.BTourOrder(); IList <EyouSoft.Model.TourStructure.BuyCompanyTraveller> list = BLL.GetTourOrderBuyCompanyTravellerByOrderId(orderId); if (list != null && list.Count > 0) { this.rpt_CustomerList.DataSource = list.Where(p => p.TravellerStatus == TravellerStatus.在团); this.rpt_CustomerList.DataBind(); } EyouSoft.Model.TourStructure.MTourOrderExpand model = BLL.GetTourOrderExpandByOrderId(orderId); EyouSoft.BLL.TourStructure.BTour BTour = new EyouSoft.BLL.TourStructure.BTour(); if (model != null) { EyouSoft.Model.TourStructure.MTourBaseInfo tourModel = BTour.GetBasicTourInfo(model.TourId); if (tourModel != null) { this.lbRouteName.Text = tourModel.RouteName; this.lbTourCode.Text = tourModel.TourCode; this.lbName.Text = tourModel.OperatorInfo.Name + (string.IsNullOrEmpty(tourModel.OperatorInfo.Mobile) ? "" : "/" + tourModel.OperatorInfo.Mobile); if (tourModel.GuideList != null && tourModel.GuideList.Count > 0) { this.lbGuid.Text = tourModel.GuideList.First().Name + (string.IsNullOrEmpty(tourModel.GuideList.First().Phone) ? "" : "/" + tourModel.GuideList.First().Phone); } if (tourModel.TourPlaner != null && tourModel.TourPlaner.Count > 0) { this.lbTourPlaner.Text = tourModel.TourPlaner.First().Planer + (string.IsNullOrEmpty(tourModel.TourPlaner.First().Phone) ? "" : "/" + tourModel.TourPlaner.First().Phone); } } } }
/// <summary> /// 页面加载 /// </summary> /// <param name="tourId"></param> protected void InitPage(string tourId, string type) { EyouSoft.BLL.TourStructure.BTour BTour = new EyouSoft.BLL.TourStructure.BTour(); EyouSoft.Model.TourStructure.MTourBaseInfo model = BTour.GetTourInfo(tourId); if (model != null) { this.lbRouteName.Text = model.RouteName; this.lbTourCode.Text = model.TourCode; } EyouSoft.BLL.TourStructure.BTourOrder BLL = new EyouSoft.BLL.TourStructure.BTourOrder(); IList <EyouSoft.Model.TourStructure.MTourOrderSummary> list = BLL.GetTourOrderSummaryByTourId(tourId); if (list != null && list.Count > 0) { if (type == "1") { rpt_OrderList.DataSource = list.Where(i => i.OrderStatus == EyouSoft.Model.EnumType.TourStructure.OrderStatus.已留位); } else { rpt_OrderList.DataSource = list.Where(i => i.OrderStatus == EyouSoft.Model.EnumType.TourStructure.OrderStatus.已成交); } rpt_OrderList.DataBind(); } }
protected void PageInit(string tourId) { //根据计划Id获取预设车型集合 EyouSoft.BLL.TourStructure.BTour BLL = new EyouSoft.BLL.TourStructure.BTour(); IList <MTourCarType> list = BLL.GetTourCarType(tourId); if (list != null && list.Count > 0) { this.PresetBusType1.PreSetTypeList = list; } this.PresetBusType1.TourId = tourId; this.PresetBusType1.ContrloModel = "updateTrue"; EyouSoft.Model.TourStructure.MTourBaseInfo baseModel = BLL.GetBasicTourInfo(tourId); if (baseModel != null && baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.组团散拼短线) { if (baseModel.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.封团) { this.ph_Save.Visible = false; } if (baseModel.SaleInfo != null) { this.OperateID.Value = baseModel.SaleInfo.SellerId; } } }
/// <summary> /// 团队下面的游客信息汇总 /// </summary> /// <param name="tourId">团队编号</param> protected void InitPageForTour(string tourId, string type) { EyouSoft.BLL.TourStructure.BTour BTour = new EyouSoft.BLL.TourStructure.BTour(); EyouSoft.Model.TourStructure.MTourBaseInfo model = BTour.GetBasicTourInfo(tourId); if (model != null) { this.lbRouteName.Text = model.RouteName; this.lbTourCode.Text = model.TourCode; this.lbName.Text = model.OperatorInfo.Name + (string.IsNullOrEmpty(model.OperatorInfo.Mobile) ? "" : "/" + model.OperatorInfo.Mobile); if (model.GuideList != null && model.GuideList.Count > 0) { this.lbGuid.Text = model.GuideList.First().Name + (string.IsNullOrEmpty(model.GuideList.First().Phone) ? "" : "/" + model.GuideList.First().Phone); } if (model.TourPlaner != null && model.TourPlaner.Count > 0) { this.lbTourPlaner.Text = model.TourPlaner.First().Planer + (string.IsNullOrEmpty(model.TourPlaner.First().Phone) ? "" : "/" + model.TourPlaner.First().Phone); } } EyouSoft.BLL.TourStructure.BTourOrder BLL = new EyouSoft.BLL.TourStructure.BTourOrder(); IList <EyouSoft.Model.TourStructure.BuyCompanyTraveller> list = new List <EyouSoft.Model.TourStructure.BuyCompanyTraveller>(); int[] arry = null; switch (type) { case "1": arry = new int[] { (int)OrderStatus.已留位 }; list = BLL.GetTourOrderBuyCompanyTravellerById(tourId, arry); break; case "2": arry = new int[] { (int)OrderStatus.已成交 }; list = BLL.GetTourOrderBuyCompanyTravellerById(tourId, arry); break; default: list = BLL.GetTourOrderBuyCompanyTravellerById(tourId, new int[] { (int)OrderStatus.已成交 }); break; } if (list != null && list.Count > 0) { this.rpt_CustomerList.DataSource = list.Where(i => i.TravellerStatus == EyouSoft.Model.EnumType.TourStructure.TravellerStatus.在团).ToList(); this.rpt_CustomerList.DataBind(); } }
/// <summary> /// 是否显示查看链接 /// </summary> /// <param name="orderid"></param> /// <param name="tourid"></param> /// <returns></returns> protected string GetIsShow(object orderid, object tourid) { EyouSoft.BLL.TourStructure.BTour bll = new EyouSoft.BLL.TourStructure.BTour(); EyouSoft.Model.TourStructure.MTourBaseInfo model = bll.GetTourInfo(Convert.ToString(tourid)); System.Text.StringBuilder str = new System.Text.StringBuilder(); if (model != null) { if (model.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.组团散拼短线) { EyouSoft.BLL.TourStructure.BTourOrder bllorder = new EyouSoft.BLL.TourStructure.BTourOrder(); IList <EyouSoft.Model.TourStructure.MTourOrderSeatInfo> list = bllorder.GetTourOrderSeatInfo(tourid.ToString()); if (list != null && list.Count > 0) { str.AppendFormat("<a href='javascript:void(0);' data-class='showCarModel' data-peonum='{0}' data-tourid='{1}' data-orderid='{2}'>查看</a>", GetPeopleNum(Convert.ToString(orderid)), Convert.ToString(tourid), Convert.ToString(orderid)); } } } return(str.ToString()); }
/// <summary> /// 页面初始化 /// </summary> /// <param name="id">操作ID</param> protected void PageInit(string id) { EyouSoft.BLL.TourStructure.BTour bll = new EyouSoft.BLL.TourStructure.BTour(); EyouSoft.Model.TourStructure.MTourBaseInfo baseModel = bll.GetTourInfo(id); if (baseModel != null && (baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.出境团队 || baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.地接团队 || baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.组团团队)) { EyouSoft.Model.TourStructure.MTourTeamInfo model = (EyouSoft.Model.TourStructure.MTourTeamInfo)baseModel; if (model.TourCode.Trim() != "") { this.lblTourCode.Text = model.TourCode; } BindAreaList(model.AreaId); this.hideRouteID.Value = model.RouteId; this.txt_RouteName.Text = model.RouteName; this.txt_Days.Text = model.TourDays.ToString(); this.UC_CustomerUnitSelect.CustomerUnitId = model.CompanyInfo != null ? model.CompanyInfo.CompanyId : ""; this.UC_CustomerUnitSelect.CustomerUnitName = model.CompanyInfo != null ? model.CompanyInfo.CompanyName : ""; this.txt_Contact.Text = model.CompanyInfo != null ? model.CompanyInfo.Contact : ""; this.txt_ConTel.Text = model.CompanyInfo != null ? model.CompanyInfo.Phone : ""; this.hideContactDeptId.Value = model.ContactDepartId; if (act == "copy") { this.SellsSelect1.SellsID = SiteUserInfo.UserId; this.SellsSelect1.SellsName = SiteUserInfo.Name; lblTourCode.Text = ""; } else { this.SellsSelect1.SellsID = model.SaleInfo.SellerId; this.SellsSelect1.SellsName = model.SaleInfo.Name; } this.txt_Adult.Text = model.Adults.ToString(); this.txt_Child.Text = model.Childs.ToString(); this.txtPlanContent.Text = model.PlanFeature; this.txtAdultPrice.Text = Utils.FilterEndOfTheZeroDecimal(model.AdultPrice); this.txtChildPrice.Text = Utils.FilterEndOfTheZeroDecimal(model.ChildPrice); this.txtOtherPrice.Text = Utils.FilterEndOfTheZeroDecimal(model.OtherCost); this.txtSumPrice.Text = Utils.FilterEndOfTheZeroDecimal(model.SumPrice); this.txtQuoteRemark.Text = model.QuoteRemark; this.CountryID = model.CountryId.ToString(); this.ProvinceID = model.ProvinceId.ToString(); if (model.OutQuoteType == EyouSoft.Model.EnumType.TourStructure.TourQuoteType.分项) { this.ForeignQuote1.IsTourOrSubentry = false; this.ForeignQuote1.StandardTourList = model.TourTeamPrice; } else { this.ForeignQuote1.IsTourOrSubentry = true; this.ForeignQuote1.GroupService = model.TourService != null ? model.TourService.ServiceStandard : ""; } this.Journey1.SetPlanList = model.TourPlan; CostAccounting1.CostCalculation = model.CostCalculation; if (model.TourService != null) { CostAccounting1.NoNeedItem = model.TourService.NoNeedItem; CostAccounting1.ShoppingItem = model.TourService.ShoppingItem; CostAccounting1.ChildServiceItem = model.TourService.ChildServiceItem; CostAccounting1.OwnExpense = model.TourService.OwnExpense; CostAccounting1.NeedAttention = model.TourService.NeedAttention; CostAccounting1.WarmRemind = model.TourService.WarmRemind; CostAccounting1.InsiderInfor = model.TourService.InsiderInfor; } this.txtLDate.Text = model.LDate.HasValue ? model.LDate.Value.ToString("yyyy-MM-dd") : ""; this.txtSuccesssStraffBegin.Text = model.LTraffic; this.txtSuccesssStraffEnd.Text = model.RTraffic; this.txtSuccessGather.Text = model.Gather; this.txtSuccessAddPrice.Text = Utils.FilterEndOfTheZeroDecimal(model.SaleAddCost); this.txtSuccessAddPriceRemark.Text = model.AddCostRemark; this.txtSuccessReducePrice.Text = Utils.FilterEndOfTheZeroDecimal(model.SaleReduceCost); this.txtSuccessReducePriceRemark.Text = model.ReduceCostRemark; this.txtSuccessGuideIncome.Text = Utils.FilterEndOfTheZeroDecimal(model.GuideIncome); this.lblSuccessSalerIncome.Text = Utils.FilterEndOfTheZeroDecimal(model.SalerIncome); this.txtSuccessOrderRemark.Text = model.OrderRemark; if (act != "copy") { txtHeTongHao.HeTongId = model.HeTongId; txtHeTongHao.HeTongCode = model.HeTongCode; } //签证附件 if (model.VisaFileList != null && model.VisaFileList.Count > 0) { string visaStr = string.Empty; for (int i = 0; i < model.VisaFileList.Count; i++) { visaStr += "<span class='upload_filename'> <a href='" + model.VisaFileList[i].FilePath + "' target='_blank'>" + model.VisaFileList[i].Name + "</a><a href='javascript:void(0);' onclick='AddTeamPlan.RemoveVisaFile(this);return false;'> <img style='vertical-align:middle' src='/images/cha.gif'></a><input type='hidden' name='hideVisaFile' value='" + model.VisaFileList[i].Name + "|" + model.VisaFileList[i].FilePath + "|" + model.VisaFileList[i].Downloads.ToString() + "'>;</span>"; } this.lblVisaFiles.Text = visaStr; } switch (model.TourType) { case EyouSoft.Model.EnumType.TourStructure.TourType.地接团队: case EyouSoft.Model.EnumType.TourStructure.TourType.组团团队: this.phdTravelControlS.Visible = false; this.TravelControl1.SetTravelList = model.Traveller; break; case EyouSoft.Model.EnumType.TourStructure.TourType.出境团队: this.phdTravelControl.Visible = false; this.TravelControlS1.SetTravelList = model.Traveller; break; } #region 修改控制 this.phdSave.Visible = false; if (model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.销售未派计划 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调未接收 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调配置 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调配置完毕 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.资金超限 ) { this.phdSave.Visible = true; } if (act == "copy") { this.phdSave.Visible = true; } //按钮权限控制 BtnPowerControl(); //是否可以操作该数据 if (!SiteUserInfo.IsHandleElse && act != "copy") { if (model.OperatorInfo != null && model.OperatorInfo.OperatorId != SiteUserInfo.UserId && model.SaleInfo != null && model.SaleInfo.SellerId != SiteUserInfo.UserId) { this.phdSave.Visible = false; } } #endregion #region 变更控制 if (model.TourStatus != EyouSoft.Model.EnumType.TourStructure.TourStatus.销售未派计划) { this.hideIsChangeInput.Value = "true"; } else { this.hideIsChangeInput.Value = "false"; } #endregion switch (model.TourStatus) { case EyouSoft.Model.EnumType.TourStructure.TourStatus.垫付申请: this.hideOverrunState.Value = "3"; break; case EyouSoft.Model.EnumType.TourStructure.TourStatus.审核失败: this.hideOverrunState.Value = "4"; break; } } else { Utils.ResponseGoBack(); } }
/// <summary> /// 页面初始化 /// </summary> /// <param name="id">操作ID</param> protected void PageInit(string id) { #region 用户控件初始化 #endregion EyouSoft.BLL.TourStructure.BTour bll = new EyouSoft.BLL.TourStructure.BTour(); EyouSoft.Model.TourStructure.MTourBaseInfo baseModel = bll.GetTourInfo(id); if (baseModel != null && (baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.出境散拼 || baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.地接散拼 || baseModel.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.组团散拼)) { EyouSoft.Model.TourStructure.MTourSanPinInfo model = (EyouSoft.Model.TourStructure.MTourSanPinInfo)baseModel; #region 表单控件赋值 this.lblLeaveDateMore.Text = "出团日期:"; BindAreaList(model.AreaId); this.cbxDistribution.Checked = model.IsShowDistribution; this.hideRouteID.Value = model.RouteId; this.txt_RouteName.Text = model.RouteName; this.txt_Days.Text = model.TourDays.ToString(); this.txtPeopleCount.Text = model.PlanPeopleNumber.ToString(); this.lblLeaveDate.Text = UtilsCommons.GetDateString(model.LDate, this.ProviderToDate); this.hideLeaveDate.Value = model.LDate.HasValue ? model.LDate.Value.ToString("yyyy-MM-dd") : ""; this.txtSuccesssStraffBegin.Text = model.LTraffic; this.txtSuccesssStraffEnd.Text = model.RTraffic; this.txtSuccessGather.Text = model.Gather; this.txtStopDate.Text = model.StopDays.ToString(); if (act == "copy") { this.SellsSelect1.SellsID = SiteUserInfo.UserId; this.SellsSelect1.SellsName = SiteUserInfo.Name; } else { this.SellsSelect1.SellsID = model.SaleInfo.SellerId; this.SellsSelect1.SellsName = model.SaleInfo.Name; } this.txtPlanContent.Text = model.PlanFeature; this.txtSearchKey.Text = model.KeyName; // 报价标准 this.PriceStand1.InitMode = false; this.PriceStand1.InitTour = true; this.PriceStand1.SetPriceStandard = model.MTourPriceStandard; //行程安排 this.Journey1.SetPlanList = model.TourPlan; //散拼 服务 if (model.TourService != null) { CostAccounting1.ServiceStandard = model.TourService.ServiceStandard; CostAccounting1.NoNeedItem = model.TourService.NoNeedItem; CostAccounting1.ShoppingItem = model.TourService.ShoppingItem; CostAccounting1.ChildServiceItem = model.TourService.ChildServiceItem; CostAccounting1.OwnExpense = model.TourService.OwnExpense; CostAccounting1.NeedAttention = model.TourService.NeedAttention; CostAccounting1.WarmRemind = model.TourService.WarmRemind; CostAccounting1.InsiderInfor = model.TourService.InsiderInfor; } #endregion #region 附件 //附件 if (model.FilePath.Trim() != "") { this.lblFiles.Text = "<span class='upload_filename'> <a href='" + model.FilePath + "' target='_blank'>查看附件</a><a href='javascript:void(0);' onclick='AddSanPlan.RemoveVisaFile(this);return false;'> <img style='vertical-align:middle' src='/images/cha.gif'></a><input type='hidden' name='hideOtherFile' value='|" + model.FilePath + "'></span>"; } //签证附件 if (model.VisaFileList != null && model.VisaFileList.Count > 0) { string visaStr = string.Empty; for (int i = 0; i < model.VisaFileList.Count; i++) { visaStr += "<span class='upload_filename'> <a href='" + model.VisaFileList[i].FilePath + "' target='_blank'>" + model.VisaFileList[i].Name + "</a><a href='javascript:void(0);' onclick='AddSanPlan.RemoveVisaFile(this);return false;'> <img style='vertical-align:middle' src='/images/cha.gif'></a><input type='hidden' name='hideVisaFile' value='" + model.VisaFileList[i].Name + "|" + model.VisaFileList[i].FilePath + "|" + model.VisaFileList[i].Downloads.ToString() + "'></span>"; } this.lblVisaFiles.Text = visaStr; } #endregion #region 修改控制 this.phdSave.Visible = false; if (model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.销售未派计划 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调未接收 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调配置 || model.TourStatus == EyouSoft.Model.EnumType.TourStructure.TourStatus.计调配置完毕 ) { //供应商发布的散拼计划不能修改 if (model.SourceId.Trim() != "") { this.phdSave.Visible = false; } else { this.phdSave.Visible = true; } } if (act == "copy") { this.phdSave.Visible = true; } //按钮权限控制 BtnPowerControl(); //是否可以操作该数据 if (!SiteUserInfo.IsHandleElse && act != "copy") { if (model.OperatorInfo != null && model.OperatorInfo.OperatorId != SiteUserInfo.UserId && model.SaleInfo != null && model.SaleInfo.SellerId != SiteUserInfo.UserId) { this.phdSave.Visible = false; } } #endregion #region 变更控制 if (model.TourStatus != EyouSoft.Model.EnumType.TourStructure.TourStatus.销售未派计划) { this.hideIsChangeInput.Value = "true"; } else { this.hideIsChangeInput.Value = "false"; } #endregion } else { Utils.ResponseGoBack(); } }