28 lines
794 B
C#
28 lines
794 B
C#
using Musify.Domain.Entities;
|
|
|
|
namespace Musify.Application.PlayLists.Responses
|
|
{
|
|
public record PlayListResponse(
|
|
Guid Id,
|
|
string Name,
|
|
string Description,
|
|
string SmallImageKeyName,
|
|
string MediumImageKeyName,
|
|
string LargeImageKeyName,
|
|
DateTime CreatedAt,
|
|
DateTime UpdatedAt)
|
|
{
|
|
public static PlayListResponse FromEntity(PlayList playList)
|
|
{
|
|
return new PlayListResponse(
|
|
playList.Id,
|
|
playList.Name,
|
|
playList.Description,
|
|
playList.SmallPictureName,
|
|
playList.MediumPictureName,
|
|
playList.LargePictureName,
|
|
playList.CreatedDate,
|
|
playList.UpdatedDate);
|
|
}
|
|
}
|
|
} |