Beispiel #1
0
        public void CategorySubscribe(int catid, bool remove)
        {
            var user   = HttpContext.Current.User.Identity.Name;
            var member = Membership.GetUser(user, true);

            if (member != null && member.ProviderUserKey != null)
            {
                if (remove)
                {
                    Subscriptions.RemoveCategorySubscription((int)member.ProviderUserKey, catid);
                }
                else
                {
                    Subscriptions.AddCategorySubscription((int)member.ProviderUserKey, catid);
                }
            }
        }