Pull back records that include child records
The fact that your ViewModel is almost an identical copy of your entity class is a code smell. ViewModel should represent data as it is to be shown on screen, that means that most properties should be simple types (string, int and bool mostly). Weed them out first, I don't believe you need all the IDs either!

Your repository doesn't do any real projection, so you can get rid of the entire select clause. Use eager loading (Include()) instead of joins (your domain and/or EF config might need to be modified):

var reqMatsInc = (from rm in db.RequiredMaterial.Include(rm =&gt; rm.RequiredMaterialRoles)
                  join p in db.Project on rm.ProjectTemplateId equals p.ProjectTemplateId
                  where p.ProjectId == id).


Then, have another method in another class (preferrably in your UI layer) map the result to  your ViewModels.

(may I suggest AutoMapper to handle this task for you, it was made for exactly these kind of things).