Example #1
0
        protected void ReportEmail(DataRow row)
        {
            var tr = new HtmlTableRow().AddTo(CurrentHtmlTable, "trReportDetailHeading");
            var td = new HtmlTableCell().AddTo(tr, "tdReportDetail");

            new HtmlAnchor
            {
                HRef = SecureAdminPage.GetPartiesPageUrl(Parties.GetStateCodeFromKey(row.PartyKey()),
                                                         row.PartyKey(), row.PartyEmail()),
                Target    = "edit",
                InnerText = row.PartyEmail()
            }.AddTo(td);
            new HtmlTableCell {
                InnerText = row.PartyContactPhone()
            }.AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyContactFName()
            }.AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyContactLName()
            }.AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyContactTitle()
            }.AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyPassword()
            }.AddTo(tr, "tdReportDetail");
        }
Example #2
0
        protected void ReportParty(DataRow row)
        {
            var tr = new HtmlTableRow().AddTo(CurrentHtmlTable, "trReportDetail");

            new HtmlTableCell {
                InnerText = row.PartyOrder().ToString()
            }
            .AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyKey()
            }
            .AddTo(tr, "tdReportDetail");
            new HtmlTableCell {
                InnerText = row.PartyCode()
            }
            .AddTo(tr, "tdReportDetail");
            var td = new HtmlTableCell().AddTo(tr, "tdReportDetail");

            new HtmlAnchor
            {
                HRef      = SecureAdminPage.GetPartiesPageUrl(row.StateCode(), row.PartyKey()),
                InnerText = row.PartyName(),
                Target    = "edit"
            }.AddTo(td);
            td = new HtmlTableCell().AddTo(tr, "tdReportDetail");
            var url = row.PartyUrl();

            if (IsNullOrWhiteSpace(url))
            {
                td.InnerHtml = " ";
            }
            else
            {
                new HtmlAnchor
                {
                    HRef      = VotePage.NormalizeUrl(url),
                    InnerText = row.PartyUrl(),
                    Title     = "Party Wensite",
                    Target    = "view"
                }
            }.AddTo(td);