You can tell Stripes how to format the field value via the
"formatType" and "formatPattern" attributes of <s:text>.  The type in
your case would probably be "number", and the pattern would be either
a resource key for a pattern stored as a Stripes property, or else a
raw java.text.MessageFormat pattern.

On Fri, Mar 15, 2013 at 2:10 PM, Chris Cheshire <cheshira...@gmail.com> wrote:
> Using Stripes 1.5.7, I have an action bean to process a form. One
> field is a BigDecimal. When it has a small value (in this case
> 0.00013450), it is being displayed as 0 when used in conjunction with
> a stripes text box, text area or even hidden field :
>
> <stripes:text name="btcCost" size="20" />
>
> If I use JSP-EL, ${actionBean.btcCost}, to display it on the page, I
> get the correct value. If I use vanilla html code and JSP-EL to grab
> the value from the action bean, I get the right value in the field.
>
> It initially saved the correct value via the form, but any attempts to
> present it are failing, even though the accessor is returning the
> right value.
>
> Is there anything special I need to do (other than reverting to
> vanilla html) to get BigDecimal form fields working?
>
> Chris
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_d2d_mar
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/stripes-users



-- 
Turtle, turtle, on the ground,
Pink and shiny, turn around.

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
_______________________________________________
Stripes-users mailing list
Stripes-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to