对于OATableBean&OAAdvancedTableBean中NUMBER数据按指定格式显示
来源:互联网 发布:linux 退出gdb调试 编辑:程序博客网 时间:2024/06/05 05:23
OATableBean&OAAdvancedTableBean中Number列的数据在默认情况下会自动根据数据是否有小数在表中展示,但是如果业务要求表内的所有Number列,特别是金额列按照固定格式展示就需要在co中进行代码控制:
方法一:根据币种显示数据(代码)
OAMessageStyledTextBean stextBean=(OAMessageStyledTextBean)webBean.findChildRecursive(“列的ID”);//OAMessageStyledTextBean可以根据情况修改
if(stextBean!=null){
stextBean.setAttributeValue(CURRENCY_CODE, "CNY");
}
方法二:根据自定义的样式展现(代码)
Formatter formatter = new OADecimalValidater("#,###,###,##0.00;(#,###,###,##0.00)", "#,###,###,##0.##;(#,###,###,##0.##)");
OAMessageStyledTextBean stextBean=(OAMessageStyledTextBean)webBean.findChildRecursive(“列的ID”);//OAMessageStyledTextBean可以根据情况修改
if(stextBean!=null){
stextBean.setAttributeValue(ON_SUBMIT_VALIDATER_ATTR, formatter);
}
0
NumberYesDigit#
NumberYesDigit, zero shows as absent.
NumberYesDecimal separator or monetary decimal separator-
NumberYesMinus sign,
NumberYesGrouping separatorE
NumberYesSeparates mantissa and exponent in scientific notation. Need not be quoted in prefix or suffix.;
Subpattern boundaryYesSeparates positive and negative subpatterns%
Prefix or suffixYesMultiply by 100 and show as percentage\u2030
Prefix or suffixYesMultiply by 1000 and show as per mille value¤
(\u00A4
)Prefix or suffixNoCurrency sign, replaced by currency symbol. If doubled, replaced by international currency symbol. If present in a pattern, the monetary decimal separator is used instead of the decimal separator.'
Prefix or suffixNoUsed to quote special characters in a prefix or suffix, for example, "'#'#"
formats 123 to"#123"
. To create a single quote itself, use two in a row: "# o''clock"
.
- 对于OATableBean&OAAdvancedTableBean中NUMBER数据按指定格式显示
- 按照指定格式显示数据表数据
- C#中对于Json格式数据的处理
- 对于ListView中TextView的数据显示问题
- oracle 中将number类型的数据转化成指定格式的小数
- Java爬虫,爬取竞彩网数据并按指定格式输出到excel表格中
- 更改数据到指定格式
- GridView 数据显示格式
- 对于json格式数据节点的解析
- MySQL数据库按指定格式导出、导入数据
- SQL Developer快速按指定格式导出数据
- 数据库数据按指定格式导出到Excel
- echars 自定义tooltip中显示格式和柱状图上(series)数据显示格式
- 通过递归方法 将DataTable中的树状数据信息 按树状格式显示在DropDownList中
- flex中如何对数据的显示格式进行设置
- localStorage数据指定位置显示
- 对于数据的显示在 StringGrid 的 OnDrawCell 事件中写程序
- shell中按格式显示日期
- Lucene 检索的early termination
- dba_segments 查看表使用的容量
- linux或者UC/OS
- 第一章-内核模块
- Eclipse中java文件和jsp字体大小设置
- 对于OATableBean&OAAdvancedTableBean中NUMBER数据按指定格式显示
- 查看表空间的容量
- Android Log
- 【Unity3D 游戏开发之一】搭建Unity3D环境&导出自带Demo示例
- 炫彩界面库设计
- Session的生命周期
- 重新定位自己
- 实际项目中的常见算法
- Asp.net Jquery Dialog 2