• 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
create new to-many objects in d2w
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

create new to-many objects in d2w


  • Subject: create new to-many objects in d2w
  • From: Theodore Petrosky <email@hidden>
  • Date: Fri, 12 Jul 2013 11:33:57 -0400

when I create a new to-many object there is a button with a  label 'Save'. I understood that this new object was inserted into the EC and I had to click the save button at the bottom of my parent EO to actually save the related object.

but of course there is a problem. If I add an object and immediately click its delete button, my app throws a hissy-fit because the object can not be deleted as it is not saved in the first place.

So the question is. when I create a new object, and click save, shouldn't d2w do just that? saveChanges() on the EC?

this is the saveButton's action (from ERMODWizardCreationPage).
/**
 * Performs submit action. Overridden to reset the nested validation setting on the
 * object.
 */
 // FIXME - Is this needed here? davidleber
 @Override
 public WOComponent submitAction() throws Throwable {
  WOComponent result = super.submitAction();
  if (object() instanceof ERXGenericRecord) {
     ((ERXGenericRecord)object()).setValidatedWhenNested(true);
  }
 return result;
}


I keep following back the super.submitAction() to see what it does but there is no implied saveChanges() anywhere that I can find.



 _______________________________________________
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

  • Follow-Ups:
    • Re: create new to-many objects in d2w
      • From: David Holt <email@hidden>
  • Prev by Date: Create dynamic AjaxTabbedPanelTab in AjaxTabbedPanel with WORepetion
  • Next by Date: Re: create new to-many objects in d2w
  • Previous by thread: Re: Create dynamic AjaxTabbedPanelTab in AjaxTabbedPanel with WORepetion
  • Next by thread: Re: create new to-many objects in d2w
  • Index(es):
    • Date
    • Thread