Copied to clipboard

Flag this post as spam?

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


  • ATHUL JAYAN 9 posts 58 karma points
    Dec 16, 2014 @ 10:53
    ATHUL JAYAN
    0

    DateTime Picker as Macro Parameter

    Hi, 

    Is there any way to get the datetime picker inside the macro parameter data type ?
    I need to use this in Umbraco 7 as well as 6 + versions.

    Thanks

    Athul

  • Dennis Aaen 4499 posts 18254 karma points admin hq c-trib
    Dec 16, 2014 @ 10:59
    Dennis Aaen
    0

    Hi Athul,

    For the solution for the Umbraco 7, i think that you should have a look on this https://github.com/umbraco/AngularWorkbook/blob/master/Exercises/Exercise10.md

    Hope this helps for the Umbraco 7 part.

    /Dennis

  • Dennis Aaen 4499 posts 18254 karma points admin hq c-trib
    Dec 16, 2014 @ 11:01
    Dennis Aaen
    0

    And for the Umbraco 6, I think at you should have a look here. http://our.umbraco.org/documentation/Extending-Umbraco/Macro-Parameter-Editors/

    Hope this helps too.

    /Dennis

  • ATHUL JAYAN 9 posts 58 karma points
    Dec 16, 2014 @ 11:23
    ATHUL JAYAN
    0

    Hi Dennis 

    Thanks for the quick response.

    Is there any way to use umbraco's native date picker data type as macro parameter ? Instead of creating the date picker from scratch, i would like to use the native data type.

    Thanks 

    Athul

  • jivan thapa 194 posts 681 karma points
    Dec 16, 2014 @ 21:42
    jivan thapa
    102

    Hi, Athul Jayan.

    Yes, you can do it. it's very easy.

    Just create an empty class that inherits from DatePropertyEditor. And you should pass en extra parameter (IsParameterEditor = true). You are done. :)

    It will look like this one

    using Umbraco.Core.PropertyEditors;
    using Umbraco.Web.PropertyEditors;
    
    namespace UmbracoTest.App_Plugins
    {
    
    
        [PropertyEditor("Date", "Datepicker for macro", "datepicker", IsParameterEditor = true)]
        public class DateTimePickerTest : DatePropertyEditor 
        {
        }
    }
    
  • cchehn 28 posts 69 karma points
    Sep 27, 2018 @ 18:38
    cchehn
    0

    How would you do this now with the App_Plugins structure in U7?

  • ATHUL JAYAN 9 posts 58 karma points
    Dec 17, 2014 @ 05:56
    ATHUL JAYAN
    0

    Hi Jivan

    I already done this by editing the umbraco source code , adding IsParameterEditor = true to the date picker class.

    Thanks Jivan. Yours was way better than what i done..

     

    Thanks 

    Athul

Please Sign in or register to post replies

Write your reply to:

Draft