示例#1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (EyouSoft.Common.Utils.GetInt(Request.QueryString["Page"]) > 1)
            {
                pageIndex = EyouSoft.Common.Utils.GetInt(Request.QueryString["Page"]);
            }
            if (!IsPostBack)
            {
                this.Page.Title = "全国旅游咨询";

                if (Request["TourAreaId"] != null)
                {
                    if (int.Parse(Request["TourAreaId"].ToString()) == 35)
                    {
                        provinceName = "全国";
                    }
                    else
                    {
                        if (EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(int.Parse(Request["TourAreaId"].ToString())) != null)
                        {
                            EyouSoft.Model.SystemStructure.SysProvince model = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(int.Parse(Request["TourAreaId"].ToString()));
                            provinceName = model.ProvinceName;
                        }
                    }
                    InitQuYu(int.Parse(Request["TourAreaId"].ToString()));
                }
            }
        }
示例#2
0
        /// <summary>
        /// 获取公司地址根据相应id
        /// </summary>
        /// <param name="provinceid">省id</param>
        /// <param name="cityid">市id</param>
        /// <param name="countryid">县id</param>
        /// <returns></returns>
        public string GetCompanyAddress(string provinceid, string cityid, string countryid)
        {
            string result = string.Empty;
            int    proid  = Convert.ToInt32(provinceid);
            int    ctid   = Convert.ToInt32(cityid);
            int    cyid   = Convert.ToInt32(countryid);

            EyouSoft.Model.SystemStructure.SysProvince       proviceModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(proid);
            EyouSoft.Model.SystemStructure.SysCity           cityModel    = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(ctid);
            EyouSoft.Model.SystemStructure.SysDistrictCounty countyModel  = EyouSoft.BLL.SystemStructure.SysDistrictCounty.CreateInstance().GetModel(cyid);
            if (proviceModel != null)
            {
                result = proviceModel.ProvinceName + " ";
            }
            if (cityModel != null)
            {
                result += cityModel.CityName + " ";
            }
            if (countyModel != null)
            {
                result += countyModel.DistrictName;
            }

            return(result);
        }
示例#3
0
        protected void rptList_ItemCreated(object sender, RepeaterItemEventArgs e)
        {
            if (e.Item.ItemIndex != -1)
            {
                EyouSoft.Model.CompanyStructure.SupplierInfo model = e.Item.DataItem as EyouSoft.Model.CompanyStructure.SupplierInfo;
                if (model != null)
                {
                    //电话
                    Panel pnlTelPhone = e.Item.FindControl("pnlTelPhone") as Panel;
                    //传真
                    Panel pnlFax = e.Item.FindControl("pnlFax") as Panel;
                    //联系人名
                    Panel pnlContact = e.Item.FindControl("pnlContact") as Panel;

                    //添加城市
                    Label lblCity = e.Item.FindControl("lblCity") as Label;
                    //添加省份
                    Label lblProvince = e.Item.FindControl("lblProvince") as Label;

                    EyouSoft.Model.SystemStructure.SysCity     cityModel = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(model.CityId);
                    EyouSoft.Model.SystemStructure.SysProvince provModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(model.ProvinceId);

                    if (cityModel != null)
                    {
                        lblCity.Text = cityModel.CityName;
                    }
                    if (provModel != null)
                    {
                        lblProvince.Text = provModel.ProvinceName;
                    }

                    if (model.State.CompanyService.IsServiceAvailable(EyouSoft.Model.CompanyStructure.SysService.HighShop))
                    {
                        //添加联系信息
                        Label lblTelPhone = new Label();
                        lblTelPhone.Text = "电&nbsp;&nbsp;话:<span class=\"hong\">" + model.ContactInfo.Tel + "</span>";
                        pnlTelPhone.Controls.Add(lblTelPhone);
                        //添加传真
                        Label lblFax = new Label();
                        lblFax.Text = "传&nbsp;&nbsp;真:<span class=\"hong\">" + model.ContactInfo.Fax + "</span>";
                        pnlFax.Controls.Add(lblFax);

                        //添加联系人名
                        Label lblName = new Label();
                        lblName.Text = "联系人:" + model.ContactInfo.ContactName + "";
                        pnlContact.Controls.Add(lblName);
                    }
                    else
                    {
                        pnlTelPhone.Controls.Clear();
                        pnlFax.Controls.Clear();
                        pnlContact.Controls.Clear();
                    }
                }
            }
        }
示例#4
0
        /// <summary>
        /// 获取省份名称
        /// </summary>
        /// <param name="ProvinceId"></param>
        /// <returns></returns>
        private string GetProvinceName(int ProvinceId)
        {
            string Result = "";

            EyouSoft.Model.SystemStructure.SysProvince model = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(ProvinceId);
            if (model != null)
            {
                Result = model.ProvinceName;
            }
            return(Result);
        }
