public static IOBalanceDBV3Entity.Customers DtoToEntity(this CustomerDetails dto) { IOBalanceDBV3Entity.Customers entity = null; if (!dto.IsNull()) { entity = new IOBalanceDBV3Entity.Customers { CustomerID = dto.CustomerId, CreatedBy = dto.CreatedBy, CustomerAddress = dto.CustomerAddress, CustomerCode = dto.CustomerCode, CustomerName = dto.CustomerName, DateCreated = dto.DateCreated, DateUpdated = dto.DateUpdated, IsActive = dto.IsActive, UpdatedBy = dto.UpdatedBy }; } return(entity); }