• 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: WOComponent quesion
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: WOComponent quesion


  • Subject: Re: WOComponent quesion
  • From: Chuck Hill <email@hidden>
  • Date: Wed, 7 Mar 2007 09:52:06 -0800


On Mar 7, 2007, at 9:44 AM, Amedeo Mantica wrote:

Hello, I have got in trouble...

I have a page with a list of objects, (a WORepetition)...

I can click on an object and go into the page for edit the object. finished editing I click on sve and return to the listing page. All works fine.

The problem:

my listing page have an ordering theh can be by date, title, etc... when i enter in a object detail and return to main page I lost my ordering method previously choosen.

You might want to look at AjaxGrid in Wonder's Ajax framework. It is pretty cool, even if I did write it. It has complex sort orderings, drag and drop column re-ordering, selections that persist across batches, and the user's chosen configuration can be persisted to a string. But I digress....



I can pass the ordering method choosen to the detail page and then return back to the main page, but I think is not the better solution.

How are you returning to the listing page? If you are doing pageWithName(), then it is creating a new object. You probably want to add this to your editing page:


private WOComponent previousPage;

public MyEditingPage(WOContext context) {
    super(context);
    previousPage = context().page();
    ...
}


public WOComponent previousPage() { previousPage.ensureAwakeInContext(context()); return previousPage; }


Then in your save and cancel methods,

   ...
   return previousPage();
}


Chuck

--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects






_______________________________________________
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: WOComponent quesion
      • From: Timo Hoepfner <email@hidden>
References: 
 >WOComponent quesion (From: Amedeo Mantica <email@hidden>)

  • Prev by Date: WOComponent quesion
  • Next by Date: Re: Question about WORepetitions
  • Previous by thread: WOComponent quesion
  • Next by thread: Re: WOComponent quesion
  • Index(es):
    • Date
    • Thread