Copied to clipboard

Flag this post as spam?

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


  • Ariel Plon 14 posts 123 karma points
    Feb 10, 2015 @ 21:45
    Ariel Plon
    0

    MVC renders /surface/umbraco/... type URL on partials

    Guys, I'm a newbie on MVC and EXTREMELY newbie on Umbraco. I am trying to integrate our custom made app's into Umbraco, so that we have the best of both worlds (Umbraco as the content manager and our app to integrate Umbraco with Dynamics CRM). After reading and watching and surfing and...., I've got to a complete stop, so I would SO MUCH appreciate some help in the form of specific code, not only some link pointers (as they've led me no where).

    The scenario is the following:

    My take is that tis should be quite simple, but I'm just missing something. I want my own controllers (which btw, map to Dynamics CRM), and integrate that into Umbraco. I want to render a link to the details of each account.

    Any suggestion and tutorial will be GRATLY APPRECIATED.

    Regards, Ariel

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Feb 11, 2015 @ 09:14
    Jeroen Breuer
    100

    Hello,

    Maybe not what you're looking for, but if you want to know more about MVC and Umbraco have a look at the Hybrid Framework. It shows how you can do more with MVC in Umbraco.

    Jeroen

  • Ariel Plon 14 posts 123 karma points
    Mar 10, 2015 @ 01:11
    Ariel Plon
    0

    thanks for your reply Jeroen. We did take a look at the hybrid framework and took some ideas that allowed us to solve the problem

    once again, thanks for your reply

    best regards, Ariel

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Mar 10, 2015 @ 09:29
    Jeroen Breuer
    0

    Glad I could help. Could you mark a post as the solution if it helped you? You could also add another post in which you explain how you fixed it and mark that as the solution.

    Jeroen

  • Ariel Plon 14 posts 123 karma points
    Mar 11, 2015 @ 13:12
    Ariel Plon
    0

    So this is what we ended up doing. We created a template associated to the content type. In htat template, we added an html.action (for example: @Html.Action("Index", "ContactUs")). The controller renders a partial view, which gets included in the template, allowing us to effectively integrate Umbraco to our CRM. Inside the partial view, we used the following:

    @model xmsbs.Models.ContactUs

     

    @using (Html.BeginUmbracoForm<xmsbs.Controllers.ContactUsController>("contactUs")) {

    //html markup

    }

    BTW, the controller is an Umbraco SurfaceController, so no custom routing (hijacking or whatever) is necessary.

    I am not totally satisfied with this solution, as we need to create the template in Umbraco backoffice and then go back to visual studio and create the partial view. I'll keep "digging" till I find a better, more robust solution.

    Regards, Ariel

     

     

     

Please Sign in or register to post replies

Write your reply to:

Draft