protected void Page_Load(object sender, EventArgs e) { this.Paging.PageNumber = UrlParameters.PageNumber; this.Paging.PageSize = UrlParameters.PageSize; if (!this.UrlParameters.CategoryIdentifierSpecified) { this.StoryList.DataBind(StoryCache.GetPopularStories(this.HostProfile.HostID, false, this.UrlParameters.StoryListSortBy, this.UrlParameters.PageNumber, this.UrlParameters.PageSize)); this.Paging.RecordCount = StoryCache.GetPopularStoriesCount(this.HostProfile.HostID, false, this.UrlParameters.StoryListSortBy); this.Paging.BaseUrl = UrlFactory.CreateUrl(UrlFactory.PageName.Home) + "/upcoming/popular/" + this.UrlParameters.StoryListSortBy.ToString().ToLower(); } else { this.StoryList.DataBind(StoryCache.GetCategoryStories(this.UrlParameters.CategoryID, false, this.HostProfile.HostID, this.UrlParameters.PageNumber, this.UrlParameters.PageSize)); this.Paging.RecordCount = StoryCache.GetCategoryStoryCount(this.UrlParameters.CategoryID, false, this.HostProfile.HostID); this.Paging.BaseUrl = UrlFactory.CreateUrl(UrlFactory.PageName.ViewCategoryNewStories, this.UrlParameters.CategoryIdentifier); } switch (this.UrlParameters.StoryListSortBy) { case StoryListSortBy.Today: this.PageName = UrlFactory.PageName.UpcomingToday; break; case StoryListSortBy.PastWeek: this.PageName = UrlFactory.PageName.UpcomingWeek; break; default: this.PageName = UrlFactory.PageName.NewStories; break; } }
protected void Page_Load(object sender, EventArgs e) { this.RenderRssChannel(StoryDataTableToRss.ConvertToRssChannel( StoryCache.GetCategoryStories(this.UrlParameters.CategoryID, false, this.HostProfile.HostID, 1, 25), this.HostProfile.SiteTitle + " - new " + this.UrlParameters.CategoryIdentifier + " stories", "the newest " + this.UrlParameters.CategoryIdentifier + " stories from " + this.HostProfile.SiteTitle, this.HostProfile.RootUrl + "/", this.HostProfile)); }
protected void Page_Load(object sender, EventArgs e) { this.StoryList.DataBind(StoryCache.GetCategoryStories(this.UrlParameters.CategoryID, true, this.HostProfile.HostID, this.UrlParameters.PageNumber, this.UrlParameters.PageSize)); this.Paging.RecordCount = StoryCache.GetCategoryStoryCount(this.UrlParameters.CategoryID, true, this.HostProfile.HostID); this.Paging.PageNumber = UrlParameters.PageNumber; this.Paging.PageSize = UrlParameters.PageSize; this.Paging.BaseUrl = UrlFactory.CreateUrl(UrlFactory.PageName.ViewCategory, this.UrlParameters.CategoryIdentifier); }
protected void Page_Load(object sender, EventArgs e) { //TODO: config this.RenderRssChannel(StoryDataTableToRss.ConvertToRssChannel( StoryCache.GetCategoryStories(this.UrlParameters.CategoryID, true, this.HostProfile.HostID, 1, 25), this.HostProfile.SiteTitle + " - published " + this.UrlParameters.CategoryIdentifier + " stories", "the latest published " + this.UrlParameters.CategoryIdentifier + " stories from " + this.HostProfile.SiteTitle, this.HostProfile.RootUrl + "/", this.HostProfile)); }
protected void Page_Load(object sender, EventArgs e) { this.Paging.PageNumber = UrlParameters.PageNumber; this.Paging.PageSize = UrlParameters.PageSize; if (this.UrlParameters.StoryListSortBy == Incremental.Kick.Common.Enums.StoryListSortBy.RecentlyPromoted) { this.UrlParameters.StoryListSortBy = Incremental.Kick.Common.Enums.StoryListSortBy.LatestUpcoming; } if (!this.UrlParameters.CategoryIdentifierSpecified) { this.StoryList.DataBind(StoryCache.GetAllStories(false, this.HostProfile.HostID, this.UrlParameters.PageNumber, this.UrlParameters.PageSize)); this.Paging.RecordCount = StoryCache.GetStoryCount(this.HostProfile.HostID, false); this.Paging.BaseUrl = UrlFactory.CreateUrl(UrlFactory.PageName.Home) + "/upcoming"; } else { this.StoryList.DataBind(StoryCache.GetCategoryStories(this.UrlParameters.CategoryID, false, this.HostProfile.HostID, this.UrlParameters.PageNumber, this.UrlParameters.PageSize)); this.Paging.RecordCount = StoryCache.GetCategoryStoryCount(this.UrlParameters.CategoryID, false, this.HostProfile.HostID); this.Paging.BaseUrl = UrlFactory.CreateUrl(UrlFactory.PageName.ViewCategoryNewStories, this.UrlParameters.CategoryIdentifier); } }