Copied to clipboard

Flag this post as spam?

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


  • Patrick Scott 70 posts 110 karma points c-trib
    Feb 10, 2015 @ 15:19
    Patrick Scott
    0

    Display Grid data Resolver

    I have created property editor data resolvers for courier in the past, so I am familiar with the technique, but I can't seem to work out how to create a data resolver for a new display grid editor I have created.

    I have tried inheriting my class from both PropertyDataResolverProvider and GridCellDataResolverProvider. The EditorAlias property on the class gets called and I assume that the problem is the string I am returning.

    I have tried the alias defined in the grid.editors.config.js file as well as the view and render properties. Does anyone what string I should be returning as the editor alias?

    Is there any guidance for creating data resolvers for the display grid yet?

     

     

  • Paul Sterling 718 posts 1534 karma points MVP 8x admin c-trib
    Feb 10, 2015 @ 19:13
    Paul Sterling
    0

    @Patrick 

    Have a look at how the Archetype data resolver was created, it's a good reference.  

    https://github.com/imulus/Archetype/tree/fbf686f559c2838b0aa319498496e09866093c5d/app/Umbraco/Archetype.Courier

    The latest version of Courier supports the Umbraco Grid property editor and defined datatypes, but if you've gone beyon that you are on the right track in creating your own data resolver.

  • Patrick Scott 70 posts 110 karma points c-trib
    Feb 10, 2015 @ 20:18
    Patrick Scott
    0

    @Paul, Thanks for the info. Archetype is a data type (i.e. only appears in the Developer/Data Types section)? , I have created my own data type also and got that working with courier.

    The issue I have is with a property editor (in the new grid layout). This is defined in the grid.editors.config.js and only appears in the grid layout, not as a data type.  

    The entry in grid.editors.config.js is:

    {
        "name""SPC Page Part Not Courier friendly",
            "alias""SPCPagePartPicker",
            "view""/App_Plugins/SPCGrid/Editors/Views/SPCPagePart.html",
            "render""/App_Plugins/SPCGrid/Editors/Render/SPCPagePart.cshtml",
            "icon""icon-settings-alt"
    },
    

     

    I am wondering if courier does not support custom grid property editors yet and I am ahead of the curve on this.

     

     

  • Paul Sterling 718 posts 1534 karma points MVP 8x admin c-trib
    Feb 11, 2015 @ 01:50
    Paul Sterling
    0

    @Patrick

    Ah, got it...I did misunderstand initially.  Yes, currently there is not support for custom grid property editors, but it seems a logical feature to add in the next - well, the next, next - release.  What would be ideal is if you'd create a feature request in the tracker http://issues.umbraco.org/issues/COU and include your custom grid.  If it's not something you can share publicly then could you send to me directly and I can queue it up for a future sprint for Courier (paul at umbraco).  Having your real-world example will help sorting out what's needed.

  • Patrick Scott 70 posts 110 karma points c-trib
    Feb 11, 2015 @ 10:40
    Patrick Scott
    0

    Thanks, I will get a feature request raised today. Its a very simple editor at the moment, it just wraps the content picker so I can start it at a specific node and use the advanced filter.

    Its something I can do with a macro and my own custom property editor (datatype), so I can work around it for now. 

     

     

Please Sign in or register to post replies

Write your reply to:

Draft