Script for visibility by many lanes

410 views
Skip to first unread message

yves.d...@gmail.com

unread,
Dec 15, 2015, 12:57:32 PM12/15/15
to Fujitsu RunMyProcess Developer Community
Hello,

What are the scripts to :
1. in a menu bar make one menu visible only by users belonging to lane 1234 plus users belonging to lane 5678
"visible": "???"

2. in the Home page, make one icone visible only by users belonging to lane 1234 plus users belonging to lane 5678
class="displayme_$ ????">

Regards
Yves

Sweta Suman

unread,
Dec 19, 2015, 12:31:37 PM12/19/15
to suppor...@runmyprocess.com
Hi,

Query 1 : To make menu items visible to multiple users you can use script as -

{
"title" : "Home",
"visible" : "${has_right('12345') == 'true' || ${has_right('88877') == 'true'}"}
}


Query 2 :  In homepage you can use script as displayme_${has_right('12345')&&has_right('1234')&&has_right('5678')}

For more details refer below tutorial -





Hope this helps you.

Yves

--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at https://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/56e5e4a2-23ba-4fce-bc81-ffad609d611e%40runmyprocess.com.
For more options, visit https://groups.google.com/a/runmyprocess.com/d/optout.



--
Thanks,
Sweta 
Fujitsu RunMyProcess

yves.d...@gmail.com

unread,
Dec 21, 2015, 3:37:33 PM12/21/15
to Fujitsu RunMyProcess Developer Community, yves.d...@gmail.com
Hello Sweta,

It doesn't work.
Using <li class=" displayme_${has_right('238694')&& has_right('238593')}"> gives the following error :
'Expecting a boolean (true/false) expression hereExpression {has_right('238694' does not evaluate to true/false it is an instance of freemarker.template.SimpleScalar
Bad Request'
<li class=" displayme_${has_right('238694')}"> alone or <li class=" displayme_${has_right('238593')}"> alone works but not both together


> Regards
> Yves

Pankaj Kumar

unread,
Dec 22, 2015, 5:11:46 AM12/22/15
to Fujitsu RunMyProcess Developer Community
Hi,

From the error log, it seems you using the "has_right" function in a Web Interface as a java script. Please refer to below link for detials of the method.


Thank you,
Pankaj Kumar
Fujitsu RunMyProcess Support



> Regards
> Yves

--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "Fujitsu RunMyProcess Developer Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at https://groups.google.com/a/runmyprocess.com/group/supportforum/.

yves.d...@gmail.com

unread,
Dec 22, 2015, 10:48:36 AM12/22/15
to Fujitsu RunMyProcess Developer Community
Hello Pankaj,

<li class=" displayme_${has_right('238694')&& has_right('238593')}"> is used in a HTML widget in the webinterface which displays the apps icons in our custom HomePage.

I don't mind the method : has_right or another one.
My question is : 'in the Home page, how to make one icone visible only by users belonging to lane 1234 plus users belonging to lane 5678 ?'


Regards
Yves

rode...@roderickforsythe.com

unread,
Dec 22, 2015, 11:04:13 AM12/22/15
to Fujitsu RunMyProcess Developer Community, yves.d...@gmail.com

I'm not sure if this would work, but you might try this:
<li class=" displayme_${(has_right('238694')&& has_right('238593'))?eval}">

http://freemarker.incubator.apache.org/docs/ref_builtins_expert.html#ref_builtin_eval

yves.d...@gmail.com

unread,
Dec 22, 2015, 11:25:33 AM12/22/15
to Fujitsu RunMyProcess Developer Community
Le mardi 15 décembre 2015 18:57:32 UTC+1, yves.d...@etrali.com a écrit :
> Hello,
>
Thanks Roderick for your help, appreciate.
Unfortunately, it doesn't work and the following error message pop-up :
'Expecting a boolean (true/false) expression hereExpression (has_right('238694' does not evaluate to true/false it is an instance of freemarker.template.SimpleScalar
Bad Request'
>
> Regards
> Yves

yves.d...@gmail.com

unread,
Dec 23, 2015, 6:31:18 AM12/23/15
to Fujitsu RunMyProcess Developer Community, yves.d...@gmail.com
Hello,

Looks like I have the solution for the 2nd query.
Following script used in a HTML widget in the webinterface which displays the apps icons in our custom HomePage works fine :
<div class="home_app">
<ul>
<li class="displayme_${has_right('123456')=='true' || has_right('456789')=='true'}">

All users belonging to lane 123456 plus all users belonging to lane 456789 can see the icon.

> Regards
> Yves

Reply all
Reply to author
Forward
0 new messages