Copied to clipboard

Flag this post as spam?

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


  • Scott Blomfield 30 posts 57 karma points
    Dec 30, 2009 @ 13:24
    Scott Blomfield
    0

    Create Dialog for Custom Tree (size)

    I was hoping someone would be able to point me in the right direction for how to size the create dialog? My ascx file requires more space than the standard simple.ascx, and the scrollbars that are presently there make it pretty difficult to use. I haven't been able to find much information about using a custom usercontrol in the create dialog...

    Thanks,

    Scott

  • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
    Dec 30, 2009 @ 13:37
    Dirk De Grave
    0

    Just a wild guess and not being an expert at this, but me thinks you'll have to take a look at the styles being used in the create dialog and change the css accordingly. 

     

    Cheers,

    /Dirk

  • Scott Blomfield 30 posts 57 karma points
    Dec 30, 2009 @ 14:34
    Scott Blomfield
    0

    Thanks Dirk,

    I also figured that would be the case, but I don't see anything in the usercontrol that would lend its self to that - no specific IDs or Classes that would control the overall height...

    I appreciate the thought though... perhaps Niels, Per, or Tim might weigh in here... (I've built everything else from Tim's excellent umbraco.tv videos so far)

    Thanks,

    Scott

  • Comment author was deleted

    Dec 30, 2009 @ 15:16

    Hi Scott,

    The create member dialog also has some more fields and that has a correct size (no scrollbars). So it might be good to check out the source for that usercontrol (/umbraco/create/member.ascx).

     

    Cheers,
    Tim

  • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
    Dec 30, 2009 @ 15:52
    Dirk De Grave
    0

    Ok, was intrigued by your question and wanted to find the answer... found it... need to edit the createNew() javascript function in umbracoDefault.js.

    And as tim pointed out, there's a else branch that checks whether you want to create a new member (alias = initmember from ui.xml) and sets the height of the modal box accordingly.

    Hope this helps.

    Regards,

    /Dirk

     

  • Nik Wahlberg 639 posts 1237 karma points MVP
    Dec 30, 2009 @ 16:06
    Nik Wahlberg
    0

    This is an intersting topic, meaning, the topic of modals. Especially as it related to the "Choose Media..." modal. Given what you posted above Dirk, I'll check out the possibility of changing the pick media one as well. 

    Thanks!

    -- Nik

  • Scott Blomfield 30 posts 57 karma points
    Dec 30, 2009 @ 17:51
    Scott Blomfield
    0

    I'd noticed the same thing, sizes being set in umbracoDefault.js.

    The reason I ask is that I am developing an eCommerce solution for umbraco (to be released as OSS on codeplex - name pending, I want to make sure it is distinct from the awesome commercial uCommerce package) and was trying to determine how I can facilitate the creation of items when there are multiple required fields. I want to keep all of the maintenance of the commerce items inside of the umbraco admin.

    Since this would be packaged up, would it be possible or advisable to modify umbracoDefault.js? If not, then the only way I see is to try to resize the parent container from inside the iframed usercontrol via jQuery - but this also seems inadvisable.

  • Søren Spelling Lund 13 posts 13 karma points
    Jan 08, 2010 @ 09:52
    Søren Spelling Lund
    0

    I would advise against modifying the Umbraco source. What we did for uCommerce is limit the input needed in the dialogs and instead go for input in the dashboard itself. Usually we only ask for a name or identifier in the dialogs and leave everything else for the dashboard. Works quite well and you avoid the running into space limitation of the dialog UI.

    Hope this helps.

  • Scott Blomfield 30 posts 57 karma points
    Jan 08, 2010 @ 20:37
    Scott Blomfield
    0

    Hi Soren! Nice to hear from you, and from someone in a similar situation in more ways than one! Since this question, I have taken the same path you indicated. I save default values instead of asking for them all in the dialog. I also agree that modifying the umbraco source really seems like a bad idea for a package to do. Going forward, I would love to see an extensible way for being able to specify the width and height of that dialog, but certainly for now it is usable as you suggested, and that is the path I will continue to take.

Please Sign in or register to post replies

Write your reply to:

Draft