title: use properties and metadata on base class in different namespace
body: <p>I have a separate Visual Studio project where I keep my data model (EF6). So, my entities are in namespace <code>Name1</code> (created by EF6 database first, but simplified below, for this example):</p>
  <pre><code>namespace Name1
  {
     public class Person
     {
        public string FName {get; set;}
        public string LName {get; set;}
     }
  }
  </code></pre>
  <p>Now, I have created a new MVC 5 project, which references the data Visual Studio project so that I can access the entities. In my MVC project, I want to add some metadata to the entity like this:</p>
  <pre><code>namespace NameMvc 
  {
     [MetadataType(typeof(PersonMetaData))]
     public class Person : Name1.Person
     {
      
     }
  
     public class PersonMetaData
     {
        [Display(Name = &quot;Firstname&quot;)]
        public string FName;
     }
  }
  </code></pre>
  <p>In my controller I want to get all the persons, so I have an Action like this:</p>
  <pre><code>using Name1;
  using NameMvc;
  
  -- controller class code
  public ActionResult Index()
  {
     var persons = db.Person.ToList();
     return View(persons);
  }
  -- controller class code
  </code></pre>
  <p>And in my view I try to access that via:</p>
  <pre><code>@model IEnumerable&lt;NameMvc.Person&gt;
  </code></pre>
  <p>Now, when I run the code I get an error:</p>
  <blockquote>
  <p>The model item passed into the dictionary is of type 'System.Data.Entity.Infrastructure.DbQuery`1[Name1.Person]', but this dictionary requires a model item of type 'System.Collections.Generic.IEnumerable`1[Name.MvcPerson]'.</p>
  </blockquote>
  <p>I probably did something wrong in the action, because <code>db.Person</code> comes from the <code>Name1</code> namespace.</p>
  <p>I want to use the metadata in my View so that when I do something like this <code>@Html.DisplayNameFor(model =&gt; model.FName)</code>, it displays &quot;Firstname&quot;.</p>