SAP Fiori globalization实现原理分析

简介: SAP Fiori globalization实现原理分析

This issue is copied from one of Jerry’s workshop regarding Fiori Globalization implementation.

You have observed the following behavior: the sales volume is displayed in detail view with 1880 USD, while in master list, it is displayed as 2K for short. Why?


image.pngThe truncation behavior in master list is implemented by Fiori application to fulfill the product standard of Globalization requirement.

The exact value for SalesVolume is 1880.00,


image.pngimage.pngAnd in order to understand the implementation detail of framework API “FormatAmountShort”, we have to understand the definition of CLDR - Unicode Common Locale Data Repository.

The Unicode CLDR provides key building blocks for software to support the world’s languages, with the largest and most extensive standard repository of locale data available. This data is used by a wide spectrum of companies for their software internationalization and localization, adapting software to the conventions of different languages for such common software tasks. See one part of CLDR definition below from http://cldr.unicode.org/translation/number-patterns :


image.pngimage.pngThe English version of CLDR content defined in the web page http://cldr.unicode.org/ is packed and stored in JSON file en.json by SAP and is now loaded:


image.pngAnd here below is the code how “1880” is transformed to “2k” by framework code:image.pngThe reason why English version of CLDR file is loaded is the language setting of the browser.

UI5 runtime will use the first Language configured in browser as primary language for all subsequent language-specific configuration stuff load mechanism, as illustrated in line 67 below:


image.png

相关文章
|
5月前
|
人工智能 搜索推荐 Serverless
使用金庸的著作,来测试阿里通义千问最新开放的长文档处理功能
使用金庸的著作,来测试阿里通义千问最新开放的长文档处理功能
使用金庸的著作,来测试阿里通义千问最新开放的长文档处理功能
|
5月前
|
数据库 API
启用SAP Fiori之前的一些注意事项
启用SAP Fiori之前的一些注意事项
|
5月前
|
JavaScript 前端开发
试读版:如何找出 SAP 标准 Fiori 应用某个按钮点击后执行的 JavaScript 源代码
试读版:如何找出 SAP 标准 Fiori 应用某个按钮点击后执行的 JavaScript 源代码
|
5月前
|
网络安全
实战分析 - 为什么有些 SAP ABAP 程序,启动之后界面有些按钮是灰色的试读版
实战分析 - 为什么有些 SAP ABAP 程序,启动之后界面有些按钮是灰色的试读版
SAP UI5 Link 控件的使用方法介绍 - 后续学习 Fiori Elements Smart Link 的基础试读版
SAP UI5 Link 控件的使用方法介绍 - 后续学习 Fiori Elements Smart Link 的基础试读版
|
5月前
|
UED
什么是 SAP Fiori 的 Technical Catalog 和 Business Catalog
什么是 SAP Fiori 的 Technical Catalog 和 Business Catalog
|
5月前
|
前端开发 UED
SAP Fiori 到底指什么
SAP Fiori 到底指什么
|
5月前
|
XML 前端开发 JavaScript
SAP Fiori Launchpad Custom Fields tile 里的 ABAP 语法高亮显示
SAP Fiori Launchpad Custom Fields tile 里的 ABAP 语法高亮显示
|
5月前
|
前端开发 搜索推荐 开发者
SAP UI5 sap.m.Column 控件的 minScreenWidth 属性介绍
SAP UI5 sap.m.Column 控件的 minScreenWidth 属性介绍
|
5月前
|
JavaScript 前端开发 开发者
SAP UI5 控件 sap.m.ListBase 的 inset 属性的作用介绍
SAP UI5 控件 sap.m.ListBase 的 inset 属性的作用介绍