• 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: ERMBatchSizeControl problem with embedded listings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ERMBatchSizeControl problem with embedded listings


  • Subject: Re: ERMBatchSizeControl problem with embedded listings
  • From: ISHIMOTO Ken <email@hidden>
  • Date: Wed, 20 Oct 2010 13:23:59 +0200

Hi David,

I had the some Problem.

The fix that I use was:

1: To get no Error for just in case

ERMDBatchSizeControl

public void setNumberOfObjectsPerBatch(Integer number) {
displayGroup().setNumberOfObjectsPerBatch(number);
NSDictionary dic = (d2wContext() == null) ? NSDictionary.emptyDictionary() : new NSDictionary(d2wContext(),"d2wContext");
NSNotificationCenter.defaultCenter().postNotification( ERXBatchNavigationBar.BatchSizeChanged, ERXConstant.integerForInt(number.intValue()), dic );
}

2: Add missing Binding

ERMODEditRelationshipPage

WOD :

BatchSizeControl : ERMDBatchSizeControl {
displayGroup = relationshipDisplayGroup;
updateContainerID = d2wContext.idForRepetitionContainer;
d2wContext = d2wContext; // <-- This is missing an makes the Error
}


Hope it help



On 2010/10/07, at 13:15, David Avendasora wrote:

Hi D2Wers,

When I try to change the number of results in an embedded listing I get  "Attempt to insert null object into an  com.webobjects.foundation.NSDictionary." (full stack trace below).  I've checked several places where I'm displaying toMany relationships and it throws the error in all of them. If it is not embedded, just a listing of objects that match a query then it works as expected.

It appears that the ERMBatchSizeControl returns null for d2wContext() when it's tied to an embedded listing.

Dave


Oct 07 06:47:09 TotalViewAdminD2W[9191] (TVWApplication.java:283) ERROR er.extensions.appserver.ERXApplication  - Uncaught exception: Attempt to insert null object into an  com.webobjects.foundation.NSDictionary.
Extra info: {
"D2W-SubTask" = "null";
"D2W-PageConfiguration" = "ListEmbeddedCCCommunicationIdentity";
"CurrentComponent" = "er.modern.directtoweb.components.ERMDBatchSizeControl";
"PreviousPageList" = (
"QuerySamsStudent",
"ListSamsStudent",
"InspectSamsStudent"
);
"D2W-PropertyKey" = "null";
"D2W-DisplayPropertyKeys" = (
"communication.communicationDate",
"role.displayName",
"identity.firstname",
"identity.lastname",
"communication.subject"
);
"CurrentPage" = "er.modern.look.pages.ERMODTabInspectPage";
"Current Account" = "10193338";
"URL" = "/cgi-bin/WebObjects/TotalViewAdminD2W.woa/ajax/hV8rQV1q1R2BMjuPYav2xw/5.0.3.5.1.2.3.0.1.0.0.3.3.0.1.3.1263925117.0.1.3.0.1.0.1.3.0.1.3.1.2.0.0.0.0.1.2.3.1.0.3.3.1.1.9.1.0.1.1.0.9";
"CurrentComponentHierarchy" = (
"er.modern.look.pages.ERMODTabInspectPage",
"er.modern.directtoweb.components.repetitions.ERMDInspectPageRepetition",
"er.directtoweb.components.relationships.ERDList",
"er.directtoweb.embed.ERXD2WList",
"er.directtoweb.components.ERD2WSwitchComponent",
"er.modern.look.pages.ERMODListPage",
"er.modern.directtoweb.components.ERMDBatchSizeControl"
);
"D2W-EntityName" = "CCCommunicationIdentity";
"D2W-ComponentName" = "ERD2WDisplayString";
"Headers" = {
"user-agent" = "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_4; en-us) AppleWebKit/533.18.1 (KHTML, like Gecko) Version/5.0.2 Safari/533.18.5";
"cookie" = "__utmc=188508456; __utma=188508456.1010180370.1286383408.1286383408.1286383408.1; __utmz=188508456.1286383408.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none)";
"origin" = "http://10.0.1.8:9191";
"accept" = "text/_javascript_, text/html, application/xml, text/xml, */*";
"referer" = "http://10.0.1.8:9191/cgi-bin/WebObjects/TotalViewAdminD2W.woa/wo/hV8rQV1q1R2BMjuPYav2xw/3.0.3.5.1.2.3.0.1.0";
"content-type" = "application/x-www-form-urlencoded; charset=UTF-8";
"accept-encoding" = "gzip, deflate";
"content-length" = "27";
"x-prototype-version" = "1.6.1";
"original_context_id" = "5";
"x-requested-with" = "XMLHttpRequest";
"host" = "10.0.1.8:9191";
"accept-language" = "en-us";
"connection" = "keep-alive";
};
"Current User" = "Reed Ckeade";
}

IllegalArgumentException: Attempt to insert null object into an  com.webobjects.foundation.NSDictionary.
  at com.webobjects.foundation.NSDictionary.<init>(NSDictionary.java:170)
  at er.modern.directtoweb.components.ERMDBatchSizeControl.setNumberOfObjectsPerBatch(ERMDBatchSizeControl.java:177)
     ... skipped 21 stack elements
  at ognl.helperfunction.WOHelperFunctionKeyValueAssociation.setValue(WOHelperFunctionKeyValueAssociation.java:21)
  at er.ajax.AjaxInPlaceEditor.handleRequest(AjaxInPlaceEditor.java:168)
     ... skipped 232 stack elements
  at er.ajax.AjaxRequestHandler.handleRequest(AjaxRequestHandler.java:17)
     ... skipped 1 stack elements
  at er.extensions.appserver.ajax.ERXAjaxApplication.dispatchRequest(ERXAjaxApplication.java:50001)
     ... skipped 1 stack elements
  at com.k12.totalview.app.TVWApplication.dispatchRequestImmediately(TVWApplication.java:50001)
  at com.k12.totalview.app.Application.dispatchRequestImmediately(Application.java:50001)
     ... skipped 1 stack elements
  at com.k12.totalview.app.TVWApplication.dispatchRequest(TVWApplication.java:213)
  at com.k12.totalview.app.Application.dispatchRequest(Application.java:42)
  ... skipped 3 stack elements



Thank you

--------------------------------------------------------
K's ROOM      (ISHIMOTO Ken)
--------------------------------------------------------
[E-Mail]  <email@hidden>
[iChat:]   <email@hidden>
[HP]          http://www.ksroom.com/
_____________________________________________________________________
This e-mail has not been scanned for viruses because it was written on an Mac,
and there are NO Viruses on an Apple Computer.
For further information visit http://www.apple.com



 _______________________________________________
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: 
 >ERMBatchSizeControl problem with embedded listings (From: David Avendasora <email@hidden>)

  • Prev by Date: Re: WOComponent.generateResponse
  • Next by Date: Nothing goes in "Referenced Libraries"
  • Previous by thread: Re: ERMBatchSizeControl problem with embedded listings
  • Next by thread: ERRest, D2WContext, displayPropertyKeys and localizer issue
  • Index(es):
    • Date
    • Thread