Context substitution variable in workflow/BPA | IFS Community
Question

Context substitution variable in workflow/BPA

  • 14 July 2022
  • 5 replies
  • 84 views

Badge +1

Hello,

I am trying to update a custom field on a custom page on IFS Cloud using workflow/BPA.

The value needs to be set to the current user Id.

Is there a way to get the current user Id by using a context substitute variable(#USER_ID#) in the value field?

I am using  - IFS Aurena client version: 21.2.1.20211105061905.0

Thanks in advance,

Asheer.


5 replies

Badge +1

Hi Asheer,

I had a same requirement to get the current logged in User-Id for a validation. I was able to read user id using a IFS Projection like below. Variable “Identity” returns the current User-Id.

 

Hope this will help you 😊

Cheers!
Chamari

Badge +1

Hi @ChamariJ , 
Thank you for your response. 
However, I am unable to use the variable Identity returned by the read IFS Projection. 
The following error is generated.


You will find below my workflow design.

Is there a way to use the variable in the value field? 
Also, how did you know that the projection to use is Usersetting and the entity set name should be SingletonUser? Is there any Documentation to know where to get these values? 
Do you know if any supporting document/training is available concerning BPA Workflows? 
I have already covered the training session available on IFS Academy. However, it just gives a basic idea about workflows.
Thanks in advance,
Asheer.

Badge +1

Hi Asheer,

Unfortunately I don’t have any idea about your E-Tag error 😥. Did you try to remove it and see? and please try to update with key in Customer LU.


Regarding the UserSettingProjection, I just searched for a projection call which returns the current logged in user and I found SingletonUser is having a where function to retrieve what I want.
 

I also followed the training sessions but could not find any ifs-technical documentation for this. I am using ifs cloud 21R2 and there are some interface changes rather than Aurena in BPA.

Thanks!
Chamari

Userlevel 6
Badge +14

Some documentation can be found here:

 

Userlevel 6
Badge +14

Less technical documentation is found here:

 

Reply