示例#5
0
        protected void Apply_MQ()
        {
            if (!IsCompanyCheck)
            {
                Utils.ResponseMeg(false, "对不起,你尚未审核通过!");
                return;
            }
            string companyId    = SiteUserInfo.CompanyID;
            string applyContact = Utils.GetFormValue("contact");
            string tel          = Utils.GetFormValue("tel");
            string mobile       = Utils.GetFormValue("mobile");
            string address      = Utils.GetFormValue("address");

            EyouSoft.Model.SystemStructure.SysApplyServiceInfo serviceInfo = new EyouSoft.Model.SystemStructure.SysApplyServiceInfo();
            serviceInfo.ApplyServiceType = EyouSoft.Model.CompanyStructure.SysService.MQ;
            serviceInfo.ApplyTime        = DateTime.Now;
            serviceInfo.CityId           = SiteUserInfo.CityId;
            EyouSoft.Model.SystemStructure.SysCity cityModel = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(SiteUserInfo.CityId);
            if (cityModel != null)
            {
                serviceInfo.CityName = cityModel.CityName;
            }
            serviceInfo.CompanyId      = SiteUserInfo.CompanyID;
            serviceInfo.CompanyName    = SiteUserInfo.CompanyName;
            serviceInfo.ContactAddress = address;
            serviceInfo.ContactMobile  = mobile;
            serviceInfo.ContactMQ      = SiteUserInfo.ContactInfo.MQ;
            serviceInfo.ContactName    = applyContact;
            serviceInfo.ContactQQ      = SiteUserInfo.ContactInfo.QQ;
            serviceInfo.ContactTel     = tel;
            serviceInfo.UserId         = SiteUserInfo.ID;
            EyouSoft.Model.SystemStructure.SysProvince provinceModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(SiteUserInfo.ProvinceId);
            if (provinceModel != null)
            {
                serviceInfo.ProvinceName = provinceModel.ProvinceName;
            }
            serviceInfo.ProvinceId = SiteUserInfo.ProvinceId;
            if (!applyBll.IsApply(SiteUserInfo.CompanyID, EyouSoft.Model.CompanyStructure.SysService.MQ))
            {
                if (applyBll.Apply(serviceInfo))
                {
                    Utils.ResponseMegSuccess();
                }
                else
                {
                    Utils.ResponseMeg(false, "申请失败!");
                }
            }
            else
            {
                Utils.ResponseMeg(false, "你已经提交过申请!");
            }
        }
示例#6
0
        protected string GetProAndCity(int pId, int cId)
        {
            string strCity = "";
            string strPro  = "";

            EyouSoft.Model.SystemStructure.SysCity     city     = cityBll.GetSysCityModel(cId);
            EyouSoft.Model.SystemStructure.SysProvince province = provinceBll.GetProvinceModel(pId);
            if (city != null)
            {
                strCity = city.CityName;
            }
            if (province != null)
            {
                strPro = province.ProvinceName;
            }
            return(strPro + "-" + strCity);
        }
示例#7
0
        /// <summary>
        /// 根据省份ID获取省份名称
        /// </summary>
        /// <param name="ProvinceId">省份ID</param>
        /// <returns></returns>
        protected string GetProvinceNameById(string ProvinceId)
        {
            if (string.IsNullOrEmpty(ProvinceId) || StringValidate.IsInteger(ProvinceId.Trim()) == false || Convert.ToInt32(ProvinceId.Trim()) <= 0)
            {
                return(string.Empty);
            }

            ProvinceModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(int.Parse(ProvinceId));
            if (ProvinceModel != null)
            {
                return(string.Format("【{0}】", ProvinceModel.ProvinceName));
            }
            else
            {
                return(string.Empty);
            }
        }
示例#8
0
        /// <summary>
        /// 根据城市ID获取名称
        /// </summary>
        /// <param name="CityId">城市ID</param>
        /// <returns></returns>
        protected string GetCityNameById(string ProvinceId)
        {
            if (string.IsNullOrEmpty(ProvinceId) || EyouSoft.Common.Function.StringValidate.IsInteger(ProvinceId) == false)
            {
                return(string.Empty);
            }

            EyouSoft.Model.SystemStructure.SysProvince model = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(int.Parse(ProvinceId));
            if (model.Equals(null))
            {
                return(string.Empty);
            }
            else
            {
                return(model.ProvinceName);
            }
        }
示例#9
0
        /// <summary>
        /// 获取省份列表
        /// </summary>
        /// <param name="IsEnabled">是否开通</param>
        /// <returns>返回省份实体集合</returns>
        public virtual IList <EyouSoft.Model.SystemStructure.SysProvince> GetProvinceList(bool IsEnabled)
        {
            IList <Model.SystemStructure.SysProvince> List = new List <Model.SystemStructure.SysProvince>();
            string strSql = Sql_SysProvince_Select;

            if (IsEnabled)
            {
                strSql += " where ID IN(SELECT ProvinceId FROM tbl_SysCity WHERE IsEnabled='1')";
            }
            strSql += " order by SortId,HeaderLetter asc";
            DbCommand dc = base.SystemStore.GetSqlStringCommand(Sql_SysProvince_Select);

            using (IDataReader dr = DbHelper.ExecuteReader(dc, base.SystemStore))
            {
                Model.SystemStructure.SysProvince model = null;
                while (dr.Read())
                {
                    model = new EyouSoft.Model.SystemStructure.SysProvince();
                    if (!dr.IsDBNull(0))
                    {
                        model.ProvinceId = dr.GetInt32(0);
                    }
                    if (!dr.IsDBNull(1))
                    {
                        model.CountryId = dr.GetInt32(1);
                    }
                    model.HeaderLetter = dr[2].ToString();
                    model.ProvinceName = dr[3].ToString();
                    if (!dr.IsDBNull(4))
                    {
                        model.AreaId = (Model.SystemStructure.ProvinceAreaType)dr.GetInt32(4);
                    }
                    if (!dr.IsDBNull(5))
                    {
                        model.SortId = dr.GetInt32(5);
                    }

                    List.Add(model);
                }
                model = null;
            }

            return(List);
        }
