Numbers not formatted properly in Struts 2

后端 未结 2 1023
不知归路
不知归路 2021-01-16 11:22

I am using following syntax to display a value in a proper number format, e.g. 1,250.00.



        
2条回答
  •  渐次进展
    2021-01-16 12:15

    If the value is printed like 1250.00 then it's not formatted properly. The method getText() has many overloaded methods and which method is used is determined by the parameter's types and count.

    To pass arguments to the getText() method you can use OGNL list construction {}. And the arguments should be listed as single values, not "list of object". Perfectly it should be list of Double with one element inside the list.

    
    
    

提交回复
热议问题