如何将SAP CRM产品主数据页面的assignment block设置成只读

Created by Jerry Wang, last modified on Sep 29, 2016

Metadata table for relationship:

如何将SAP CRM产品主数据页面的assignment block设置成只读_第1张图片

This method can only set existing data to read only, but could NOT prevent user from creating new data in WebUI.

如何将SAP CRM产品主数据页面的assignment block设置成只读_第2张图片

This method can allow you ( GenIL layer ) to add some post processing of data retrieved from API layer

如何将SAP CRM产品主数据页面的assignment block设置成只读_第3张图片

It works as screenshot below.
How to disable these two buttons:

如何将SAP CRM产品主数据页面的assignment block设置成只读_第4张图片

Approach 1: change enabled attribute in gt_button
Appraoch 2: hard code displayMode = read only

如何将SAP CRM产品主数据页面的assignment block设置成只读_第5张图片
如何将SAP CRM产品主数据页面的assignment block设置成只读_第6张图片

How to disable Edit List button:

Same idea:

如何将SAP CRM产品主数据页面的assignment block设置成只读_第7张图片
如何将SAP CRM产品主数据页面的assignment block设置成只读_第8张图片

要获取更多Jerry的原创文章,请关注公众号"汪子熙":
如何将SAP CRM产品主数据页面的assignment block设置成只读_第9张图片

你可能感兴趣的:(Jerry,Wang的原创SAP技术文章,CRM,ABAP)