SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較

i042416發表於2020-09-27

Formatted Text Edit is supported both in CRM and Cloud for Customer ( starting from 1702 according to blog  What’s New in 1702 SAP Hybris Cloud for Customer – Responsive UI.

Formatted Text Edit in CRM

Sometimes when you create new button in Note assignment block:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


The Formatted Text Edit control is available, since you can see various buttons in toolbar now.


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


However when you have chosen one Text Type from drop down list, the Formatted Text Edit control is gone, instead a pure Text Edit field is displayed.


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


The reason is simply because the Formatted edit function for the given text type is not enabled in customizing, which could be done via SPRO->Basic Functions->Text Management->Define Text Format: create a new entry for the text type and mark the checkbox “Formatted”:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


After that the Formatted Text Editor is back:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


Take the rich text I maintained in above for example,when you open the page next time, as its name means, you could observe the formatted text is read from database by function module READ_TEXT.


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較 SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


Formatted Text Edit in C4C

I am asked by partners why Formatted Text edit is enabled in some tenant while disabled in some others.

Take the Product Tab in Sales Quote TI for example:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


There are two “duplicate” Text Edit controls, value of one is bound to model field “text” and the other with “FormattedText”:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較 SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


In the runtime both the pure text and formatted text are returned from ABAP backend, the HTTP response could be monitored in Chrome development tool:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


The flags to control which of them should be visible in the runtime are IsItemNotesPlainTextVisible and IsItemNotesFormattedTextVisible accordingly.


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較 SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


This is the reason why you could observe the different behavior in different tenant in the runtime:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較 SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


For sure these flags are determined by BC scoping in backend:


SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


Further reading

Jerry’s blogs regarding the comparison how CRM and Cloud for Customer implement a given feature using different approaches:

要獲取更多Jerry的原創文章,請關注公眾號"汪子熙":

SAP CRM和Cloud for Customer裡的Formatted Text控制元件的比較


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/24475491/viewspace-2724415/,如需轉載,請註明出處,否則將追究法律責任。

相關文章