That was it.. I needed to use the correct format for the Joda formatter, ie:  

public ERXJodaLocalDateFormatter jodaFormat1 = new 
ERXJodaLocalDateFormatter("MM/dd/yyyy");

Thanks. I really wanted to use the date instead of a Timestamp


Ted



--- On Thu, 9/15/11, Ramsey Gurley <[email protected]> wrote:

> From: Ramsey Gurley <[email protected]>
> Subject: Re: Joda question
> To: "Theodore Petrosky" <[email protected]>
> Cc: "WebObjects Development" <[email protected]>
> Date: Thursday, September 15, 2011, 4:25 PM
> Hi Ted,
> 
> Those are NSTimestampFormatter symbols.  You want to
> use formatter symbols the joda DateTimeFormatter expects...
> something like "MM/dd/yyyy" for your format string. 
> Then in the ADP, the format string is read from the
> formatter and passed through
> translateSimpleDateFormatSymbols.  
> 
> I don't know who added that part, but it looks like it
> should do the trick.  I haven't tried it personally,
> but it sounds like Hernrique has been using it for a while
> now (^_^)
> 
> Ramsey
> 
> On Sep 15, 2011, at 1:13 PM, Chuck Hill wrote:
> 
> > Unless Ramsey or someone changed this, it may not
> support the Joda stuff.
> > 
> > On 2011-09-15, at 12:59 PM, Theodore Petrosky wrote:
> > 
> >> Thanks Paul, but I tried:
> >> 
> >> public ERXJodaLocalDateFormatter jodaFormat1 = new
> ERXJodaLocalDateFormatter("%m/%d/%Y");
> >> 
> >> And it throws the same error:
> >> 
> >> <er.ajax.AjaxRequestHandler>: Exception
> occurred while handling request:
> >> java.lang.IllegalArgumentException: Invalid
> format: "09/28/2011"
> >> 
> >> I also tried it with NO formatter and the app
> crashed saying that it did not like the NSTimestamp
> >> 
> >> IllegalArgumentException: While trying to set the
> field "myJodaDate" on an object of type
> com.eltek.components.Main we expected a
> org.joda.time.LocalDate but received a
> com.webobjects.foundation.NSTimestamp with a value of
> 2011-09-30 04:00:00 Etc/GMT. This often happens if you
> forget to use a formatter.
> >> 
> >> other ideas??
> >> 
> >> Ted
> >> 
> >> --- On Thu, 9/15/11, Paul Yu <[email protected]>
> wrote:
> >> 
> >>> From: Paul Yu <[email protected]>
> >>> Subject: Re: Joda question
> >>> To: "Theodore Petrosky" <[email protected]>
> >>> Cc: "Ramsey Gurley" <[email protected]>,
> [email protected]
> >>> Date: Thursday, September 15, 2011, 3:44 PM
> >>> The last time I looked at this. 
> >>> The date format for AjaxDatePicker HAD to be
> %m/%d/%Y.
> >>> 
> >>> Paul
> >>> On Sep 15, 2011, at 3:28 PM, Theodore Petrosky
> wrote:
> >>> 
> >>>> thanks, I checked the path and I saw that
> >>> ERAttributeExtension was not included. So I
> added it, and
> >>> yes I now the fetch works and shows the
> correct date.
> >>>> 
> >>>> I am playing with an AjaxDatePicker and
> there is a
> >>> problem when the form is submitted.
> >>>> 
> >>>> JodaTestCalendar : AjaxDatePicker {
> >>>>    value = myJodaDate;
> >>>>    formatter = jodaFormat1;
> >>>>    id =
> "DateInputWithFormatField";
> >>>> }
> >>>> 
> >>>> here is my formatter:
> >>>> 
> >>>> public ERXJodaLocalDateFormatter
> jodaFormat1 = new
> >>> ERXJodaLocalDateFormatter("%Y-%m-%d");
> >>>> 
> >>>> Here is my form:
> >>>> 
> >>>> <wo:WOForm>
> >>>> <webobject name =
> >>>
> "JodaTestCalendar"/><wo:AjaxSubmitButton  action
> >>> = "$insertDate" value = "Insert"
> >>> updateContainerID="loopID"/>
> >>>> </wo:WOForm>
> >>>> 
> >>>> the method insertDate is not getting
> called
> >>>> 
> >>>> <er.ajax.AjaxRequestHandler>:
> Exception occurred
> >>> while handling request:
> >>>> java.lang.IllegalArgumentException:
> Invalid format:
> >>> "2011-09-17"
> >>>> 
> >>>> any idea where I should look?
> >>>> 
> >>>> Ted
> >>>> 
> >>>> --- On Thu, 9/15/11, Ramsey Gurley <[email protected]>
> >>> wrote:
> >>>> 
> >>>> From: Ramsey Gurley <[email protected]>
> >>>> Subject: Re: Joda question
> >>>> To: "Theodore Petrosky" <[email protected]>
> >>>> Cc: [email protected]
> >>>> Date: Thursday, September 15, 2011, 11:26
> AM
> >>>> 
> >>>> 
> >>>> On Sep 15, 2011, at 7:14 AM, Theodore
> Petrosky wrote:
> >>>> I did a wonder fetch and I get this
> error:
> >>>> 
> >>>>
> TestBedTable.fetchAllTestBedTables(theEC);
> >>>> 
> >>>> Class org.joda.time.LocalDate does not
> implement
> >>> method jodaLocalDate
> >>>> 
> >>>> Am I missing something (meaning am I
> supposed to
> >>> import something specific)?
> >>>> 
> >>>> 
> >>>> Make sure you added ERAttributeExtension
> to your
> >>> classpath ahead of the JavaEOAccess
> framework.
> >>>> http://webobjects.mdimension.com/hudson/job/Wonder/javadoc/er/attributeextension/package-summary.html
> >>>> If you've done that, then I suspect you've
> saved a a
> >>> change in ERPrototypes which caused WOLips to
> overwrite some
> >>> attribute settings it doesn't understand yet.
> It should be
> >>> calling the static method on the
> >>> valuefactory/valueconversion classes in the
> ERPrototype
> >>> framework.
> >>>> Ramsey
> >>>> 
> >>>>
> _______________________________________________
> >>>> Do not post admin requests to the list.
> They will be
> >>> ignored.
> >>>> Webobjects-dev mailing list   
>   ([email protected])
> >>>> Help/Unsubscribe/Update your
> Subscription:
> >>>> http://lists.apple.com/mailman/options/webobjects-dev/pyu%40mac.com
> >>>> 
> >>>> This email sent to [email protected]
> >>> 
> >>> 
> >> _______________________________________________
> >> Do not post admin requests to the list. They will
> be ignored.
> >> Webobjects-dev mailing list     
> ([email protected])
> >> Help/Unsubscribe/Update your Subscription:
> >> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
> >> 
> >> This email sent to [email protected]
> > 
> > -- 
> > Chuck Hill         
>    Senior Consultant / VP Development
> > 
> > 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 protected])
> > Help/Unsubscribe/Update your Subscription:
> > http://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
> > 
> > This email sent to [email protected]
> 
>
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to