Hi Gurus,
I need a technical help to make the Value Help feature of Smart Field Control working: https://sapui5.hana.ondemand.com/#docs/guide/3361e270c62c46c9893eaefb2966d62e.html .
Implementation is done, but a small piece is missing in the backend, what I could not identify, due lack of documentation. The annotations metadata is not returned by the backend system. So I need help to find the missing part in implementation of the valuelist annotation in SEGW for an entity property.
1. System environment
Service is implemented in ECC backend
and registered in GateWay HUB system, where the BSP application is deployed
We have SAPUI5 libraries version 1.28.8-10 installed.
I’ve applied latest OSS Notes in both systems regarding annotations, and regenerated runtime objects.
2. Implementation
It consists of two parts:
- a.) base project: ZMD_VENDOR
- b.) vocabulary project: ZMD_VENDOR_ANNO
SEGW Project is ZMD_VENDOR for which I would like to create valuelist annotations for property Anred (Title)
I defined entity AddressTitle entity and AddressTitles entityset to be used in valuelist annotation
Since the project ZMD_VENDOR is of type Service with SAP Annotations, I had to create a new project ZMD_VENDOR_ANNO with type Annotation Model for Referenced service, importing vocabulary (/IWBEP/VOC_COMMON/com.sap.vocabularies.Common.v1), and service reference to ZECC_MD_VENDOR.
I set Text annotations for AddressTitle
and valuelist annotation for property Anred (Title)
After generation and service registration, I can see that now the annotation service is properly assigned to the base service in
/IWBEP/REG_VOCAN - Maintain Vocabulary Annotations
I added the following code part to the base service model provider class extension to register the annotation model using its technical model name ZMD_VENDOR_ANNO_MDL.
Metadata of the annotation service seems fine:
The annotation model seems referenced in base service metadata,but the problem is (why the smart field on the UI is not showing valuehelp/dropdownlist), that the annotation tags and properties are missing in metadata xml below, for which I created the annotations in annotation project:
Metadata: (collapsed)
Metadata: Request entity with entity property Anred(Title) (expanded)
AddressTitle entity, with property Title (expanded)
Reason is unknown for the missing annotations. Anyone any idea or example on this.
Thank you!
P.S.:
Smart controls and OData annotations v4 are great, can reduce UI implementation costs, and keep logic in the backend, However documentation not really available on this concept, and about the framework, Do you have one ? I've tried to investigate examples, but there is only an sflight test annotation service and class in the backend. but this is annotation within the same model. Now I need to do external annotations.