struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brajesh Patel <brajeshpate...@gmail.com>
Subject Re: Another Date Time Format
Date Sat, 29 Jan 2011 04:54:57 GMT
I think it is possible with transient

if you don't want to change field in the data base then use variable as
transient.



On Sat, Jan 29, 2011 at 9:58 AM, Nick Broadhurst <hou1nxb@gmail.com> wrote:

> Hi,
>
> I am displaying two date-time fields from my demographics object which
> populates from the DB:
>
> <s:date name="demographics.creationDate"/>
> <s:date name="demographics.lastModificationDate"/>
>
> Both fields show the full date and time. Perfect.
> I need the creation date to go back in unchanged on form submit. Tried
> this:
>
> <s:hidden name="demographics.creationDate"/>
>
> But only populates the date into hidden field and when it goes back into
> DB,
> the time is 00:00:00. No Good.
> Is there a version of this:
>
> <s:hidden name="demographics.creationDate"
> value="%{demographics.creationDate}"/>
>
> that I can use a date-time function also to get the hidden field to use
> full
> date-time? I haven't messed formatting the the field
> in my action first because it is already in that format as shown by the
> s:date displayed values.
>
> Or is there a better way to do it?
>
> Thanks,
>
> Nick
>



-- 
Thanks
Brajesh Patel

HotWax Media
http://www.hotwaxmedia.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message