示例#10
0
 /// <summary>
 /// 根据ID得到省份名称
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 protected string GetProvNameById(int id)
 {
     if (id > 0)
     {
         EyouSoft.Model.SystemStructure.SysProvince p = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(id);
         if (p != null)
         {
             return(p.ProvinceName);
         }
         else
         {
             return("");
         }
     }
     else
     {
         return("");
     }
 }
示例#11
0
        /// <summary>
        /// 初始化省份
        /// </summary>
        /// <returns></returns>
        public string InitProvince(int ProvinceId)
        {
            StringBuilder strTmp = new StringBuilder();

            EyouSoft.Model.SystemStructure.SysProvince modelP = new EyouSoft.Model.SystemStructure.SysProvince();
            modelP = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(ProvinceId);
            if (IsLogin)
            {
                strTmp.AppendFormat("<a target='_blank' href='{0}'>", EyouSoft.Common.URLREWRITE.SupplierInfo.GetSuplierUrl("", 0, 0, 0, ProvinceId, 0, CityId));
                strTmp.AppendFormat("{0}</a>", modelP == null ? "" : "【" + modelP.ProvinceName + "】");
            }
            else
            {
                strTmp.AppendFormat("<a target='_blank' href='{0}'>", EyouSoft.Common.URLREWRITE.SupplierInfo.GetSuplierUrl("", 0, 0, 0, ProvinceId, 0, CityId));
                strTmp.AppendFormat("{0}</a>", modelP == null ? "" : "【" + modelP.ProvinceName + "】");
            }
            modelP = null;
            return(strTmp.ToString());
        }
示例#12
0
 protected string GetProName(int proid)
 {
     if (proid == 0)
     {
         return("全国");
     }
     else
     {
         EyouSoft.Model.SystemStructure.SysProvince p = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(proid);
         if (p != null)
         {
             return(p.ProvinceName);
         }
         else
         {
             return("全国");
         }
     }
 }
示例#13
0
        protected void Page_Load(object sender, EventArgs e)
        {
            RequestCityID = Utils.GetInt(Request.QueryString["RequestCityID"], 0); //目的地地接社所在城市
            SaleCityID    = CityId;
            ProvinceID    = Utils.GetInt(Request.QueryString["ProvinceID"], 0);    //目的地接社所在省份
            strURL        = Utils.GeneratePublicCenterUrl("/RouteManage/LocalAgencyList.aspx?ProvinceID=" + ProvinceID + "&RequestCityID=" + RequestCityID, CityId);
            if (!Page.IsPostBack)
            {
                InitCityList();

                InitLocalAgencyList();
            }

            //如果 地接社所在城市 条件 不为空,则显示 城市名称
            //如果 地接社所在城市条件 为空,则显示 所在省份名称
            string placeName = string.Empty;//地名

            if (RequestCityID != 0)
            {
                EyouSoft.Model.SystemStructure.SysCity tmpCityModel = null;
                EyouSoft.IBLL.SystemStructure.ISysCity bll          = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance();
                tmpCityModel = bll.GetSysCityModel(RequestCityID);
                if (tmpCityModel != null)
                {
                    placeName = tmpCityModel.CityName;
                }
            }
            else if (ProvinceID != 0)
            {
                EyouSoft.Model.SystemStructure.SysProvince tmpProModel = null;
                EyouSoft.IBLL.SystemStructure.ISysProvince proBll      = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance();
                tmpProModel = proBll.GetProvinceModel(ProvinceID);
                if (tmpProModel != null)
                {
                    placeName = tmpProModel.ProvinceName;
                }
            }

            //根据 地名 格式化 页面标题
            this.Page.Title = string.Format("{0}地接社_{0}地接电话_{0}旅行社大全", placeName);
        }
