16 lines
421 B
C#
16 lines
421 B
C#
using Contracts.DTO;
|
|
using Contracts.ViewModels;
|
|
|
|
namespace Contracts.Mappers;
|
|
|
|
public static class ChangeRecordMapper
|
|
{
|
|
public static ChangeRecordViewModel ToView(this ChangeRecordDto dto)
|
|
=> new()
|
|
{
|
|
Id = dto.Id,
|
|
Sum = dto.Sum,
|
|
ChangedAt = dto.ChangedAt.ToString("dd.MM.yyyy"),
|
|
SpendingGroupName = dto.SpendingGroupName ?? string.Empty
|
|
};
|
|
} |