NHaml config issue: model not found
I have a little problem with my NHaml config:
<configSections>
<section name="nhaml" type="NHaml.Configuration.NHamlConfigurationSection, NHaml"/>
</configSections>
<nhaml AutoRecompile="true">
<assemblies>
<add assembly="Microsoft.Web.Mvc"/>
<add assembly="MyAssembly"/>
</assemblies>
<namespaces>
<add namespace="NHaml.Web.Mvc"/>
<add namespace="MyAssembly.Models"/>
<add namespace="System.Linq"/>
</namespaces>
</nhaml>
The problem is I am trying to use a model from MyAssembly.Models in my opinion:
%ul
- foreach(var v in (IQueryable<Model>)ViewData["stat"])
%li= v.name
But it keeps crashing, informing me that MyAssembly.Models.Model is not recognized and asking if I am missing a usage directive. Is there something wrong in my web.config or my view?
Thanks in advance.
0
source to share