public static externalDTO.ProductService MapFromInternal(internalDTO.ProductService productService) { var res = productService == null ? null : new externalDTO.ProductService() { Id = productService.Id, Description = productService.Description, WorkObjectId = productService.WorkObjectId, WorkObject = WorkObjectMapper.MapFromInternal(productService.WorkObject), ProductForClientId = productService.ProductForClientId, ProductForClient = ProductForClientMapper.MapFromInternal(productService.ProductForClient) }; return(res); }
public static externalDTO.AppUserOnObject MapFromInternal(internalDTO.AppUserOnObject appUserOnObject) { var res = appUserOnObject == null ? null : new externalDTO.AppUserOnObject { Id = appUserOnObject.Id, AppUserId = appUserOnObject.AppUserId, AppUser = AppUserMapper.MapFromInternal(appUserOnObject.AppUser), WorkObjectId = appUserOnObject.WorkObjectId, WorkObject = WorkObjectMapper.MapFromInternal(appUserOnObject.WorkObject), From = appUserOnObject.From, Until = appUserOnObject.Until }; return(res); }
public static externalDTO.Bill MapFromInternal(internalDTO.Bill bill) { var res = bill == null ? null : new externalDTO.Bill { Id = bill.Id, ClientId = bill.ClientId, Client = ClientMapper.MapFromInternal(bill.Client), ArrivalFee = bill.ArrivalFee, SumWithoutTaxes = bill.SumWithoutTaxes, TaxPercent = bill.TaxPercent, FinalSum = bill.FinalSum, DateTime = bill.DateTime, InvoiceNr = bill.InvoiceNr, Comment = bill.Comment, WorkObjectId = bill.WorkObjectId, WorkObject = WorkObjectMapper.MapFromInternal(bill.WorkObject), // BillLines = bill.BillLines.Select(e => BillLineMapper.MapFromInternal(e)).ToList(), }; return(res); }