Copied to clipboard

Flag this post as spam?

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


  • Peter Cort Larsen 421 posts 1038 karma points
    Oct 08, 2012 @ 11:00
    Peter Cort Larsen
    0

    MNTP: Source code vers. 3.03 pre-selected items

    Hi,

    Is it possible to get source code for vers. 3.03?

    I would like to tweak it so i can show some pre-selected nodes before the user has made a choose of nodes.

     

  • Lee Kelleher 4026 posts 15837 karma points MVP 13x admin c-trib
    Oct 08, 2012 @ 11:08
    Lee Kelleher
    0

    Hi Peter,

    Yes, our uComponents repo is version tagged - here's the source for v3.0.3: http://ucomponents.codeplex.com/SourceControl/changeset/view/3e1f5aa6ee5b - Press the "Download" link in the top-right menu.

    Personally I wouldn't modify the source for MNTP, I'd hook into the "Document.New" event and pre-populate the MNTP's values from there.

    Cheers, Lee.

  • Peter Cort Larsen 421 posts 1038 karma points
    Oct 08, 2012 @ 11:43
    Peter Cort Larsen
    0

    Hi,

     

    Sounds like a good idea to not mess with thier code and use doc new

  • Peter Cort Larsen 421 posts 1038 karma points
    Nov 13, 2012 @ 21:10
    Peter Cort Larsen
    0

    Hi Lee,

     

    Back at this thing again.

    I have a file DocumentNew.cs with the code below. But what do i do next to pre-populate the current node mntp? And does this only work when creating a new page? Or also on existing pages with a mntp?

     

     public class DocumentNew : ApplicationBase
    {
    //Constructor
    public DocumentNew()
    {
    Document.BeforeSave += new Document.SaveEventHandler(Document_New);
    }

    void Document_New(Document sender, umbraco.cms.businesslogic.SaveEventArgs e)
    {
    Log.Add(LogTypes.Save, sender.Id, "saved " + sender.Id);
    }
    }

     

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies