Exemplo n.º 1
0
 public static IncentiveKindViewModel ToViewModel(this IncentiveKindEntity entity)
 {
     if (entity == null) throw new ArgumentNullException(nameof(entity));
     var result = new IncentiveKindViewModel();
     result.AssignFrom(entity);
     return result;
 }
Exemplo n.º 2
0
 public virtual void AssignFrom(TaskIncentiveEntity entity)
 {
     if (entity == null) throw new ArgumentNullException(nameof(entity));
     this.Amount = entity.Amount;
     this.IncentiveKind = entity.IncentiveKind.ToViewModel(); 
 }