Advanced Techniques - Display Intrexx Share profile pictures in applications
Every user can add a picture to their profile in Intrexx Share. This workshop
demonstrates how these profile pictures can also be used in other applications -
e.g. the profile picture of the current user or of the user who last edited a
data record. Background knowledge application development are of an advantage
2. Display the profile picture of the current user
Before the profile pictures can
be shown in applications, two conditions need to be checked:
Create a grouping for displaying the
profile picture and define that it should only bedisplayed if a condition is met.
Two if conditions are used here to check whether the portal has Intrexx Share.
If yes, it then checks whether the current user has an Intrexx Share.
Copy the following Velocity script and replace the name of the "simplegroup" with
the corresponding name of the grouping in your application:
The file "makro.vmi" can be created directly in the Velocity file manager.
The file "script.vmi", which we created in the previous step, is still defined in the
"Refer to a file in the application package" option.
Afterwards, the application can be published and tested.
3. Display the profile picture of last editor
To display the profile picture of the user who last edited the data record,
add a button column
to the respective table. Edit the column and remove the predefined image.
Go to the Options section of the General tab
in the button properties and activate the setting "Display if condition met".
Insert the following script beneath the first line:
In this case as well, the code begins by checking whether the portal has Intrexx
Share. Afterwards, the user ID of the user who last edited the record is
used to identify and display their Intrexx Share profile picture. Instead
of the profile picture of the last editor, you can also display the
profile picture of the data record creator/owner. Modify the script above
at line 5 as follows: