Dear Community,
I have the following situation:
We have a S/4Hana 1909 On-Premise in place, SAP_BASIS 7.54 SP 01, and SAP_ABA 7.5E, SP 01.
I created a Fiori-Elements Application using RAP (unmannaged), respective CDS-View and OData-Service, Service Behaviour/Definition, Behaviour Implementation etc.
I have a search help in place, using the annotation
@Consumption.valueHelpDefinition
I even created an association to that CDS-View that is providing me data for the search help, and the search help works fine.
The problem is: the users can still enter values that are not contained in the Search Help, and these values are accepted upon saving.
Instead, I want those values to be automatically restricted to those that are coming from the search help (throwing some error messages etc. would be a cool feature too), like when you create a table and a table-view maintainance from SM30, and you provide foreign-key relationship to another table, you get the search-help and those checks for free (automatically). I even tried with the annotation
@ObjectModel.foreignKey.association:
to get the value help and see if this works, but it didn't. Then I've tried to put the foreign key relationship directly to the data base table definition in eclipse, using
with foreign key [0..*,1]
statement, but it didn't helped either.
So, the questions is, is it even possible to provoke this check intrinsically/automatically, ( for e.g. using annotations), or do we have to implement this manually in the validation? I was searching the documentation, blogs, developers-pages, and so far, i was not able to find anything. Maybe someone could pin-point me to an ressource/blog where this point was already discussed?
Maybe it is not possible yet for unmanaged?
Doing it manually via coding would be to much effort for each field.
Thank you all very much in advance!!
Best regards,
Aleks
Request clarification before answering.
Dear Aleksandar,
After adding value help/F4 help for a field using annotation @Consumption.valueHelpDefinition, you can add a validation for the values using annotation @Consumption.valueHelpDefinition.useForValidation. This validation marks value help that shall be used for validation of user input. For more information on usage of annotations, visit below official SAP help portal:
Consumption Annotations | SAP Help Portal
Thanks
Abhishek Khanna
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 5 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.