示例#14
0
        /// <summary>
        /// 获取存在资讯信息的所有省份列表
        /// </summary>
        /// <returns></returns>
        public virtual IList <EyouSoft.Model.SystemStructure.SysProvince> GetExistsNewsProvinceList()
        {
            IList <Model.SystemStructure.SysProvince> List = new List <Model.SystemStructure.SysProvince>();
            string    strSql = Sql_SysProvince_Select + " where Id in(select distinct provinceId from tbl_Affiche) order by SortId,HeaderLetter asc";
            DbCommand dc     = base.SystemStore.GetSqlStringCommand(strSql);

            using (IDataReader dr = DbHelper.ExecuteReader(dc, base.SystemStore))
            {
                Model.SystemStructure.SysProvince model = null;
                while (dr.Read())
                {
                    model = new EyouSoft.Model.SystemStructure.SysProvince();
                    if (!dr.IsDBNull(0))
                    {
                        model.ProvinceId = dr.GetInt32(0);
                    }
                    if (!dr.IsDBNull(1))
                    {
                        model.CountryId = dr.GetInt32(1);
                    }
                    model.HeaderLetter = dr[2].ToString();
                    model.ProvinceName = dr[3].ToString();
                    if (!dr.IsDBNull(4))
                    {
                        model.AreaId = (Model.SystemStructure.ProvinceAreaType)dr.GetInt32(4);
                    }
                    if (!dr.IsDBNull(5))
                    {
                        model.SortId = dr.GetInt32(5);
                    }

                    List.Add(model);
                }
                model = null;
            }

            return(List);
        }
示例#15
0
        protected string GetRelation(object Range, object relases)
        {
            string      result = "";
            IList <int> relas  = relases as IList <int>;

            switch ((EyouSoft.Model.AdvStructure.AdvRange)Enum.Parse(typeof(EyouSoft.Model.AdvStructure.AdvRange), Range.ToString()))
            {
            case EyouSoft.Model.AdvStructure.AdvRange.全国:
                result = "全国";
                break;

            case EyouSoft.Model.AdvStructure.AdvRange.全省:;
                if (relas != null)
                {
                    int num = 0;
                    EyouSoft.Model.SystemStructure.SysProvince province = null;
                    foreach (int item in relas)
                    {
                        province = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(item);
                        if (province != null)
                        {
                            num++;
                            result += province.ProvinceName + ",";
                        }
                        if (num % 4 == 0)
                        {
                            result += "</br>";
                        }
                    }
                    province = null;
                }
                break;

            case EyouSoft.Model.AdvStructure.AdvRange.单位类型:
                break;

            case EyouSoft.Model.AdvStructure.AdvRange.城市:
                if (relas != null)
                {
                    EyouSoft.Model.SystemStructure.SysCity city = null;
                    int num = 0;
                    foreach (int item in relas)
                    {
                        city = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(item);
                        if (city != null)
                        {
                            num++;
                            result += city.CityName + ",";
                        }
                        if (num % 4 == 0)
                        {
                            result += "</br>";
                        }
                    }
                    city = null;
                }
                break;
            }
            if (result != "全国" && result != "")
            {
                return("<a href=\"javascript:void(0)\" onmouseover='wsug(this,\"" + Range.ToString() + ":" + result.Substring(0, result.LastIndexOf(',')) + "\")' onmouseout='wsug(this, 0)'>" + Utils.GetText(result, 5) + "</a>");
            }
            else
            {
                return(result);
            }
        }
