File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 1
1
using AutoMapper ;
2
2
using Supermarket . Core . Models ;
3
3
using Supermarket . Extensions ;
4
- using Supermarket . Resources ;
4
+ using Supermarket . V1 . Dtos . AccountDtos ;
5
+ using Supermarket . V1 . Dtos . CategoryDtos ;
6
+ using Supermarket . V1 . Dtos . ProductDtos ;
5
7
6
8
namespace Supermarket . Mapping
7
9
{
8
10
public class ModelToResourceProfile : Profile
9
11
{
10
12
public ModelToResourceProfile ( )
11
13
{
12
- CreateMap < ApplicationUser , UserProfileResource > ( ) ;
14
+ CreateMap < ApplicationUser , UserInfoDto > ( ) ;
13
15
14
- CreateMap < Category , CategoryResource > ( ) ;
16
+ CreateMap < Category , CategoryDto > ( ) ;
15
17
16
- CreateMap < Product , ProductResource > ( )
18
+ CreateMap < Product , ProductDto > ( )
17
19
. ForMember ( src => src . UnitOfMeasurement ,
18
20
opt => opt . MapFrom ( src => src . UnitOfMeasurement . ToDescriptionString ( ) ) ) ;
19
21
}
Original file line number Diff line number Diff line change 1
1
using AutoMapper ;
2
2
using Supermarket . Core . Models ;
3
3
using Supermarket . Resources ;
4
+ using Supermarket . V1 . Dtos . CategoryDtos ;
4
5
5
6
namespace Supermarket . Mapping
6
7
{
7
8
public class ResourceToModelProfile : Profile
8
9
{
9
10
public ResourceToModelProfile ( )
10
11
{
11
- CreateMap < SaveCategoryResource , Category > ( ) ;
12
+ CreateMap < CreateCategoryDto , Category > ( ) ;
12
13
}
13
14
}
14
15
}
You can’t perform that action at this time.
0 commit comments