| | |
| | | var mapper = new MapperConfiguration(cfg => |
| | | { |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceSetting, PBS.Dto.ElecPriceSetting>(); |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceVmo, PBS.Dto.UpdateElecPriceInput>(); |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceVmo, PBS.Dto.AddElecPriceInput>(); |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceMonthSetting, PBS.Dto.ElecPriceMonthSetting>(); |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceHourSetting, PBS.Dto.ElecPriceHourSetting>(); |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceVmo, PBS.Dto.UpdateElecPriceInput>() |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceVmo, PBS.Dto.AddElecPriceInput>() |
| | | .ForMember(dest => dest.Settings, opt => opt.MapFrom(src => src.Settings)); |
| | | }).CreateMapper(); |
| | | var dto = mapper.Map<PBS.Vmo.ElecPriceVmo, PBS.Dto.AddElecPriceInput>(vmo); |
| | |
| | | cfg.CreateMap<PBS.Vmo.ElecPriceVmo, PBS.Dto.UpdateElecPriceInput>() |
| | | .ForMember(dest => dest.Settings, opt => opt.MapFrom(src => src.Settings)); |
| | | }).CreateMapper(); |
| | | var dtoList = mapper.Map<List<PBS.Vmo.ElecPriceVmo>, List<PBS.Dto.UpdateElecPriceInput>>(vmoList); |
| | | var dtoList = mapper.Map<List<PBS.Vmo.ElecPriceVmo>, List<PBS.Dto.UpdateElecPriceInput>>(vmoList); |
| | | return dtoList; |
| | | } |
| | | } |