• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: AjaxModalDialog not going away
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AjaxModalDialog not going away


  • Subject: Re: AjaxModalDialog not going away
  • From: Klaus Berkling <email@hidden>
  • Date: Mon, 21 Oct 2013 16:21:41 -0700


On Oct 21, 2013, at 2:23 PM, Samuel Pelletier <email@hidden> wrote:

I read your initial message again and something caught my attention. I do not think the ModalDialog will call the action the second time, it reuse it's contents, I remember having trouble like this 2 years ago.

I never use the action on AjaxModalDialog, I always use a separate WOComponent with a binding for the edited entity. 

The HTML logo like this:
<wo:AjaxModalDialog id = "coursEditor" resizeDuration = "0.25" slideDownDuration = "0" closeUpdateContainerID = "ficheCours" title = "$localizer.CoursEdit.titre.EditerPeriode"><wo:PeriodeEditor object = "$editedPeriode"/></wo:AjaxModalDialog>

The action of the AjaxModalDialogOpener simply set the variable bound to the object like this:
public WOActionResults editPeriode() {
EOEditingContext ec = ERXEC.newEditingContext();
editedPeriode = periode().localInstanceIn(ec);
return null;
}

I even created a BasicEditorComponent class for these editors.

Very interesting.  Not using action and using WOComponent didn't change anything - but good to know.

What you said about reusing the content of the dialog was the key.  I have placed the AjaxModalDialogs within the update container. Also, my ajax submit buttons now have updateContainerID bound to the id of the update container.

Update container
Dialog1
Dialog2
Dialog3
Form
Observe field
Dialog Opener1 (new items)
Repetition
Dialog Opener2 (edit items)
Dialog Opener3

So, fixed, whoo hoo. Next...

Thanks all.


kib

Klaus Berkling
www.berkling.us | @kiberkli



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: AjaxModalDialog not going away (From: Chuck Hill <email@hidden>)
 >Re: AjaxModalDialog not going away (From: Klaus Berkling <email@hidden>)
 >Re: AjaxModalDialog not going away (From: Samuel Pelletier <email@hidden>)
 >Re: AjaxModalDialog not going away (From: Klaus Berkling <email@hidden>)
 >Re: AjaxModalDialog not going away (From: Samuel Pelletier <email@hidden>)

  • Prev by Date: Re: AjaxModalDialog not going away
  • Next by Date: Workaround for annoying NPE bug when opening WOComponent Editor
  • Previous by thread: Re: AjaxModalDialog not going away
  • Next by thread: Problem with wocommunity yum repo
  • Index(es):
    • Date
    • Thread