yavsc/Yavsc/Model/Relationship/Contact.cs

21 lines
535 B
C#
Raw Normal View History

using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
2016-08-03 23:25:57 +02:00
using Newtonsoft.Json;
namespace Yavsc.Models
{
public class Contact
{
[Required()]
public string UserId { get; set; }
[Required()]
public string OwnerId { get; set; }
2016-09-23 12:32:57 +02:00
[ForeignKeyAttribute("OwnerId"),NotMapped]
public virtual ApplicationUser Owner { get; set; }
2016-09-23 12:32:57 +02:00
[ForeignKeyAttribute("UserId"),NotMapped]
public virtual ApplicationUser User { get; set; }
}
}