如何使用配置的方式修改SAP C4C UI的字段标签,以及背后的工作原理

简介: 如何使用配置的方式修改SAP C4C UI的字段标签,以及背后的工作原理

I was asked by one partner that it is expected to adapt the label of “New” button into “Add”, and change the text of first menu item from “Add” to “From Contact”.

image.png

Here below is detail step how to achieve this requirement.

(1) Work center Administrator, General Settings->Language Adaptations:

image.png

Create a new Language Adaptation:

image.png

Select the Work center view where the button and menu item resides in:

image.png

Click Edit button and then click button “Collect Texts”:

image.png

(2) Now you could do actual text adaptation. Do filtering by “New” keyword and restrict UI Element Type to only display Button to avoid too many items with Source Text equals to “Add”. Since there are lots of “New” button defined within this work center view, so you have to also use column “UI Short Name” to identify the very button in Contact OWL toolbar.

image.png

Replace “Add” with “From Contact” as well.

image.png

Write down the ID of this text for later usage: igVref5FuaY1LnI6tdBKZm


How Text adaptation works under the hood

In the runtime the adapted text works as expected.


image.png

Neither the original text shipped by SAP nor the adapted text is directly bound to menu item. Instead, there is a binding existed to connect an instance of UI text pool with the text property of menu item.


Copy the source code of COD_Account_TI from HTTP response in the network tab of Chrome development tool and search by ID igVref5FuaY1LnI6tdBKZm:


image.png

One entry for text pool instance found:

image.png

And in the runtime, we can see the text property of menu item is bound to this text pool instance:

image.png

image.png


相关文章
|
5月前
|
前端开发 JavaScript API
SAP UI5 sap.ui.require.toUrl 的作用介绍
SAP UI5 sap.ui.require.toUrl 的作用介绍
|
5月前
|
JSON 前端开发 测试技术
SAP UI5 sap.ui.core.util.MockServer.simulate 方法介绍
SAP UI5 sap.ui.core.util.MockServer.simulate 方法介绍
使用 SAP UI5 Event Bus 机制,修复 SAP UI5 分页显示数据的一个 bug 试读版
使用 SAP UI5 Event Bus 机制,修复 SAP UI5 分页显示数据的一个 bug 试读版
|
5月前
|
监控 测试技术
SAP 电商云修改 Product Catalog Staged 版本数据后,同步到 online 版本的 UI 操作
SAP 电商云修改 Product Catalog Staged 版本数据后,同步到 online 版本的 UI 操作
什么是 SAP ABAP 里的 Subscreen
什么是 SAP ABAP 里的 Subscreen
什么是 SAP ABAP 里的 Subscreen
|
5月前
|
数据库
SAP CRM产品主数据无法根据产品描述字段进行搜索的原因
SAP CRM产品主数据无法根据产品描述字段进行搜索的原因
|
5月前
|
中间件
SAP UI5 Tooling 实战:动手创建自己的 Custom UI5 Server Middleware 试读版
SAP UI5 Tooling 实战:动手创建自己的 Custom UI5 Server Middleware 试读版
SAP UI5 Tooling 实战:动手创建自己的 Custom UI5 Server Middleware 试读版
|
5月前
|
XML JavaScript 数据格式
SAP UI5 XML Preprocessor 的工作原理和 instructions 指令详解
SAP UI5 XML Preprocessor 的工作原理和 instructions 指令详解
|
5月前
|
JSON 数据格式
SAP UI5 Class sap.ui.model.Context 的作用介绍
SAP UI5 Class sap.ui.model.Context 的作用介绍
SAP Fiori Elements 应用里图片字段(Image)的显示原理介绍试读版
SAP Fiori Elements 应用里图片字段(Image)的显示原理介绍试读版
下一篇
无影云桌面