I have created the schema, template, model, view and registered the view model. While debugging, I see that the RegionModel and Entity Model are populated only with MvcData and not the field values. When I check the Broker DB, I see that the Page content has the component fields populated properly. Schemas.json and regions.json too look fine on the presentation server. Irrespective of whether I change the template as static or DCP, I am still not able to populate fields in the viewmodel. There is no special processing that I added to EnrichModel. Any thoughts what could have gone wrong? I cross compared my configurations and code with documentation too.
-
Since you can see the fields in the Broker you ruled out link levels. If this is .NET did you register your viewmodel correctly in the module?– Rob Stevenson-LeggettMar 19, 2017 at 23:13
-
Yes. I have registered all page,, region and entity models. Moreover, I changed the page template name so that it is different from "HomePage" of Core module. Still I do not see any improvement.– BharathMar 20, 2017 at 5:42
-
1Sounds like semantic mapping fails. If you set log level to DEBUG (in Log.config), you should see diagnostic messages about the semantic mapping.– Rick PannekoekMar 20, 2017 at 7:13
1 Answer
Thanks Rick. I seriously messed up semantics. Now I see the values coming through :)
-
Good to hear you have it working. Can you elaborate on how you "messed up semantics" and how you found the problem? Maybe it can prevent others from making the same mistake? Mar 20, 2017 at 18:40
-
As Rick says - this isn't really a good answer to your question. Please add a bit more detail if you can! Mar 20, 2017 at 21:44
-
I haven't added the semantics properly. Set the schema name wrong which caused the issue. After I matched the schema name in the model, things started moving.– BharathMar 28, 2017 at 6:37