public void Analysis_OnClick(object sender, EventArgs e) { var siteId = TranslateUtils.ToInt(DdlSiteId.SelectedValue); if (siteId > 0) { PageUtils.Redirect(PageAnalysisSiteChannels.GetRedirectUrl(siteId, TbStartDate.Text, TbEndDate.Text)); } else { PageUtils.Redirect(GetRedirectUrl(TbStartDate.Text, TbEndDate.Text)); } }
private void RptContents_ItemDataBound(object sender, RepeaterItemEventArgs e) { if (e.Item.ItemType != ListItemType.Item && e.Item.ItemType != ListItemType.AlternatingItem) { return; } var siteId = (int)e.Item.DataItem; var siteInfo = SiteManager.GetSiteInfo(siteId); var ltlSiteName = (Literal)e.Item.FindControl("ltlSiteName"); var ltlNewContentNum = (Literal)e.Item.FindControl("ltlNewContentNum"); var ltlUpdateContentNum = (Literal)e.Item.FindControl("ltlUpdateContentNum"); var ltlTotalNum = (Literal)e.Item.FindControl("ltlTotalNum"); ltlSiteName.Text = $@"<a href=""{PageAnalysisSiteChannels.GetRedirectUrl(siteId)}"">{siteInfo.SiteName}</a>"; ltlNewContentNum.Text = GetYHashtable(siteId, YTypeNew); ltlUpdateContentNum.Text = GetYHashtable(siteId, YTypeUpdate); ltlTotalNum.Text = GetHorizental(siteId); }