示例#1
0
 public static DapAnCauHoiDTO FromEntity(DapAnCauHoi item)
 {
     return(new DapAnCauHoiDTO()
     {
         Id = item.Id,
         CauHoiId = item.CauHoiId,
         TenDapAn = item.TenDapAn,
         GiaTri = item.GiaTri,
         ThuTu = item.ThuTu,
         CauHoi = item.CauHoi != null?CauHoiDTO.FromEntity(item.CauHoi) : null,
                      ChiTietDapAnDeThi = item.ChiTietDapAnDeThi?.Select(ChiTietDapAnDeThiDTO.FromEntity),
     });
 }
示例#2
0
 public static ChiTietBaiThiDTO FromEntity(ChiTietBaiThi item)
 {
     return(new ChiTietBaiThiDTO()
     {
         Id = item.Id,
         BaiThiId = item.BaiThiId,
         CauHoiId = item.CauHoiId,
         CauTraLoi = item.CauTraLoi,
         DiemCham = item.DiemCham,
         BaiThi = item.BaiThi != null?BaiThiDTO.FromEntity(item.BaiThi) : null,
                      CauHoi = item.CauHoi != null?CauHoiDTO.FromEntity(item.CauHoi) : null,
     });
 }
示例#3
0
 public static ChiTietDeThiDTO FromEntity(ChiTietDeThi item)
 {
     return(new ChiTietDeThiDTO()
     {
         Id = item.Id,
         DeThiId = item.DeThiId,
         CauHoiId = item.CauHoiId,
         BatBuocTraLoi = item.BatBuocTraLoi,
         ThuTu = item.ThuTu,
         HienThiSoThuTu = item.HienThiSoThuTu,
         PhuThuocVaoCauHoiId = item.PhuThuocVaoCauHoiId,
         GiaTriPhuThuoc = item.GiaTriPhuThuoc,
         DiemToiDa = item.DiemToiDa,
         DaoDapAn = item.DaoDapAn,
         DeThi = item.DeThi != null?DeThiDTO.FromEntity(item.DeThi) : null,
                     CauHoi = item.CauHoi != null?CauHoiDTO.FromEntity(item.CauHoi) : null,
                                  ChiTietDapAnDeThi = item.ChiTietDapAnDeThi?.Select(ChiTietDapAnDeThiDTO.FromEntity),
     });
 }