protected void DataModelInti(string id, string planType) { EyouSoft.BLL.PlanStruture.TravelAgency travelbll = new EyouSoft.BLL.PlanStruture.TravelAgency(); //travelbll.GetTravelModel(""); EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo travelModel = travelbll.GetTravelModel(id); if (travelModel != null) { //地接社名称 this.txtDiJieName.Text = travelModel.LocalTravelAgency; //地接社编号 this.hideDiJieID.Value = travelModel.TravelAgencyID.ToString(); //获得地接社的返利 EyouSoft.Model.CompanyStructure.CompanySupplier djModel = new EyouSoft.BLL.CompanyStructure.CompanySupplier().GetModel(travelModel.TravelAgencyID, SiteUserInfo.CompanyID); if (djModel != null) { this.hideCommission.Value = djModel.Commission.ToString("0.00"); } //联系人 this.txtContact.Text = travelModel.Contacter; //电话 this.txtPhone.Text = travelModel.ContactTel; //接团时间 this.txtBeginTime.Text = travelModel.ReceiveTime.ToString("yyyy-MM-dd"); //送团时间 this.txtEndTime.Text = travelModel.DeliverTime.ToString("yyyy-MM-dd"); //接待行程 IList <EyouSoft.Model.PlanStructure.LocalAgencyTourPlanInfo> tourList = travelModel.LocalAgencyTourPlanInfoList; //设置选中 if (travelModel.LocalAgencyTourPlanInfoList != null && travelModel.LocalAgencyTourPlanInfoList.Count > 0) { for (int i = 0; i < travelModel.LocalAgencyTourPlanInfoList.Count; i++) { this.hideXingCheng.Value += travelModel.LocalAgencyTourPlanInfoList[i].Days + ","; } } //判断 价格组成 为A or B IList <EyouSoft.Model.PlanStructure.TravelAgencyPriceInfo> priceList = travelModel.TravelAgencyPriceInfoList; this.rptProjectB.DataSource = priceList; this.rptProjectB.DataBind(); this.rptProjectA.DataSource = priceList; this.rptProjectA.DataBind(); //团款 this.txtTeamPrice.Text = travelModel.Fee.ToString("0.00"); //返款 this.txtBackPrice.Text = travelModel.Commission.ToString("0.00"); //结算费用 this.txtSettlePrice.Text = travelModel.Settlement.ToString("0.00"); //支付方式 DdlPayListInit(Convert.ToInt32(travelModel.PayType).ToString()); //地接社须知 this.txtNotes.Text = travelModel.Notice; //备注 this.txtRemarks.Text = travelModel.Remark; } }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; string type = context.Request.QueryString["type"]; string id = context.Request.QueryString["id"]; //登录公司ID EyouSoft.SSOComponent.Entity.UserInfo userModel = EyouSoft.Security.Membership.UserProvider.GetUser(); //如果公司ID为0表示没有公司登录 并返回false if (userModel == null) { context.Response.Write("{Islogin:false}"); return; } if (type != null) { EyouSoft.BLL.PlanStruture.TravelAgency travelbll = new EyouSoft.BLL.PlanStruture.TravelAgency(); if (type == "Delete") { if (id != null && id != "") { bool b = travelbll.DelTravelAgency(id); if (b) { context.Response.Write("OK"); } else { context.Response.Write("Error"); } } } if (type == "GetInfo") { //声明操作对象 EyouSoft.BLL.CompanyStructure.CompanySupplier bll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); EyouSoft.Model.CompanyStructure.CompanySupplier companyModel = bll.GetModel(Utils.GetInt(id), userModel.CompanyID); string returnStr = "{0}||{1}||{2}||{3}"; if (companyModel != null) { if (companyModel.SupplierContact != null && companyModel.SupplierContact.Count > 0) { returnStr = string.Format(returnStr, companyModel.SupplierContact[0].ContactName, companyModel.SupplierContact[0].ContactTel, companyModel.Commission.ToString("0.00"), companyModel.LicenseKey); } else { returnStr = string.Format(returnStr, "", "", companyModel.Commission.ToString("0.00"), companyModel.LicenseKey); } } context.Response.Write(returnStr); } } }
protected bool grantto = false; //导出 #endregion protected void Page_Load(object sender, EventArgs e) { if (!CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_栏目)) { Utils.ResponseNoPermit(global::Common.Enum.TravelPermission.供应商管理_地接_栏目, true); } //权限附值 grantadd = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_新增); grantmodify = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_修改); grantdel = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_删除); grantload = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_导入); grantto = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_导出); //获取当前用户所在公司id this.ucProvince1.CompanyId = CurrentUserCompanyID; //设为常用城市 this.ucProvince1.IsFav = true; //获取当前用户所在公司id this.ucCity1.CompanyId = CurrentUserCompanyID; //是否设为常用城市 this.ucCity1.IsFav = true; //初始化比BLL csBll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); //操作赋值 act = EyouSoft.Common.Utils.GetQueryStringValue("act"); if (!IsPostBack) { switch (act) { //导出 case "toexcel": if (grantto) { CreateExcel("area" + DateTime.Now.ToShortDateString()); } break; //删除 case "areadel": if (grantdel) { AreaDel(); } break; default: //加载数据 DataInit(); break; } } }
/// <summary> /// 删除地接 /// </summary> /// <param name="TravelId">安排地接编号</param> /// <returns></returns> public bool DelTravelAgency(string TravelId) { EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo modelTravel = GetTravelModel(TravelId); if (dal.DeletTravelModel(TravelId)) { //加日志 //AddSysLog("删除"); //维护地接社交易数量 if (modelTravel != null) { EyouSoft.BLL.CompanyStructure.CompanySupplier bllSuplier = new EyouSoft.BLL.CompanyStructure.CompanySupplier();// EyouSoft.BLL.CompanyStructure.CompanySupplier(); EyouSoft.Model.CompanyStructure.CompanySupplier Model = bllSuplier.GetModel(modelTravel.TravelAgencyID, modelTravel.CompanyId); if (Model != null && Model.Id > 0) { EyouSoft.BLL.UtilityStructure.Utility idal = new EyouSoft.BLL.UtilityStructure.Utility(); idal.ServerTradeCount(new int[] { Model.Id }); } //重新计算团队支出 EyouSoft.BLL.UtilityStructure.Utility u = new EyouSoft.BLL.UtilityStructure.Utility(); //价格维护 u.CalculationTourOut(modelTravel.TourId, null); #region LGWR EyouSoft.Model.EnumType.TourStructure.TourType? tourType = new EyouSoft.BLL.TourStructure.Tour().GetTourType(modelTravel.TourId); Model.EnumType.CompanyStructure.SysPermissionClass mokuai = EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.散拼计划_散拼计划; if (tourType != null && tourType == EyouSoft.Model.EnumType.TourStructure.TourType.团队计划) { mokuai = EyouSoft.Model.EnumType.CompanyStructure.SysPermissionClass.团队计划_团队计划; } 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}在" + mokuai.ToString() + "删除了地接安排,安排编号:" + modelTravel.ID + ",计划编号为:" + modelTravel.TourId; logInfo.EventTime = DateTime.Now; logInfo.EventTitle = "删除地接安排"; logInfo.ModuleId = mokuai; logInfo.OperatorId = 0; this.Logwr(logInfo); #endregion return(true); } } return(false); }
protected void rpt_area_ItemDataBound(object sender, RepeaterItemEventArgs e) { EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo item = e.Item.DataItem as EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo; EyouSoft.BLL.CompanyStructure.CompanySupplier bll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); EyouSoft.Model.CompanyStructure.CompanySupplier companyModel = bll.GetModel(item.TravelAgencyID, CurrentUserCompanyID); Literal lt_cName = e.Item.FindControl("lt_cName") as Literal; Literal lt_cTel = e.Item.FindControl("lt_cTel") as Literal; Literal lt_cFax = e.Item.FindControl("lt_cFax") as Literal; if (companyModel != null && companyModel.SupplierContact.Count > 0) { lt_cName.Text = companyModel.SupplierContact[0].ContactName; lt_cTel.Text = companyModel.SupplierContact[0].ContactTel; lt_cFax.Text = companyModel.SupplierContact[0].ContactFax; } }
/// <summary> /// 删除数据 /// </summary> private void AreaDel() { EyouSoft.BLL.CompanyStructure.CompanySupplier csBLL = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); string[] stid = Utils.GetFormValue("tid").Split(','); int[] tid = new int[stid.Length]; for (int i = 0; i < stid.Length; i++) { tid[i] = Utils.GetInt(stid[i]); } bool res = false; //删除 res = csBLL.DeleteSupplierInfo(tid); Response.Clear(); Response.Write(string.Format("{{\"res\":{0}}}", res ? 1 : -1)); Response.End(); }
private void bind(int tid) { //初使化条件 pageIndex = Utils.GetInt(Utils.GetQueryStringValue("page"), 1); EyouSoft.Model.TourStructure.MTimesSummaryDiJieSearchInfo searchinfo = new EyouSoft.Model.TourStructure.MTimesSummaryDiJieSearchInfo(); DateTime?SDate = Utils.GetDateTimeNullable(Utils.GetQueryStringValue("date")); DateTime?LDate = Utils.GetDateTimeNullable(Utils.GetQueryStringValue("LDate")); int? PayStatus = Utils.GetIntNull(Utils.GetQueryStringValue("status")); if (SDate != null) { this.txt_Date.Value = Convert.ToDateTime(SDate).ToString("yyyy-MM-dd"); } searchinfo.SDate = SDate; if (LDate != null) { this.txt_Date1.Value = Convert.ToDateTime(LDate).ToString("yyyy-MM-dd"); } searchinfo.EDate = LDate; if (SeleState.Items.FindByValue(PayStatus.ToString()) != null) { SeleState.Items.FindByValue(PayStatus.ToString()).Selected = true; } searchinfo.PayStatus = PayStatus; IList <EyouSoft.Model.TourStructure.LBGYSTours> list = null; EyouSoft.BLL.TourStructure.Tour tBll = new EyouSoft.BLL.TourStructure.Tour(); list = tBll.GetToursGYS(CurrentUserCompanyID, pageSize, pageIndex, ref recordCount, tid, searchinfo); len = list == null ? 0 : list.Count; this.repList.DataSource = list; this.repList.DataBind(); //设置合计 EyouSoft.Model.SupplierStructure.MTimesSummaryDiJieInfo djInfoModel = new EyouSoft.BLL.CompanyStructure.CompanySupplier().GetTimesSummaryDiJie(SiteUserInfo.CompanyID, tid, searchinfo); if (djInfoModel != null) { this.lblCommissionAmount.Text = Utils.FilterEndOfTheZeroString(djInfoModel.CommAmount.ToString("0.00")); this.lblNotPayAmount.Text = Utils.FilterEndOfTheZeroString(djInfoModel.NotPayAmount.ToString("0.00")); this.lblSettlementAmount.Text = Utils.FilterEndOfTheZeroString(djInfoModel.TotalAmount.ToString("0.00")); this.lblPeopleNum.Text = djInfoModel.PeopleNumber.ToString(); } //设置分页 BindPage(); }
protected bool grantto = false; //导出 #endregion protected void Page_Load(object sender, EventArgs e) { if (!CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_栏目)) { Utils.ResponseNoPermit(global::Common.Enum.TravelPermission.供应商管理_票务_栏目, true); } //权限附值 grantadd = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_新增); grantmodify = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_修改); grantdel = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_删除); grantload = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_导入); grantto = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_票务_导出); this.ucProvince1.CompanyId = CurrentUserCompanyID; this.ucProvince1.IsFav = true; this.ucCity1.CompanyId = CurrentUserCompanyID; this.ucCity1.IsFav = true; csBll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); act = EyouSoft.Common.Utils.GetQueryStringValue("act"); if (!IsPostBack) { switch (act) { case "toexcel": if (grantto) { CreateExcel("ticket" + DateTime.Now.ToShortDateString()); } break; case "ticketdel": if (grantdel) { TicketDel(); } break; default: DataInit(); break; } } }
/// <summary> /// 地接的增加和修改 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void Page_Load(object sender, EventArgs e) { csBll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); csModel = new EyouSoft.Model.CompanyStructure.CompanySupplier(); this.ucProvince1.CompanyId = CurrentUserCompanyID; this.ucProvince1.IsFav = true; this.ucCity1.CompanyId = CurrentUserCompanyID; this.ucCity1.IsFav = true; if (IsPostBack) { Save(); } else { type = Utils.GetQueryStringValue("type"); switch (type) { case "modify": if (CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_修改)) { bind(); } else { Utils.ResponseNoPermit(global::Common.Enum.TravelPermission.供应商管理_地接_修改, false); } break; case "show": show = true; bind(); break; default: if (!CheckGrant(global::Common.Enum.TravelPermission.供应商管理_地接_新增)) { Utils.ResponseNoPermit(global::Common.Enum.TravelPermission.供应商管理_地接_新增, false); } break; } bindProandCity(); } }
protected bool grantto = false; //导出 #endregion protected void Page_Load(object sender, EventArgs e) { if (!CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_栏目)) { Utils.ResponseNoPermit(global::Common.Enum.TravelPermission.供应商管理_其它_栏目, true); } string act = string.Empty; //权限附值 grantadd = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_新增); grantmodify = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_修改); grantdel = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_删除); grantload = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_导入); grantto = CheckGrant(global::Common.Enum.TravelPermission.供应商管理_其它_导出); csBLL = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); act = EyouSoft.Common.Utils.GetQueryStringValue("act"); if (!IsPostBack) { switch (act) { case "toexcel": if (grantto) { CreateExcel("area" + DateTime.Now.ToShortDateString()); } break; case "areadel": if (grantdel) { AreaDel(); } break; default: DataInit(); break; } } }
private void loadXls() { string data = Utils.GetFormValue("dataxls"); string[] s = data.Split(';'); EyouSoft.BLL.CompanyStructure.CompanySupplier csBll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); List <EyouSoft.Model.CompanyStructure.CompanySupplier> list = new List <EyouSoft.Model.CompanyStructure.CompanySupplier>(); for (int i = 0; i < s.Length; i++) { string[] smodel = s[i].Split(','); if (smodel.Length == 6 && !string.IsNullOrEmpty(smodel[0]) && !string.IsNullOrEmpty(smodel[1]) && !string.IsNullOrEmpty(smodel[2])) { EyouSoft.Model.CompanyStructure.CompanySupplier csModel = new EyouSoft.Model.CompanyStructure.CompanySupplier(); csModel.ProvinceName = HttpUtility.UrlDecode(smodel[0]); csModel.CityName = HttpUtility.UrlDecode(smodel[1]); csModel.UnitName = HttpUtility.UrlDecode(smodel[2]); csModel.UnitAddress = HttpUtility.UrlDecode(smodel[3]); csModel.Commission = Utils.GetDecimal(HttpUtility.UrlDecode(smodel[4])); csModel.Remark = HttpUtility.UrlDecode(smodel[5]); csModel.OperatorId = SiteUserInfo.ID; csModel.IssueTime = DateTime.Now; csModel.CompanyId = CurrentUserCompanyID; csModel.AgreementFile = string.Empty; csModel.IsDelete = false; csModel.SupplierType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.地接; csModel.TradeNum = 0; csModel.UnitPolicy = string.Empty; list.Add(csModel); } } bool res = false; res = csBll.ImportExcelData(list); Response.Clear(); Response.Write(string.Format("{{\"res\":{0}}}", res ? 1 : -1)); Response.End(); }
/// <summary> /// 导出Excel /// </summary> public void CreateExcel(string FileName) { IList <EyouSoft.Model.SupplierStructure.SupplierOther> list = null; EyouSoft.BLL.CompanyStructure.CompanySupplier csBLL = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); //导出条件 unionName = EyouSoft.Common.Utils.GetQueryStringValue("unionName"); //获取一条记录,同事获取总记录条数 list = csBLL.GetOtherList(1, 1, ref recordCount, EyouSoft.Model.EnumType.CompanyStructure.SupplierType.航空公司, unionName, CurrentUserCompanyID); //判断记录条数 if (recordCount != 0) { //记录条数>0 获取所有记录 list = csBLL.GetOtherList(recordCount, 1, ref recordCount, EyouSoft.Model.EnumType.CompanyStructure.SupplierType.航空公司, unionName, CurrentUserCompanyID); } Response.Clear(); Response.AppendHeader("Content-Disposition", "attachment;filename=" + FileName + ".xls"); Response.ContentEncoding = System.Text.Encoding.Default; Response.ContentType = "application/ms-excel"; //取得数据表各列标题,各标题之间以\t分割,最后一个列标题后加回车符 StringBuilder sb = new StringBuilder(); sb.AppendFormat("{0}\t{1}\t{2}\t{3}\t{4}\n", "所在地", "单位名称", "联系人", "电话", "传真"); foreach (EyouSoft.Model.SupplierStructure.SupplierOther cs in list) { sb.AppendFormat("{0}\t{1}\t{2}\t{3}\t{4}\n", cs.ProvinceName + " " + cs.CityName, cs.UnitName, cs.SupplierContact == null ? "" : cs.SupplierContact[0].ContactName, cs.SupplierContact == null ? "" : cs.SupplierContact[0].ContactTel, cs.SupplierContact == null ? "" : cs.SupplierContact[0].ContactFax, cs.TradeNum); } Response.Write(sb.ToString()); Response.End(); }
/// <summary> /// 初始化页面 /// </summary> private void Bind() { //BLL EyouSoft.BLL.CompanyStructure.CompanySupplier csBLL = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); //初始化条件 pageIndex = Utils.GetInt(Utils.GetQueryStringValue("page"), 1); //公司名称 unionName = EyouSoft.Common.Utils.GetQueryStringValue("unionName"); //绑定数据 IList <EyouSoft.Model.SupplierStructure.SupplierOther> list = null; list = csBLL.GetOtherList(pageSize, pageIndex, ref recordCount, EyouSoft.Model.EnumType.CompanyStructure.SupplierType.航空公司, unionName, CurrentUserCompanyID); if (!(list == null)) { len = list.Count; this.rptList.DataSource = list; this.rptList.DataBind(); list = null; } //设置分页 BindPage(); }
/// <summary> /// /// </summary> protected void DataInit(string djName) { EyouSoft.Model.EnumType.CompanyStructure.SupplierType sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.地接; if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 5) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.票务; lbSupplerTypeName.InnerText = "票务名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 4) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.保险; lbSupplerTypeName.InnerText = "保险名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 7) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.购物; lbSupplerTypeName.InnerText = "购物名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 3) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.景点; lbSupplerTypeName.InnerText = "景点名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 1) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.酒店; lbSupplerTypeName.InnerText = "酒店名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 9) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.其他; lbSupplerTypeName.InnerText = "其它名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 8) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.车队; lbSupplerTypeName.InnerText = "车队名称:"; } if (Utils.GetInt(Utils.GetQueryStringValue("sType"), 0) == 2) { sType = EyouSoft.Model.EnumType.CompanyStructure.SupplierType.餐馆; lbSupplerTypeName.InnerText = "餐馆名称:"; } //声明操作对象 EyouSoft.BLL.CompanyStructure.CompanySupplier bll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); //查询地接社数据,获得列表list IList <EyouSoft.Model.CompanyStructure.CompanySupplier> list = bll.GetList(pageSize, pageIndex, ref recordCount, sType, 0, 0, djName, this.CurrentUserCompanyID); if (list != null && list.Count > 0) { this.rptList.DataSource = list; this.rptList.DataBind(); //设置分页 BindPage(); } else { //没有数据时隐藏分页控件 并 提示信息 this.ExportPageInfo1.Visible = false; this.lblMsg.Text = "没有找到相关信息!"; } }
/// <summary> /// 页面初始化方法 /// </summary> /// <param name="tourId">行程单ID</param> protected void DataInit(string tourId) { //声明bll对象 EyouSoft.BLL.TourStructure.Tour bll = new EyouSoft.BLL.TourStructure.Tour(SiteUserInfo); //声明团队计划对象 EyouSoft.Model.TourStructure.TourTeamInfo model = (EyouSoft.Model.TourStructure.TourTeamInfo)bll.GetTourInfo(tourId); if (model != null) { #region 页面控件赋值 //出团日期 LeaveDate = model.LDate.ToString("yyyy-MM-dd"); //出发交通 lblBegin = model.LTraffic; //组团社 this.txtZutuanName.Text = model.BuyerCName; //联系信息 EyouSoft.BLL.CompanyStructure.CompanySupplier supplierBll = new EyouSoft.BLL.CompanyStructure.CompanySupplier(); EyouSoft.Model.CompanyStructure.CompanySupplier companyModel = supplierBll.GetModel(model.BuyerCId, SiteUserInfo.CompanyID); if (companyModel != null) { if (companyModel.SupplierContact != null && companyModel.SupplierContact.Count > 0) { this.txtIncomeMan.Text = companyModel.SupplierContact[0].ContactName; this.txtFax.Text = companyModel.SupplierContact[0].ContactFax; } } //集合时间 lblGatheredDate.Text = model.GatheringTime; //送团人 if (model.SentPeoples != null && model.SentPeoples.Count > 0) { this.txtOffName.Text = model.SentPeoples[0].OperatorName; } this.txtAddress.Text = model.GatheringPlace; //返程交通 lblEnd = model.RTraffic; if (model.TourNormalInfo != null) { //不含项目 this.lblNoProject.Text = EyouSoft.Common.Function.StringValidate.TextToHtml(model.TourNormalInfo.BuHanXiangMu); //购物安排 this.lblBuy.Text = EyouSoft.Common.Function.StringValidate.TextToHtml(model.TourNormalInfo.GouWuAnPai); //注意事项 this.lblNote.Text = EyouSoft.Common.Function.StringValidate.TextToHtml(model.TourNormalInfo.ZhuYiShiXiang); //行程安排 if (model.TourNormalInfo.Plans != null) { this.listCount = model.TourNormalInfo.Plans.Count; tdCount = model.TourNormalInfo.Plans.Count; this.rptTravel.DataSource = model.TourNormalInfo.Plans; this.rptTravel.DataBind(); } } //人数 #region 人数And结算价 if (model.TourType == EyouSoft.Model.EnumType.TourStructure.TourType.团队计划) { TourQuotePrint priantTQP = new TourQuotePrint(); string number = string.Empty; string money = string.Empty; priantTQP.getPepoleNum(SiteUserInfo.CompanyID, model.PlanPeopleNumber, model.TourTeamUnit, ref number, ref money); this.lblAdult.Text = number; } else { this.lblAdult.Text = model.PlanPeopleNumber.ToString(); } #endregion //团队类型 this.txtTourType.Text = model.TourType.ToString(); //包含项目 this.rptProject.DataSource = model.Services; this.rptProject.DataBind(); #endregion } }
protected void DataListInitfirst(string tourid) { if (tourid != null) { //地接的操作BLL EyouSoft.BLL.PlanStruture.TravelAgency travelbll = new EyouSoft.BLL.PlanStruture.TravelAgency(); EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo travelModel = new EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo(); //获得该计划下的所有地接的集合 IList <EyouSoft.Model.PlanStructure.LocalTravelAgencyInfo> list = travelbll.GetList(tourid); travelModel = travelbll.GetTravelModel(list[0].ID); if (travelModel != null) { //地接社名称 this.LitDjName.Text = travelModel.LocalTravelAgency; //地接社编号 this.hideDiJieID.Value = travelModel.TravelAgencyID.ToString(); //获得地接社的返利 EyouSoft.Model.CompanyStructure.CompanySupplier djModel = new EyouSoft.BLL.CompanyStructure.CompanySupplier().GetModel(travelModel.TravelAgencyID, SiteUserInfo.CompanyID); if (djModel != null) { this.hideCommission.Value = djModel.Commission.ToString("0.00"); } //联系人 this.LitName.Text = travelModel.Contacter; //电话 this.LitPhone.Text = travelModel.ContactTel; //接团时间 this.LitBeginTime.Text = travelModel.ReceiveTime.ToString("yyyy-MM-dd"); //送团时间 this.LitEndTime.Text = travelModel.DeliverTime.ToString("yyyy-MM-dd"); //接待行程 IList <EyouSoft.Model.PlanStructure.LocalAgencyTourPlanInfo> tourList = travelModel.LocalAgencyTourPlanInfoList; //设置选中 if (travelModel.LocalAgencyTourPlanInfoList != null && travelModel.LocalAgencyTourPlanInfoList.Count > 0) { for (int i = 0; i < travelModel.LocalAgencyTourPlanInfoList.Count; i++) { this.hideXingCheng.Value += travelModel.LocalAgencyTourPlanInfoList[i].Days + ","; } } //判断 价格组成 为A or B IList <EyouSoft.Model.PlanStructure.TravelAgencyPriceInfo> priceList = travelModel.TravelAgencyPriceInfoList; this.rptProjectB.DataSource = priceList; this.rptProjectB.DataBind(); this.rptProjectA.DataSource = priceList; this.rptProjectA.DataBind(); //团款 this.litTeamPrice.Text = travelModel.Fee.ToString("0.00"); //返款 this.litBackPrice.Text = travelModel.Commission.ToString("0.00"); //结算费用 this.litSettlePrice.Text = travelModel.Settlement.ToString("0.00"); //支付方式 this.litPayType.Text = travelModel.PayType.ToString(); //地接社须知 this.litNotes.Text = travelModel.Notice; //备注 this.litRemarks.Text = travelModel.Remark; } } }