4 Replies Latest reply on Feb 26, 2009 3:45 AM by Ruediger xxx

    modalPanel disappears after a few seconds

    Ruediger xxx Newbie

      hello, i have an issue with the rich:modalPanel.

      i have a button in a rich:datatable column which opens the modal panel. the panel opens alright, but then after a few seconds disappears. i use an actionlistener in the button that opens the modalpanel. is this expected behaviour?

      i have a workaround using the "rendered" tag of the modalPanel, but i would rather not have to use this in all my screens.

      here is my code (without workaround):

      <h:commandButton id="frm_se_del_btn" title="delete"
      class="btn-delete" actionListener="#{bbRoleSearch.deleteListener}"
      onclick="#{rich:component('panel_delete_yesno')}.show()" />
      
      
      <rich:modalPanel keepVisualState="true" id="panel_delete_yesno" autosized="true" width="300" headerClass="modal-header">
       <a4j:form id="cpform">
       <h:commandButton id="del_confirm_btn" value="delete"
       action="#{bbRoleSearch.doDelete}"
       class="btn"
       onclick="Richfaces.hideModalPanel('panel_delete_yesno')" />
       <rich:spacer width="5"/>
       <h:commandButton id="del_cancel_btn" value="cancel"
       class="btn"
       onclick="Richfaces.hideModalPanel('panel_delete_yesno')" />
       </a4j:form>
      </rich:modalPanel>