title: Best way to pass lookup values to a dropdownlist
body: <p>I'm wondering what's the general approach of passing a list of lookup values to a view in MVC. Currently I have 2 db tables and I'm using db first EF6 to interface.  My main table has a lookup table and I want to populate a dropdownlist of my view with all the values of the lookup so that the user can pick when creating and editing.</p>
  
  <p>Employee Table</p>
  
  <pre><code>id primary key
  name varchar
  department id - this is the id of the department in the lookup
  </code></pre>
  
  <p>Department table</p>
  
  <pre><code>id primary key
  name varchar
  </code></pre>
  
  <p>Is it best to create a partial class for the employee model and add a new property called allDepartments and then in my controller call a method that gets all the departments before passing the model to the view, or is it better to dump the departments in the viewbag/viewdata dictionary?</p>
  
  <p>What is the general approach here?</p>