[midPoint] Condition for role assignement

Oleksandr Nekriach o.nekriach at dynatech.lv
Mon Jan 8 08:40:12 CET 2018


Sorry thi one is correct
&

On 8 January 2018 at 09:38, Oleksandr Nekriach <o.nekriach at dynatech.lv> wrote:
> Hello Jan,
> You should use $amp; instead of & character
>
> Best regards, Oleksandr
>
> On 7 January 2018 at 15:31, Jan Kaspar <Caspi at seznam.cz> wrote:
>> Hi,
>>
>> I am trying to create condition for Org assignement. Basicaly user type have
>> to be a Contractor and must be enabled.
>> Problem with this cone is an AND operator (&&). with this i cannot save the
>> code. I am missing point. In other mappings i am using OR and it works.
>>
>> See code bellow:
>>
>>  <mapping id="8">
>>       <name>My Object Template: test assign orgs</name>
>>       <authoritative>false</authoritative>
>>       <strength>strong</strength>
>>       <source>
>>          <c:path>employeeType</c:path>
>>       </source>
>>       <source>
>>          <c:path>activation/effectiveStatus</c:path>
>>       </source>
>>       <expression>
>>          <value>
>>             <targetRef oid="bc5ee415-e570-44b3-a676-daee0aa7ab0e"
>> type="OrgType"/>
>>          </value>
>>       </expression>
>>       <target>
>>          <c:path>assignment</c:path>
>>       </target>
>>       <condition>
>>          <script xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>                  xsi:type="c:ScriptExpressionEvaluatorType">
>>             <code>
>>                 def tmpStatus =
>> basic.norm(basic.stringify(effectiveStatus))?.toString();
>>                 log.info ("ORGANIZATION ASSIGNEMENT User Status = " +
>> tmpStatus);
>>         tmpStatus == 'enabled' && employeeType == 'Contractor'
>>             </code>
>>          </script>
>>       </condition>
>>    </mapping>
>>
>> Thanks for Help
>>
>> Jan
>>
>> _______________________________________________
>> midPoint mailing list
>> midPoint at lists.evolveum.com
>> http://lists.evolveum.com/mailman/listinfo/midpoint
>>
>
>
>
> --
> Best regards,
>
> Oleksandr Nekriach | Identity and access management engineer
>
> Dynatech, Mednieku str. 4a, Riga, LV-1010, Latvia
>
> +37125314685
> ,
> o.nekriach at dynatech.lv
> |
> www.dynatech.lv
>
>
>
>
> Stay connected:
>
>
> Confidentiality Notice: This message contains confidential information
> and is intended only for the named recipient(s). If you are not the
> addressee you may not copy, distribute or perform any other activities
> with this information. If you have received this transmission in
> error, please notify us by e-mail immediately. E-mail transmission
> cannot be guaranteed to be secure or error-free as information could
> be intercepted, corrupted, lost, destroyed, arrive late or incomplete,
> or contain viruses.



-- 
Best regards,

Oleksandr Nekriach | Identity and access management engineer

Dynatech, Mednieku str. 4a, Riga, LV-1010, Latvia

+37125314685
,
o.nekriach at dynatech.lv
|
www.dynatech.lv




Stay connected:


Confidentiality Notice: This message contains confidential information
and is intended only for the named recipient(s). If you are not the
addressee you may not copy, distribute or perform any other activities
with this information. If you have received this transmission in
error, please notify us by e-mail immediately. E-mail transmission
cannot be guaranteed to be secure or error-free as information could
be intercepted, corrupted, lost, destroyed, arrive late or incomplete,
or contain viruses.



More information about the midPoint mailing list