Rename directories and projects
This commit is contained in:
46
Back/skydiveLogs-api.DomainBusiness/UserImageService.cs
Normal file
46
Back/skydiveLogs-api.DomainBusiness/UserImageService.cs
Normal file
@@ -0,0 +1,46 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using skydiveLogs_api.DomainBusiness.Interfaces;
|
||||
using skydiveLogs_api.Domain;
|
||||
using skydiveLogs_api.DomainService.Repositories;
|
||||
|
||||
|
||||
namespace skydiveLogs_api.DomainBusiness
|
||||
{
|
||||
public class UserImageService : IUserImageService
|
||||
{
|
||||
public UserImageService(IUserImageRepository imageRepository)
|
||||
{
|
||||
_imageRepository = imageRepository;
|
||||
}
|
||||
|
||||
public void AddNewImage(UserImage newImage, User connectedUser)
|
||||
{
|
||||
newImage.User = connectedUser;
|
||||
_imageRepository.Add(newImage);
|
||||
}
|
||||
|
||||
public void DeleteImageById(int id)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public UserImage GetImageById(int id)
|
||||
{
|
||||
return _imageRepository.GetById(id);
|
||||
}
|
||||
|
||||
public IEnumerable<UserImage> GetAllImages(User connectedUser)
|
||||
{
|
||||
return _imageRepository.GetAll(connectedUser);
|
||||
}
|
||||
|
||||
public void UpdateImage(int id, UserImage Image)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
private readonly IUserImageRepository _imageRepository;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user