using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using r16models.Models;

namespace r16models.Controllers
{
    public class HomeController : Controller
    {
        //
        // GET: /Home/

        public ActionResult Index()
        {
            Person p = new Person();
            p.FirstName = "Jan";
            p.LastName = "Kowalski";
            p.IsApproved = true;
            p.PersonId = 1;
            p.Role = Role.User;
            p.BirthDate = new DateTime(1975, 2, 25);

            p.HomeAddress = new Address();
            p.HomeAddress.City = "Gliwice";
            p.HomeAddress.PostalCode = "44-100";
            p.HomeAddress.Country = "PL";
            p.HomeAddress.Line1 = "Kościuszki";
            p.HomeAddress.Line2 = "1c";
            return View(p);
        }

        public ActionResult SimpleModel()
        {
            SimpleModel sm = new SimpleModel();
            sm.Name = "Jan Kowalski";
            sm.Status = Role.Guest;
            return View(sm);
        }

    }
}
