Added mongo db repository
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -6,9 +7,13 @@ namespace BrightGlimmer.Data.Domain
|
||||
{
|
||||
public class Phone
|
||||
{
|
||||
[BsonElement("Id")]
|
||||
public Guid Id { get; set; }
|
||||
[BsonElement("Type")]
|
||||
public PhoneType Type { get; set; }
|
||||
[BsonElement("AreaCode")]
|
||||
public int AreaCode { get; set; }
|
||||
[BsonElement("Number")]
|
||||
public int Number { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -6,11 +7,17 @@ namespace BrightGlimmer.Data.Domain
|
||||
{
|
||||
public class Student
|
||||
{
|
||||
[BsonElement("Id")]
|
||||
public Guid Id { get; set; }
|
||||
[BsonElement("FirstName")]
|
||||
public string FirstName { get; set; }
|
||||
[BsonElement("MiddleName")]
|
||||
public string MiddleName { get; set; }
|
||||
[BsonElement("LastName")]
|
||||
public string LastName { get; set; }
|
||||
[BsonElement("Email")]
|
||||
public string Email { get; set; }
|
||||
[BsonElement("Phones")]
|
||||
public List<Phone> Phones { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user