4 Replies Latest reply on Dec 14, 2009 9:44 AM by scott coleman

    Rich: drag'n'drop confirmation PopUp

    scott coleman Newbie

      Hello people,

       

                I have a rich:extendedDataTable and a rich:tree, i have drag and drop enabled so that i can move a

      row from the ExtendedDataTable to a different node in the rich:tree.

       

      When a row is dropped into a new node in the rich:tree i would like to create a confirmation popUp asking

      if you are sure you want to do this.

       

      What i have tried:

      Using the rich:tree attribute "ondrop", i made a javascript alert( ) that would popUp and ask for confirmation

      and if the user clicked yes then a boolean would change in my bean the the method would run. If the user clicked

      no then the boolean would stay false in the bean and the method would not be run.

       

      Problems:

      I have tried to impliment the same sort of idea but using a rich:modalPanel instead, the same sort of thing can be achived

      BUT the modal panel does not Halt the dropListener process, the drop event just happens. The javascript alert seemed to

      halt the drop event untill it was close.

       

      Any idea's on how i could get around this?

      im guessing somebody must have done the same sort of thing before.

       

      Thank you.
      Scott