Example #1
0
        public bool Delete(GalleryPoolDTO gallery)
        {
            var category = _galleryPoolRepository.First(x => x.Id == gallery.Id);

            if (category != null)
            {
                _galleryPoolRepository.Delete(category);
                return(true);
            }

            return(false);
        }
Example #2
0
 public bool Add(GalleryPoolDTO gallery)
 {
     return(_galleryPoolRepository.Add(new GalleryPool()
     {
         GalleryId = gallery.GalleryId,
         Thumbnail = gallery.Thumbnail,
         ImagePath = gallery.ImagePath,
         ImageSize = gallery.ImageSize,
         PathExtension = gallery.PathExtension,
         RecordDate = DateTime.Now
     }));
 }