2024-11-25 23:46:53 +04:00
|
|
|
using Contracts.DTO;
|
|
|
|
using Contracts.ViewModels;
|
|
|
|
|
|
|
|
namespace Contracts.Mappers;
|
|
|
|
|
|
|
|
public static class SpendingGroupMapper
|
|
|
|
{
|
2024-11-27 01:47:00 +04:00
|
|
|
public static SpendingGroupViewModel ToView(this SpendingGroupDto dto)
|
2024-11-25 23:46:53 +04:00
|
|
|
=> new()
|
|
|
|
{
|
2024-11-27 01:47:00 +04:00
|
|
|
Id = dto.Id,
|
|
|
|
Name = dto.Name,
|
|
|
|
ChangeRecords = dto.ChangeRecords.Select(x => x.ToView()).ToList()
|
2024-11-25 23:46:53 +04:00
|
|
|
};
|
|
|
|
}
|