Re: Changing value of a WOConditional binding inside WORepetition [SOLVED]
Re: Changing value of a WOConditional binding inside WORepetition [SOLVED]
- Subject: Re: Changing value of a WOConditional binding inside WORepetition [SOLVED]
- From: David Holt <email@hidden>
- Date: Tue, 30 Aug 2005 15:41:38 -0700
Chuck, cleaning up the code with your suggestions makes it all work correctly. Organizing it as Ken suggested works great. Thanks guys,
David
(the final version follows)
public void appendToResponse(WOResponse aResponse, WOContext aContext) {
if (documentToUndelete != null) {
EOEditingContext ec = documentToUndelete.editingContext();
documentToUndelete.setDeleted(new Integer(0));
ec.saveChanges();
}
if (documentToDelete != null) {
EOEditingContext ec = documentToDelete.editingContext();
documentToDelete.setDeleted(new Integer(1));
ec.saveChanges();
}
documentDisplayGroup.qualifyDataSource();
super.appendToResponse(aResponse,aContext);
}
public boolean markedForDeletion()
{
Number deletedFlag = itemDocument.deleted();
return deletedFlag.equals(thisIsMarked);
}
public WOComponent deleteDocument()
{
documentToDelete=itemDocument;
return context().page();
}
public WOComponent undeleteDocument()
{
documentToUndelete=itemDocument;
return context().page();
}
On 30 Aug 2005, at 3:17 PM, David Holt wrote:
<x-tad-smaller>--
I don't want you to follow me or anyone else. I would not lead you to the promised land if I could, because if I could lead you in, somebody else would lead you out.
–Eugene V. Debs
from Sunbeams: </x-tad-smaller><x-tad-smaller>http://www.thesunmagazine.org</x-tad-smaller><x-tad-smaller> </x-tad-smaller>
_______________________________________________
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