示例#16
0
        protected void LoadCompanyInfo()
        {
            if (companyModel != null)
            {
                haveArea = companyModel.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.专线);
                EyouSoft.Model.SystemStructure.SysProvince proviceModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(companyModel.ProvinceId);
                EyouSoft.Model.SystemStructure.SysCity     cityModel    = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(companyModel.CityId);

                EyouSoft.IBLL.SystemStructure.ISysDistrictCounty disBll      = EyouSoft.BLL.SystemStructure.SysDistrictCounty.CreateInstance();
                EyouSoft.Model.SystemStructure.SysDistrictCounty countyModel = disBll.GetModel(companyModel.CountyId);
                if (proviceModel != null)
                {
                    cityName = proviceModel.ProvinceName;
                }
                if (cityModel != null)
                {
                    cityName += "-" + cityModel.CityName;
                }
                if (countyModel != null)
                {
                    if (countyModel.DistrictName.Trim() != "")
                    {
                        cityName += "-" + countyModel.DistrictName;
                    }
                }
                else
                {
                    string districtName = "";
                    IList <EyouSoft.Model.SystemStructure.SysDistrictCounty> disList = disBll.GetDistrictCounty(companyModel.CityId);
                    if (disList != null && disList.Count > 0)
                    {
                        for (int i = 0; i < disList.Count; i++)
                        {
                            districtName += "<option value='" + disList[i].Id.ToString() + "'>" + disList[i].DistrictName + "</option>";
                        }
                    }
                    cityName += "-&nbsp;<select name='sltDistrictName'>" + districtName + "</select>";
                }

                if (companyModel.SaleCity != null)
                {
                    foreach (EyouSoft.Model.SystemStructure.CityBase city in companyModel.SaleCity)
                    {
                        saleCityName += city.CityName + ",";
                    }
                    saleCityName = saleCityName.TrimEnd(',');
                }
                companyName                 = companyModel.CompanyName;
                licenese                    = string.IsNullOrEmpty(companyModel.License) ? "暂无" : companyModel.License;
                cis_txtAdmin.Value          = companyModel.ContactInfo.ContactName;
                this.txtBrandName.Value     = companyModel.CompanyBrand;
                cis_txtCompanyAddress.Value = companyModel.CompanyAddress;
                companyDetail               = companyModel.Remark;
                cis_txtFax.Value            = companyModel.ContactInfo.Fax;
                cis_txtMobile.Value         = companyModel.ContactInfo.Mobile;
                //cis_txtMSN.Value = companyModel.ContactInfo.MSN;
                //cis_txtQQ.Value = companyModel.ContactInfo.QQ;
                cis_txtTel.Value = companyModel.ContactInfo.Tel;
                //初始化账户信息
                List <EyouSoft.Model.CompanyStructure.BankAccount> BankAccountList = companyModel.BankAccounts;
                if (BankAccountList != null)
                {
                    if (BankAccountList.Where(i => i.AccountType == EyouSoft.Model.CompanyStructure.BankAccountType.公司).Count() > 0)
                    {
                        EyouSoft.Model.CompanyStructure.BankAccount companyBankAccount = BankAccountList.Where(i => i.AccountType == EyouSoft.Model.CompanyStructure.BankAccountType.公司).First();
                        cis_Company1.Value        = companyBankAccount.BankAccountName;
                        cis_CompanyAccount1.Value = companyBankAccount.AccountNumber;
                        cis_CompanyBank1.Value    = companyBankAccount.BankName;
                    }
                    cis_rpt_personBank.DataSource = companyModel.BankAccounts.Where(i => i.AccountType == EyouSoft.Model.CompanyStructure.BankAccountType.个人);
                    cis_rpt_personBank.DataBind();
                }
                //地区,省、市、区
                //this.ClientScript.RegisterStartupScript(this.GetType(), Guid.NewGuid().ToString(), string.Format("CompanyInfoSet.InitPlace('{0}','{1}','{2}');",companyModel.ProvinceId,companyModel.CityId,companyModel.CountyId), true);
                this.spanProvinceInfo.InnerHtml = cityName;// string.Format("{0}&nbsp;&nbsp;{1}&nbsp;&nbsp;{2}", proviceModel.ProvinceName, cityModel.CityName, countyModel.DistrictName);
                //管理员账户
                this.txtAdminCode.Value = companyModel.AdminAccount.UserName;
                //同业联系方式
                this.txtTongYeContact.Value = companyModel.PeerContact;
                //销售城市
                StringBuilder strSaleCity = new StringBuilder();
                List <EyouSoft.Model.SystemStructure.CityBase> lstSaleCity = companyModel.SaleCity;
                if (null != lstSaleCity && lstSaleCity.Count > 0)
                {
                    for (int i = 0; i < lstSaleCity.Count; i++)
                    {
                        strSaleCity.Append(lstSaleCity[i].CityName + ";");
                    }
                }
                this.txtSaleCity.InnerHtml = strSaleCity.Length > 0 ? strSaleCity.ToString() : "暂无销售城市";
                //公司简称
                this.txtSimpleName.Value = companyModel.Introduction;
                //客服邮箱
                this.txtEmail.Value         = companyModel.ContactInfo.Email;
                this.ddlScale.SelectedValue = Convert.ToString((int)companyModel.Scale);
                //string strUrl = "<a href=\"" + Domain.FileSystem + "{0}\" target='_blank' style='color:#f00;'>查看</a><a href=\"javascript:void(0);\" onclick=\"CompanyInfoSet.delFile(this)\" title='删除'><img src=\"" + ImageServerUrl + "/images/fujian_x.gif\"/></a>";
                string strUrl = "<a href=\"" + Domain.FileSystem + "{0}\" target='_blank'>查看</a>";
                //支付宝账户
                this.txtAliPay.Value = companyModel.AlipayAccount;
                //用户等级
                this.spanUserLevel.InnerHtml = Convert.ToString(companyModel.CompanyLev);
                //资料完整度
                this.spanInfoLevel.InnerHtml = (int)(companyModel.InfoFull * 100) + "%";
                //签约时间
                this.txtStartTime.Value = string.Format("{0:yyyy-MM-dd}", companyModel.ContractStart);
                this.txtEndTime.Value   = string.Format("{0:yyyy-MM-dd}", companyModel.ContractEnd);
                //业务优势
                this.txtOperation.Value = companyModel.ShortRemark;
                //公司网址
                this.txtWebUrl.Value = companyModel.WebSite;
                //公司经纬度
                if (companyModel.Longitude == 0 && companyModel.Latitude == 0)
                {
                    this.spanMapXY.InnerHtml = "<font style='color:#f00;font-size:12px;'>暂未设置地理位置!</font>";
                }
                else
                {
                    this.hiddenMapXY.Value = companyModel.Longitude + "," + companyModel.Latitude;
                }
                //公司图片开始
                IList <EyouSoft.Model.CompanyStructure.CompanyPublicityPhoto> lstCompanyPic = companyModel.AttachInfo.CompanyPublicityPhoto;
                if (null != lstCompanyPic && lstCompanyPic.Count > 0)
                {
                    for (int i = 0; i < lstCompanyPic.Count; i++)
                    {
                        switch (i)
                        {
                        case 0:
                            this.LtComPic1.Text = string.IsNullOrEmpty(lstCompanyPic[i].ImagePath.Trim()) ? "暂无图片" : string.Format(strUrl, lstCompanyPic[i].ImagePath);
                            MessageBox.ResponseScript(this, string.Format("CompanyInfoSet.setCompPic(0,'{0}');", lstCompanyPic[i].ImagePath));
                            break;

                        case 1:
                            this.LtComPic2.Text = string.IsNullOrEmpty(lstCompanyPic[i].ImagePath.Trim()) ? "暂无图片" : string.Format(strUrl, lstCompanyPic[i].ImagePath);
                            MessageBox.ResponseScript(this, string.Format("CompanyInfoSet.setCompPic(1,'{0}');", lstCompanyPic[i].ImagePath));
                            break;

                        case 2:
                            this.LtComPic3.Text = string.IsNullOrEmpty(lstCompanyPic[i].ImagePath.Trim()) ? "暂无图片" : string.Format(strUrl, lstCompanyPic[i].ImagePath);
                            MessageBox.ResponseScript(this, string.Format("CompanyInfoSet.setCompPic(2,'{0}');", lstCompanyPic[i].ImagePath));
                            break;

                        default:
                            break;
                        }
                    }
                }
                //公司图片结束
                //授权证书//负责人身份证
                this.spanSetRightPic.InnerHtml = string.IsNullOrEmpty(companyModel.AttachInfo.BusinessCertif.WarrantImg) ? "暂无授权证书图片" : string.Format(strUrl, companyModel.AttachInfo.BusinessCertif.WarrantImg);
                this.spanSetIDCard.InnerHtml   = string.IsNullOrEmpty(companyModel.AttachInfo.BusinessCertif.PersonCardImg) ? "暂无负责人身份证图片" : string.Format(strUrl, companyModel.AttachInfo.BusinessCertif.PersonCardImg);
                MessageBox.ResponseScript(this, string.Format("CompanyInfoSet.setRightPicAndIDCard(0,'{0}');CompanyInfoSet.setRightPicAndIDCard(1,'{1}');", companyModel.AttachInfo.BusinessCertif.WarrantImg, companyModel.AttachInfo.BusinessCertif.PersonCardImg));
                //旅行社资质
                IList <EyouSoft.Model.CompanyStructure.CompanyQualification> lstCompetence = companyModel.Qualification;
                StringBuilder strCompetence = new StringBuilder();
                if (null != lstCompetence && lstCompetence.Count > 0)
                {
                    for (int i = 0; i < lstCompetence.Count; i++)
                    {
                        strCompetence.Append(lstCompetence[i] + ";");
                    }
                }
                if (strCompetence.Length == 0)
                {
                    IList <EyouSoft.Common.EnumObj> enQualification = EyouSoft.Common.EnumObj.GetList(typeof(EyouSoft.Model.CompanyStructure.CompanyQualification));
                    if (enQualification != null && enQualification.Count > 0)
                    {
                        for (int i = 0; i < enQualification.Count; i++)
                        {
                            strCompetence.Append("<input type='checkbox' name='cbxQualification'  value='" + enQualification[i].Value + "' />" + enQualification[i].Text + "&nbsp;&nbsp;");
                        }
                    }
                }
                this.spanCompetence.InnerHtml = strCompetence.ToString();
                //经营区域
                StringBuilder strArea = new StringBuilder();
                List <EyouSoft.Model.SystemStructure.AreaBase> areaList = companyModel.Area;
                if (null != areaList && areaList.Count > 0)
                {
                    for (int i = 0; i < areaList.Count; i++)
                    {
                        strArea.AppendFormat("{0}&nbsp;&nbsp;", areaList[i].AreaName);
                    }
                }
                if (strArea.Length > 0)
                {
                    this.trAreas.Visible     = true;
                    this.spanAreas.InnerHtml = strArea.ToString();
                }
                else
                {
                    this.trAreas.Visible = false;
                }
            }
            //加载经营范围
            if (haveArea)
            {
                IList <EyouSoft.Model.SystemStructure.AreaBase> areaList = EyouSoft.BLL.CompanyStructure.CompanyArea.CreateInstance().GetCompanyArea(SiteUserInfo.CompanyID);
                if (areaList != null && areaList.Count > 0)
                {
                    IList <EyouSoft.Model.SystemStructure.AreaBase> longAreaList = areaList.Where(i => i.RouteType == EyouSoft.Model.SystemStructure.AreaType.国内长线).ToList <EyouSoft.Model.SystemStructure.AreaBase>();
                    longCount = longAreaList.Count;
                    pis_rpt_LongAreaList.DataSource = longAreaList;
                    pis_rpt_LongAreaList.DataBind();
                    IList <EyouSoft.Model.SystemStructure.AreaBase> shortAreaList = areaList.Where(i => i.RouteType == EyouSoft.Model.SystemStructure.AreaType.国内短线).ToList <EyouSoft.Model.SystemStructure.AreaBase>();
                    shortCount = shortAreaList.Count;
                    pis_rpt_ShortAreaList.DataSource = shortAreaList;
                    pis_rpt_ShortAreaList.DataBind();
                    IList <EyouSoft.Model.SystemStructure.AreaBase> exitAreaList = areaList.Where(i => i.RouteType == EyouSoft.Model.SystemStructure.AreaType.国际线).ToList <EyouSoft.Model.SystemStructure.AreaBase>();
                    exitCount = exitAreaList.Count;
                    pis_rpt_ExitAreaList.DataSource = exitAreaList;
                    pis_rpt_ExitAreaList.DataBind();
                }
            }
        }
