Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class User : IdentityUser
- {
- public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager<User> manager)
- {
- // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType
- var userIdentity = await manager.CreateIdentityAsync(this, DefaultAuthenticationTypes.ApplicationCookie);
- // Add custom user claims here
- return userIdentity;
- }
- public User()
- {
- Calendar = new Calendar();
- }
- public Calendar Calendar { get; private set; }
- }
- public class Calendar
- {
- public int Id { get; set; }
- public Calendar()
- {
- CalendarEvents = new List<CalendarEvent>();
- }
- public virtual List<CalendarEvent> CalendarEvents { get; private set; }
- }
- public class CalendarEvent
- {
- public int Id { get; set; }
- public string title { get; set; }
- public string date { get; set; }
- public string start { get; set; }
- public string end { get; set; }
- public string url { get; set; }
- public bool allDay { get; set; }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement