Copied to clipboard

Flag this post as spam?

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


  • Jay 409 posts 635 karma points
    May 17, 2016 @ 15:00
    Jay
    0

    Composition property with Vorto

    Hi All,

    I'm using Umbraco 7.4.3 and I've got a composition property of Media Picker that I've inherited into a DocType.

    I'm using the ModelsBuilder but it keeps picking it up at an object of type VortoValue.

    Do anyone have any idea on how to overwrite the Composition Property to use the GetVortoProperty<>()?

    I've tried to overwrite my composition with a partial but my DocType model doesn't pick up the Media Picker property anymore when i overwrite them.

    Any idea?

    Thanks

  • Jay 409 posts 635 karma points
    May 17, 2016 @ 15:22
    Jay
    0

    I've currently created a separate property as below for the composition. Not sure if there's a better way to this to reuse the stuff from the ModelsBuilder interface for composition

    ///<summary>
    /// Header Image
    ///</summary>
    [ImplementPropertyType("image")]
    public IPublishedContent CompositionImage
    {
          get { return this.GetVortoValue<IPublishedContent>("image"); }
    }
    
Please Sign in or register to post replies

Write your reply to:

Draft