示例#17
0
        /// <summary>
        /// 获得高级网点的实体
        /// </summary>
        public void DataInit(string agencyId)
        {
            EyouSoft.IBLL.CompanyStructure.ISupplierInfo Sdll  = EyouSoft.BLL.CompanyStructure.SupplierInfo.CreateInstance();
            EyouSoft.Model.CompanyStructure.SupplierInfo model = Sdll.GetModel(agencyId);
            if (model != null)
            {
                if (!model.State.CompanyService.IsServiceAvailable(EyouSoft.Model.CompanyStructure.SysService.HighShop))
                {
                    Utils.ShowError("对不起,该网店尚未开通高级!", "SupplyError");
                    return;
                }
                this.ImgHead.ImageUrl = Domain.FileSystem + model.CompanyImg;
                this.lblTitle.Text    = model.CompanyName;
                this.lblContent.Text  = Utils.RemoveHref(model.Remark);
                this.lblUserName.Text = model.ContactInfo.ContactName;
                this.lblTelPhone.Text = model.ContactInfo.Tel;
                this.lblFax.Text      = model.ContactInfo.Fax;
                this.lblAddress.Text  = model.CompanyAddress;

                //设置地区
                EyouSoft.Model.SystemStructure.SysCity     cityModel = EyouSoft.BLL.SystemStructure.SysCity.CreateInstance().GetSysCityModel(model.CityId);
                EyouSoft.Model.SystemStructure.SysProvince provModel = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(model.ProvinceId);

                if (provModel != null && cityModel != null)
                {
                    this.lblDiQu.Text = "" + provModel.ProvinceName + "&nbsp;&nbsp;" + cityModel.CityName + "";
                }

                this.lblUrl.Text = model.WebSite;
                this.MQ          = model.ContactInfo.MQ;
                this.AdvancedControl11.SetAgencyId = agencyId;

                IList <EyouSoft.Model.CompanyStructure.ProductInfo> list = model.ProductInfo;
                if (list != null && list.Count > 0)
                {
                    this.rptContentImgList.DataSource = list.Take(4);
                    this.DataBind();
                }
                if (model.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.景区))
                {
                    this.CityAndMenu1.HeadMenuIndex = 4;
                    this.Page.Title = model.CompanyName + "_景区";
                }
                if (model.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.酒店))
                {
                    this.CityAndMenu1.HeadMenuIndex = 5;
                    this.Page.Title = model.CompanyName + "_酒店";
                    //星级、周边环境
                    this.lblLeaveTitle.Visible    = true;
                    this.lblLeave.Visible         = true;
                    this.lblHuanJingTitle.Visible = true;
                    this.lblHuanJing.Visible      = true;

                    this.lblLeave.Text = HotelLevel(model.CompanyLevel);
                    if (model.CompanyTag.Count > 0)
                    {
                        this.lblHuanJing.Text = "<a>";
                        for (int i = 0; i < model.CompanyTag.Count; i++)
                        {
                            this.lblHuanJing.Text += model.CompanyTag[i].FieldName + " &nbsp";
                        }
                        this.lblHuanJing.Text += "</a>";
                    }
                }
                if (model.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.车队))
                {
                    this.CityAndMenu1.HeadMenuIndex = 6;
                    //this.Page.Title = model.CompanyName + "_车队";
                    //业务优势
                    this.lblRemark.Visible      = true;
                    this.lblRemarkTitle.Visible = true;
                    this.lblRemarkTitle.Text    = "业务优势:";
                    this.lblRemark.Text         = model.ShortRemark;
                    //设置Title.....
                    this.Title = string.Format(EyouSoft.Common.PageTitle.CarDetail_Title, CityModel.CityName, model.CompanyName);
                    AddMetaTag("description", string.Format(EyouSoft.Common.PageTitle.CarDetail_Des, CityModel.CityName, model.CompanyName));
                    AddMetaTag("keywords", EyouSoft.Common.PageTitle.CarDetail_Keywords);
                }
                if (model.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.旅游用品店))
                {
                    this.CityAndMenu1.HeadMenuIndex = 7;
                    //this.Page.Title = model.CompanyName + "_旅游用品店";
                    //主营产品
                    this.lblRemark.Visible      = true;
                    this.lblRemarkTitle.Visible = true;
                    this.lblRemarkTitle.Text    = "主营产品:";
                    this.lblRemark.Text         = model.ShortRemark;
                    //设置Title.....
                    this.Title = string.Format(EyouSoft.Common.PageTitle.TravelDetail_Title, CityModel.CityName, model.CompanyName);
                    AddMetaTag("description", string.Format(EyouSoft.Common.PageTitle.TravelDetail_Des, CityModel.CityName, model.CompanyName));
                    AddMetaTag("keywords", EyouSoft.Common.PageTitle.TravelDetail_Keywords);
                }
                if (model.CompanyRole.HasRole(EyouSoft.Model.CompanyStructure.CompanyType.购物店))
                {
                    this.CityAndMenu1.HeadMenuIndex = 8;
                    this.Page.Title = model.CompanyName + "_购物店";
                    //主营产品
                    this.lblRemark.Visible      = true;
                    this.lblRemarkTitle.Visible = true;
                    this.lblRemarkTitle.Text    = "主营产品:";
                    this.lblRemark.Text         = model.ShortRemark;
                }

                list  = null;
                model = null;
                Sdll  = null;
            }
        }
