cancel
Showing results for 
Search instead for 
Did you mean: 

Validations in Business Rules in SAP Cloud Platform

0 Kudos

Hi All,

I have created a FIORI app to display the business rules from SCP with the help of below blog

https://blogs.sap.com/2017/12/21/author-sap-cloud-platform-based-business-rules-using-fiori-applicat...

Has anyone added validations on particular cell(of the business rules table on screen) while using Business Rules API?

~Sruti

Accepted Solutions (0)

Answers (2)

Answers (2)

vikrant_patil
Employee
Employee

Hi Sruti,

What kind of validations do you want achieve at a cell level? Can you provide some more information to understand your requirement?

Regards,

Vikrant

0 Kudos

Hi Vikrant,

We plan to have materials as one of the columns in Business Rules Table. We wanted to validate the materials entered by user with the SAP materials(maintained in ECC which can be retrieved by making an odata call).

Regards,

Sruti

vikrant_patil
Employee
Employee

Hi Sruti,

We plan to provide value help (future) for selecting a value from allowed list of values. I think this will solve your use case and do not need a validation at cell level. Do you agree?

Regards,

Vikrant

0 Kudos

Yes. It would resolve our problem. Thank you

Archana
Product and Topic Expert
Product and Topic Expert
0 Kudos

Yes Shruti, Validations are there at two levels in business rules editor. Once when you are modelling the rules and next when you are deploying the rules. They are design time and runtime validations respectively. Design time validation you can trigger on clicking the Validate button on the editor of each rule artefacts and runtime validations are triggered when you Deploy the rule service. The validation errors are shown in the notification bars on top right corner of the editor

0 Kudos

Hi Archana,


I have create a custom sapui5 screen by embedding the Rules Editor UI and integrating with Business Rules ODATA services.

I am trying to write some additional validations on the screen data that business user has entered, before saving/deploying the rules from my custom screen. The model binding seems to be quite complex to dynamically read it. Is there a way to read the screen data from the business rules UI?

Regards,
Sruti

Archana
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Shruti,

You can write small utility methods using business rules repository APIs. Now we have REST repository APIs , you can use them over ODATA APIs. There are no handle to read data from UI elements. Rules already provides validation of the its content but if you need additional data validation then you need to write your utilities.