|
@@ -24,7 +24,13 @@ namespace MTWorkHR.Application.Mapper
|
|
.ForMember(m => m.UserRoles, op => op.Ignore())
|
|
.ForMember(m => m.UserRoles, op => op.Ignore())
|
|
.ForMember(m => m.Id, op => op.Ignore());
|
|
.ForMember(m => m.Id, op => op.Ignore());
|
|
|
|
|
|
- CreateMap<ApplicationUser, UserDto>().ForMember(m => m.Password, op => op.Ignore());
|
|
|
|
|
|
+ CreateMap<ApplicationUser, UserDto>().ForMember(m => m.Password, op => op.Ignore())
|
|
|
|
+ .ForMember(s => s.QualificationName, o => o.MapFrom(s => s.Qualification == null ? "" : GlobalInfo.lang == "ar" ? s.Qualification.NameAr : s.Qualification.NameEn))
|
|
|
|
+ .ForMember(s => s.JobTitleName, o => o.MapFrom(s => s.JobTitle == null ? "" : GlobalInfo.lang == "ar" ? s.JobTitle.NameAr : s.JobTitle.NameEn))
|
|
|
|
+ .ForMember(s => s.IndustryName, o => o.MapFrom(s => s.Industry == null ? "" : GlobalInfo.lang == "ar" ? s.Industry.NameAr : s.Industry.NameEn))
|
|
|
|
+ .ForMember(s => s.CountryName, o => o.MapFrom(s => s.Country == null ? "" : GlobalInfo.lang == "ar" ? s.Country.NameAr : s.Country.NameEn))
|
|
|
|
+ .ForMember(s => s.UniversityName, o => o.MapFrom(s => s.University == null ? "" : GlobalInfo.lang == "ar" ? s.University.NameAr : s.University.NameEn)
|
|
|
|
+ );
|
|
CreateMap<ApplicationUser, UserAllDto>()
|
|
CreateMap<ApplicationUser, UserAllDto>()
|
|
.ForMember(s => s.QualificationName, o => o.MapFrom(s => s.Qualification ==null ? "" : GlobalInfo.lang == "ar" ? s.Qualification.NameAr : s.Qualification.NameEn))
|
|
.ForMember(s => s.QualificationName, o => o.MapFrom(s => s.Qualification ==null ? "" : GlobalInfo.lang == "ar" ? s.Qualification.NameAr : s.Qualification.NameEn))
|
|
.ForMember(s => s.JobTitleName, o => o.MapFrom(s => s.JobTitle ==null ? "" : GlobalInfo.lang == "ar" ? s.JobTitle.NameAr : s.JobTitle.NameEn))
|
|
.ForMember(s => s.JobTitleName, o => o.MapFrom(s => s.JobTitle ==null ? "" : GlobalInfo.lang == "ar" ? s.JobTitle.NameAr : s.JobTitle.NameEn))
|