Person Archetype
|
Since 4.8
This functionality is available since version 4.8.
|
This document describes the built-in Person archetype in midPoint.
Introduction
The built-in Person archetype can be used for users imported from an authoritative source of data, such as HR.
We have created this archetype as a part of First Steps Methodology.
This archetype includes a reference to Person Object Template, which is also a midPoint initial object.
System configuration includes an object collection view for users with this archetype.
Configuration
Person archetype
The Person archetype references the Person Object Template, and it can be assigned to users.
Person object template
The template contains two mappings:
-
generate-name-jsmith-8-2: Mapping to generate the midPoint username from user’sgivenNameandfamilyNameproperties using thejsmithnaming convention. At most 8 characters are used. To achieve username uniqueness, an iteration token is appended (2-99).-
This mapping’s strength is weak; it will only be used to create usernames. Usernames will never be automatically changed if user’s
givenNameorfamilyNamechanges, however, it can be overridden manually by an administrator. -
This mapping has the lifecycle state set to
draftby default, i.e., it is effectively disabled by default. Change the lifecycle state toproposedto use the mapping in simulations, or toactiveto use the mapping.
-
-
generate-fullname: Mapping to generate the midPointfullNameproperty from user’sgivenNameandfamilyNameusing theJohn Smithnaming convention.-
this mapping’s strength is strong; it will always enforce the
fullName.
-
Feel free to add any additional mappings or change the existing ones; just remember that the object template is a midPoint built-in object that may be updated in future midPoint releases.
System configuration example
In the following configuration example, you can see how we:
-
display users with the
Personarchetype assigned using a menu item, -
add a custom search configuration.
objectCollectionView)<objectCollectionView id="80">
<description>Persons</description>
<documentation>This view displays all users with archetype "Person"</documentation>
<identifier>person-view</identifier>
<displayOrder>10</displayOrder>
<type>UserType</type>
<collection>
<collectionRef oid="00000000-0000-0000-0000-000000000702" relation="org:default" type="c:ArchetypeType">
<!-- Person -->
</collectionRef>
</collection>
<searchBoxConfiguration>
<searchItems>
<searchItem id="81">
<description>Allow searching for users having account on specific resource. Intent is not considered. The search item is not displayed by default
(visibleByDefault=false).
</description>
<visibleByDefault>true</visibleByDefault>
<filter>
<q:text>
linkRef/@ matches (
. type ShadowType
and resourceRef/@/name = `resourceParameter?.getName()?.getOrig()`
and kind = "account" )
</q:text>
</filter>
<display>
<label>Users with account</label>
</display>
<parameter>
<name>resourceParameter</name>
<type>c:ObjectReferenceType</type>
<targetType>ResourceType</targetType>
</parameter>
</searchItem>
<searchItem id="82">
<description>Allow searching for users not having account on specific resource. Intent is not considered. The search item is not displayed by default
(visibleByDefault=false).
</description>
<visibleByDefault>true</visibleByDefault>
<filter>
<q:text>
linkRef/@ not matches (
. type ShadowType
and resourceRef/@/name = `resourceParameter?.getName()?.getOrig()`
and kind = "account" )
</q:text>
</filter>
<display>
<label>Users without account</label>
</display>
<parameter>
<name>resourceParameter</name>
<type>c:ObjectReferenceType</type>
<targetType>ResourceType</targetType>
</parameter>
</searchItem>
</searchItems>
</searchBoxConfiguration>
</objectCollectionView>