示例#18
0
        /// <summary>
        /// 行绑定事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void RepeatorList_ItemDataBound(object sender, RepeaterItemEventArgs e)
        {
            if (e.Item.ItemType == ListItemType.AlternatingItem || e.Item.ItemType == ListItemType.Item)
            {
                System.Text.StringBuilder strTmp = null;
                EyouSoft.Model.CommunityStructure.ExchangeList Exchange = (EyouSoft.Model.CommunityStructure.ExchangeList)e.Item.DataItem;
                EyouSoft.Model.SystemStructure.SysProvince     modelP   = null;

                Literal ltr = (Literal)e.Item.FindControl("ltrTagHtml");
                if (ltr != null && Exchange != null && Exchange.ExchangeTagHtml != null)
                {
                    ltr.Text = Exchange.ExchangeTagHtml.TagHTML;
                }

                //初始化省份链接
                Literal ltrProvince = (Literal)e.Item.FindControl("ltrProvince");
                if (ltrProvince != null && Exchange != null)
                {
                    strTmp = new System.Text.StringBuilder();
                    modelP = new EyouSoft.Model.SystemStructure.SysProvince();
                    modelP = EyouSoft.BLL.SystemStructure.SysProvince.CreateInstance().GetProvinceModel(Exchange.ProvinceId);
                    if (IsLogin)
                    {
                        strTmp.AppendFormat("<a href='{0}'>", EyouSoft.Common.URLREWRITE.SupplierInfo.InfoListWrite(Exchange.ProvinceId, CityId));
                        //strTmp.AppendFormat("<a href='{0}'>", Utils.GeneratePublicCenterUrl(string.Format("/SupplierInfo/ExchangeList.aspx?PId={0}", Exchange.ProvinceId), CityId));
                        strTmp.AppendFormat("{0}</a>", modelP == null ? "" : "【" + modelP.ProvinceName + "】");
                    }
                    else
                    {
                        strTmp.AppendFormat("<a href='{0}'>", EyouSoft.Common.URLREWRITE.SupplierInfo.InfoListWrite(Exchange.ProvinceId, CityId));
                        //strTmp.AppendFormat("<a href='{0}'>", Utils.GeneratePublicCenterUrl(string.Format("/SupplierInfo/ExchangeList.aspx?PId={0}", Exchange.ProvinceId), CityId));
                        strTmp.AppendFormat("{0}</a>", modelP == null ? "" : "【" + modelP.ProvinceName + "】");
                    }
                    ltrProvince.Text = strTmp.ToString();
                    modelP           = null;
                    strTmp           = null;
                }
                //初始化标题链接
                Literal ltrTitle = (Literal)e.Item.FindControl("ltrTitle");
                if (ltrTitle != null && Exchange != null)
                {
                    strTmp = new System.Text.StringBuilder();
                    if (IsLogin)
                    {
                        strTmp.AppendFormat("<a href='{0}' title=\"{2}\">{1}</a>",
                                            SiteUserInfo.IsEnable?
                                            EyouSoft.Common.URLREWRITE.SupplierInfo.InfoUrlWrite(Exchange.ID, CityId)
                                :"javascript:alert('您的账户还没有启用,请联系管理员!');return false;",
                                            Utils.GetText(Exchange.ExchangeTitle, 26),
                                            Exchange.ExchangeTitle);
                    }
                    else
                    {
                        //strLoginUrl = EyouSoft.Security.Membership.UserProvider.BuildLoginAndReturnUrl(
                        //EyouSoft.Common.URLREWRITE.SupplierInfo.InfoUrlWrite(Exchange.ID, CityId),
                        // "你目前进行的操作,需要“登录”后才能继续……");
                        //strTmp.AppendFormat("<a href='{0}' title=\"{1}\">", strLoginUrl, Exchange.ExchangeTitle);
                        strTmp.AppendFormat("<a href='{0}' title=\"{1}\">", EyouSoft.Common.URLREWRITE.SupplierInfo.InfoUrlWrite(Exchange.ID, CityId), Exchange.ExchangeTitle);
                        strTmp.AppendFormat("{0}</a>", Utils.GetText(Exchange.ExchangeTitle, 26));
                    }
                    ltrTitle.Text = strTmp.ToString();
                    strTmp        = null;
                }
                //初始化MQ链接
                Literal ltrMQ = (Literal)e.Item.FindControl("ltrMQ");
                if (ltrMQ != null && Exchange != null)
                {
                    ltrMQ.Text = Utils.GetMQ(Exchange.OperatorMQ);
                }

                Exchange = null;
            }
        }