public void BindPage() { PanelAddPaymentType.Visible = false; ButtonAddPaymentType.Visible = true; AspDotNetStorefrontCore.Customer adnsfCustomer = AspDotNetStorefrontCore.Customer.Current; ListViewCreditCards.DataSource = DataUtility.GetPaymentProfiles(adnsfCustomer.CustomerID, adnsfCustomer.EMail); ListViewCreditCards.DataBind(); }
public void BindPage() { SkinBase page = HttpContext.Current.Handler as SkinBase; AspDotNetStorefrontCore.Customer adnsfCustomer; if (page != null) { adnsfCustomer = page.ThisCustomer; } else { adnsfCustomer = AspDotNetStorefrontCore.Customer.Current; } ListViewCreditCards.DataSource = DataUtility.GetPaymentProfiles(adnsfCustomer.CustomerID, adnsfCustomer.EMail); ListViewCreditCards.DataBind(); PanelNoSavedCards.Visible = ListViewCreditCards.Items.Count <= 0; }