PersonModel.cs 796 B

1234567891011121314151617181920212223242526272829
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace friaLabbar.Models
  7. {
  8. public class PersonModel
  9. {
  10. public int PersonId { get; set; }
  11. public string FirstName { get; set; }
  12. public string LastName { get; set; }
  13. public bool IsAlive { get; set; }
  14. public DateTime DateOfBirth { get; set; }
  15. public int Age { get; set; }
  16. public decimal AccountBalance { get; set; }
  17. public List<AddressModel> Addresses { get; set; } = new List<AddressModel>();
  18. public AddressModel PrimaryAddress { get; set; }
  19. public string FullName
  20. {
  21. get
  22. {
  23. return $"{FirstName} {LastName}";
  24. }
  25. }
  26. }
  27. }