protected void Page_Load(object sender, EventArgs e) { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); IList <Johnny.CMS.OM.SeH.Software> list = bll.GetList(null); StringBuilder sb = new StringBuilder(); foreach (Johnny.CMS.OM.SeH.Software software in list) { sb.Append("<div class=\"big-box\">"); sb.Append(" <div class=\"big-box-inner\" style=\"height:140\" >"); sb.Append(" <div class=\"big-box-text\">"); sb.Append(string.Format(" <h4>{0}</h4>", software.SoftwareName)); sb.Append(string.Format(" <p>{0}</p>", software.ShortDescription)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"softwaredetail.aspx?softwareid={0}\">详细信息 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"download.aspx?softwareid={0}\">下载 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"{0}\">帮助文档 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.DownloadUrl)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"releasehistory.aspx?softwareid={0}\">发布历史 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(" </div>"); sb.Append(string.Format(" <div class=\"big-box-image\"><a href=\"softwaredetail.aspx?softwareid={0}\"><img src=\"{1}\" /></a></div>", software.SoftwareId, software.Image)); sb.Append(" </div>"); sb.Append("</div>"); } //lblWebsites.Text = StringHelper.ConvertToHtmlTags(sb.ToString()); lblWebsites.Text = sb.ToString(); }
protected void Page_Load(object sender, EventArgs e) { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); IList<Johnny.CMS.OM.SeH.Software> list = bll.GetList(null); StringBuilder sb = new StringBuilder(); foreach(Johnny.CMS.OM.SeH.Software software in list) { sb.Append("<div class=\"big-box\">"); sb.Append(" <div class=\"big-box-inner\" style=\"height:140\" >"); sb.Append(" <div class=\"big-box-text\">"); sb.Append(string.Format(" <h4>{0}</h4>", software.SoftwareName)); sb.Append(string.Format(" <p>{0}</p>", software.ShortDescription)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"softwaredetail.aspx?softwareid={0}\">详细信息 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"download.aspx?softwareid={0}\">下载 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"{0}\">帮助文档 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.DownloadUrl)); sb.Append(string.Format(" <a class=\"big-box-link\" href=\"releasehistory.aspx?softwareid={0}\">发布历史 <img class=\"arrow\" src=\"images/arrow.png\" /></a>", software.SoftwareId)); sb.Append(" </div>"); sb.Append(string.Format(" <div class=\"big-box-image\"><a href=\"softwaredetail.aspx?softwareid={0}\"><img src=\"{1}\" /></a></div>", software.SoftwareId, software.Image)); sb.Append(" </div>"); sb.Append("</div>"); } //lblWebsites.Text = StringHelper.ConvertToHtmlTags(sb.ToString()); lblWebsites.Text = sb.ToString(); }
private void CreateddlSoftware() { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); ddlSoftware.DataSource = bll.GetList(null); ddlSoftware.DataTextField = "SoftwareName"; ddlSoftware.DataValueField = "SoftwareId"; ddlSoftware.DataBind(); }
public override void getData() { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); myManageGridView.DataSource = bll.GetList(null); myManageGridView.DataBind(); }
private void CreateddlSoftware() { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); ddlSoftware.DataSource = bll.GetList(null); ddlSoftware.DataTextField = "SoftwareName"; ddlSoftware.DataValueField = "SoftwareId"; ddlSoftware.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { //blog Johnny.CMS.BLL.SeH.Blog bll = new Johnny.CMS.BLL.SeH.Blog(); IList<Johnny.CMS.OM.SeH.Blog> list = bll.GetList(); StringBuilder sb = new StringBuilder(); foreach (Johnny.CMS.OM.SeH.Blog blog in list) { sb.Append(string.Format("<li><a href=\"blogdetail.aspx?blogid={0}\">{1}({2})</a></li>", blog.BlogId, blog.Title, DataConvert.GetShortDateString(blog.UpdatedTime))); } lblBlogList.Text = sb.ToString(); //website sb.Length = 0; Johnny.CMS.BLL.SeH.Website bllWebsite = new Johnny.CMS.BLL.SeH.Website(); IList<Johnny.CMS.OM.SeH.Website> listWebsite = bllWebsite.GetList(35); int ix = 0; for (ix = 0; ix < listWebsite.Count; ix++) { if (ix % 12 == 0) sb.Append("<ul>"); sb.Append(string.Format("<li><a href=\"{0}\" target=\"_blank\" title=\"{1}\">{2}</a></li>", listWebsite[ix].URL, listWebsite[ix].Description, listWebsite[ix].WebsiteName)); if (ix == listWebsite.Count - 1) sb.Append("<li><b><a href=\"websites.aspx\">更多 <img class=\"arrowimage\" src=\"images/arrow.png\" /></a></b></li>"); if (ix != 0 && (ix == listWebsite.Count - 1 || ix % 11 == 0)) sb.Append("</ul>"); } lblWebsites.Text = sb.ToString(); //software sb.Length = 0; Johnny.CMS.BLL.SeH.Software bllSoftware = new Johnny.CMS.BLL.SeH.Software(); IList<Johnny.CMS.OM.SeH.Software> listSoftware = bllSoftware.GetList(2); for (ix = 0; ix < listSoftware.Count; ix++) { sb.Append("<div class=\"home-block-inner\">"); sb.Append(string.Format(" <a href=\"softwaredetail.aspx?softwareid={0}\"><img class=\"shot\" src=\"{1}\" /></a>", listSoftware[ix].SoftwareId, listSoftware[ix].Image)); sb.Append(string.Format(" <h3><a href=\"softwaredetail.aspx?softwareid={0}\">{1}</a><span style=\"padding-left:10px\"><img style=\"position:relative;top:-7px;left:4px\" src=\"images/new.gif\"></span></h3>", listSoftware[ix].SoftwareId, listSoftware[ix].SoftwareName)); sb.Append(string.Format(" <p style=\"margin:0 0 8px 0\">{0}</p>", listSoftware[ix].ShortDescription)); sb.Append(" <ul>"); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature1)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature2)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature3)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature4)); sb.Append(" </ul>"); sb.Append(string.Format(" <a href=\"softwaredetail.aspx?softwareid={0}\"><img class=\"learn-more\" src=\"images/learn-more.png\" /></a>", listSoftware[ix].SoftwareId)); sb.Append(" <div style=\"clear:both\"></div>"); sb.Append("</div>"); if (ix == 0) { lblSoftware1.Text = sb.ToString(); sb.Length = 0; } else lblSoftware2.Text = sb.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { //blog Johnny.CMS.BLL.SeH.Blog bll = new Johnny.CMS.BLL.SeH.Blog(); IList <Johnny.CMS.OM.SeH.Blog> list = bll.GetList(); StringBuilder sb = new StringBuilder(); foreach (Johnny.CMS.OM.SeH.Blog blog in list) { sb.Append(string.Format("<li><a href=\"blogdetail.aspx?blogid={0}\">{1}({2})</a></li>", blog.BlogId, blog.Title, DataConvert.GetShortDateString(blog.UpdatedTime))); } lblBlogList.Text = sb.ToString(); //website sb.Length = 0; Johnny.CMS.BLL.SeH.Website bllWebsite = new Johnny.CMS.BLL.SeH.Website(); IList <Johnny.CMS.OM.SeH.Website> listWebsite = bllWebsite.GetList(35); int ix = 0; for (ix = 0; ix < listWebsite.Count; ix++) { if (ix % 12 == 0) { sb.Append("<ul>"); } sb.Append(string.Format("<li><a href=\"{0}\" target=\"_blank\" title=\"{1}\">{2}</a></li>", listWebsite[ix].URL, listWebsite[ix].Description, listWebsite[ix].WebsiteName)); if (ix == listWebsite.Count - 1) { sb.Append("<li><b><a href=\"websites.aspx\">更多 <img class=\"arrowimage\" src=\"images/arrow.png\" /></a></b></li>"); } if (ix != 0 && (ix == listWebsite.Count - 1 || ix % 11 == 0)) { sb.Append("</ul>"); } } lblWebsites.Text = sb.ToString(); //software sb.Length = 0; Johnny.CMS.BLL.SeH.Software bllSoftware = new Johnny.CMS.BLL.SeH.Software(); IList <Johnny.CMS.OM.SeH.Software> listSoftware = bllSoftware.GetList(2); for (ix = 0; ix < listSoftware.Count; ix++) { sb.Append("<div class=\"home-block-inner\">"); sb.Append(string.Format(" <a href=\"softwaredetail.aspx?softwareid={0}\"><img class=\"shot\" src=\"{1}\" /></a>", listSoftware[ix].SoftwareId, listSoftware[ix].Image)); sb.Append(string.Format(" <h3><a href=\"softwaredetail.aspx?softwareid={0}\">{1}</a><span style=\"padding-left:10px\"><img style=\"position:relative;top:-7px;left:4px\" src=\"images/new.gif\"></span></h3>", listSoftware[ix].SoftwareId, listSoftware[ix].SoftwareName)); sb.Append(string.Format(" <p style=\"margin:0 0 8px 0\">{0}</p>", listSoftware[ix].ShortDescription)); sb.Append(" <ul>"); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature1)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature2)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature3)); sb.Append(string.Format(" <li><span>{0}</span></li>", listSoftware[ix].Feature4)); sb.Append(" </ul>"); sb.Append(string.Format(" <a href=\"softwaredetail.aspx?softwareid={0}\"><img class=\"learn-more\" src=\"images/learn-more.png\" /></a>", listSoftware[ix].SoftwareId)); sb.Append(" <div style=\"clear:both\"></div>"); sb.Append("</div>"); if (ix == 0) { lblSoftware1.Text = sb.ToString(); sb.Length = 0; } else { lblSoftware2.Text = sb.ToString(); } } }
public override void getData() { Johnny.CMS.BLL.SeH.Software bll = new Johnny.CMS.BLL.SeH.Software(); myManageGridView.DataSource = bll.GetList(null); myManageGridView.DataBind(); }