On Tue, 1 Jul 2003, Jon Wilmoth wrote:
> Date: Tue, 1 Jul 2003 11:50:59 -0700 (PDT) > From: Jon Wilmoth <[EMAIL PROTECTED]> > Reply-To: Struts Developers List <[EMAIL PROTECTED]>, > [EMAIL PROTECTED] > To: Struts Developers List <[EMAIL PROTECTED]> > Subject: Re: [BeanUtils & Struts]RE: Support for Date datatypes!!! > > The problem is I have existing code that does custom > string --> date --> string conversion. I'm not > looking for a better work-around. I believe this is > functionality that everyone who builds a struts > application will have to implement with custom code > and thus is an excellent Struts/BeanUtils enhancement > candidate! I do realize this is NOT a simple task as > it has come up on the mailing list a number of times > in the last 3 years and still remains not implemented. > Here are some use cases that illustrate the desired > behavior (remember, I'm looking for round-trip support > of the date datatype): > If it were easy, it would have been done already :-). > Use Case 1 (Data Input): > 1) User enter's birthdate in MM/dd/yyyy format > .. In most of Europe, and many other places, that would be dd/MM/yyyy. > Use Case 2 (Data Input): > 1) User standard workday start time in "HH:mm" format > .. 12 hour clock or 24 hour clock? > Use Case 3 (Data Input): > 1) User enters month of year for month long event > (i.e. Black History Month) "MMMM" format > .. Presumably the user can specify this in whatever language they like? > > Use Case 3 (Data Output): > 1) User Admin views list of user names and birthdays. > 2) System displays username and birthday using > standard MM/dd/yyyy format. That's not the "standard" in many places. > 2.a) System will display date in format specified by > user preferences (i.e. EE MMMM dd yyyy) overriding the > standard MM/dd/yyyy format. This is where solutions based on ConvertUtils really fall down, because Converters are web-app wide. It's one of the symptoms of the fact that Struts doesn't really support UI "components" at the moment -- it just supports simple fields. Craig --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]