コード例 #1
0
        public void DeleteClub(int clubID)
        {
            if (!IsAdmin)
            {
                throw new Exception("Only admin can delete clubs");
            }

            new ClubDA().Delete(clubID);

            CFDataCache.CacheAllClubs();
        }
コード例 #2
0
        /// <summary>
        /// Group stuff
        /// </summary>

        public Club CreateClub(Club club)
        {
            Club newClub = new ClubDA().Insert(club);

            AddClubAreaTag(newClub.ID, GetAreaTagForCountry((Nation)newClub.CountryID).ID);

            CFLogger.RecordClubCreate(CurrentClimber.ID, club.Name, club.ID);

            CFDataCache.CacheAllClubs();

            return(club);
        }
コード例 #3
0
 public void SaveClubLogo(Club club, string imageFileName, byte[] imageBytes)
 {
     club.LogoImageFile = ImageManager.SaveClubLogo(imageFileName, imageBytes, club.ID, club.FriendlyUrlName);
     new ClubDA().Update(club);
     CFDataCache.CacheAllClubs();
 }