Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Thomsen 112 posts 335 karma points
    Apr 13, 2016 @ 23:11
    Thomsen
    0

    Error when using my own templates

    Hi

    I am running Umbraco 7.4.2 with a Merchello installation. I'm trying to build up the Bazaar project from scratch, adding a Store.cshtml template to the master, the same way as in the source code the Bazaar project is providing.

    My Master.cshtml has the page directive: @inherits Umbraco.Web.Mvc.UmbracoTemplatePage

    And my Store.cshtml has: @inherits Umbraco.Web.Mvc.UmbracoViewPage

    But I get this error:

    "Cannot bind source content type Umbraco.Web.PublishedContentModels.Store to model content type myProject.Models.ViewModels.StoreModel."

    How is the correct way to make the templates and models coorporate together within Merchello?

    In my web.config i have

    <add key="Umbraco.ModelsBuilder.Enable" value="true" />
    <add key="Umbraco.ModelsBuilder.ModelsMode" value="PureLive" />
    

    I don't know if that maybe could have an influence on the error.

    Best regards.

  • Jason 92 posts 175 karma points
    Apr 14, 2016 @ 12:59
    Jason
    0

    This isn't Merchello specific. Route hijacking in 7.4.2 isn't working correctly. See here. https://our.umbraco.org/forum/using-umbraco-and-getting-started/75998-update-to-742-all-custom-hijacked-controllers-stopped-working

  • Thomsen 112 posts 335 karma points
    Apr 15, 2016 @ 10:07
    Thomsen
    0

    Hi Jason - thank you for letting me know.

    I have been struggeling with the issue a few days now. Have you heard of a any imminent Umbraco update, which will fix the error?

    Downgrading to 7.3.0 would be such a shame...

  • Jason 92 posts 175 karma points
    Apr 15, 2016 @ 10:13
    Jason
    1

    No problem. Umbraco 7.4.3 was release yesterday (after my previous response), which includes a fix for route hijacking with custom models. I tested it last night. Not sure about Merchello's compatibility with this new version.

  • Thomsen 112 posts 335 karma points
    Apr 15, 2016 @ 10:18
    Thomsen
    0

    Ah ok, thank you - I'm not really updated myself ;-)

    I will try upgrading or else maybe downgrading one version to 7.4.1 could solve it.

Please Sign in or register to post replies

Write your reply to:

Draft