aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarcinzelent <marcin@zelent.net>2017-05-23 12:04:53 +0200
committermarcinzelent <marcin@zelent.net>2017-05-23 12:04:53 +0200
commit3a976d603e81cc01d5c8c8f13da125bec98d3b75 (patch)
tree534d77cf04676ea2cf0bcd429d1c20b9b2413712 /ApartmentManager/HousingWebApi/Models
parent6e3e15d2095468a4e131a86e3256c5b14ec6df0d (diff)
Added image converter.
Diffstat (limited to 'ApartmentManager/HousingWebApi/Models')
-rw-r--r--ApartmentManager/HousingWebApi/Models/ApartmentResident.cs32
-rw-r--r--ApartmentManager/HousingWebApi/Models/Resident.cs1
2 files changed, 32 insertions, 1 deletions
diff --git a/ApartmentManager/HousingWebApi/Models/ApartmentResident.cs b/ApartmentManager/HousingWebApi/Models/ApartmentResident.cs
new file mode 100644
index 0000000..9936a5e
--- /dev/null
+++ b/ApartmentManager/HousingWebApi/Models/ApartmentResident.cs
@@ -0,0 +1,32 @@
+namespace HousingWebApi
+{
+ using System;
+ using System.Collections.Generic;
+ using System.ComponentModel.DataAnnotations;
+ using System.ComponentModel.DataAnnotations.Schema;
+ using System.Data.Entity.Spatial;
+
+ public partial class ApartmentResident
+ {
+ [Key]
+ [DatabaseGenerated(DatabaseGeneratedOption.None)]
+ public int ApartmentId { get; set; }
+
+ [StringLength(30)]
+ public string FirstName { get; set; }
+
+ [StringLength(30)]
+ public string LastName { get; set; }
+
+ [Column(TypeName = "date")]
+ public DateTime? BirthDate { get; set; }
+
+ [StringLength(20)]
+ public string Phone { get; set; }
+
+ [StringLength(50)]
+ public string Email { get; set; }
+
+ public byte[] Picture { get; set; }
+ }
+}
diff --git a/ApartmentManager/HousingWebApi/Models/Resident.cs b/ApartmentManager/HousingWebApi/Models/Resident.cs
index c9a698f..0509d40 100644
--- a/ApartmentManager/HousingWebApi/Models/Resident.cs
+++ b/ApartmentManager/HousingWebApi/Models/Resident.cs
@@ -9,7 +9,6 @@ namespace HousingWebApi
[Table("Resident")]
public partial class Resident
{
- [DatabaseGenerated(DatabaseGeneratedOption.None)]
public int ResidentId { get; set; }
public int ApartmentId { get; set; }