Skip to Content

SAP Cloud Application Studio: Instance Based Acess Context

Hi Experts,

I want to implement Instance based access context for our custom BO.

I read through the below blog:

https://blogs.sap.com/2014/07/21/instance-based-access-control/

https://archive.sap.com/discussions/thread/3796858

I have configured exactly how Horst has mentioned on August 6, 2014 at 8:34 am

We need to set 1015 Employee or Territory. But the filter doesn't work. And more over, there is an exception on Save of any value at the BO level.

Please provide some inputs.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Nov 03, 2016 at 04:21 AM

    Hi Gayathri,

    For point 1):
    Check if the Account Workcentre View supports

    Access context "EmployeeOrTerritory"

    For point 2)
    You should be setting the association in BeforeSave event, during migration also BeforeSave event should be executed which should take care of the association, if you have data with assoication not set, then you could create MDRO to set such association.

    Thanks, Pradeep.

    Add comment
    10|10000 characters needed characters exceeded

    • Thanks Pradeep for your response.

      For Point 1) I think we have already set the access context to EmployeeOrTerritory across the application. But I will double check and update here.

      For Point 2) At present, the association level and element level access context is set in during Before Save event, but the determination of the territory is based on the logged in user. So during migration, it will through ODATA service import. So I'm still not clear how to handle this. I will check about the MDRO you have mentioned. Please share if any blog or documentation links if you have any.

      Thanks

      Gayathri

  • Nov 02, 2016 at 08:52 AM

    Hello Gayathri,

    Did you also do all steps in the UIs like setting the "RBAM Context" and so on?

    Normally you wold not need to do any ABSL coding.

    Bye,
    Horst

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 03, 2016 at 09:12 AM

    Hi,

    If you are using ODATA for data migration, this should also trigger the BeforeSave event, because the ODATA service is built on BO.
    MDRO reference:

    https://blogs.sap.com/2014/04/03/how-to-create-an-hourly-mass-data-run-in-c4c/

    Thanks, Pradeep.
    Add comment
    10|10000 characters needed characters exceeded

    • Thanks Pradeep,

      Point 1) I checked Account has not got any access context set. So that's the problem. But now I have to programmatically check the territory as list i think so.

      Point 2) I moved the piece of code that determines the UUID to the Before Save event and tried to import data. It works fine

      Thanks

      Gayathri