Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagexml
titleExample of view for RoleType
		<presentation>
			...
			<view>
                <column>
                    <name>nameColumn</name>
                    <c:path>name</c:path>
                    <display>
                        <label>Name</label>
                    </display>
                </column>
                <column>
                    <name>members</name>
                    <display>
                        <label>Members</label>
                    </display>
                    <previousColumn>nameColumn</previousColumn>
					<export>
                    	<expression>
                        	<script>
                            	<code>
                                	import com.evolveum.midpoint.prism.query.*
                                	import com.evolveum.midpoint.xml.ns._public.common.common_3.*
                                                                
                                	query = prismContext.queryFor(UserType.class).item(AssignmentHolderType.F_ROLE_MEMBERSHIP_REF).ref(object.getOid()).build();
                                
                                	objects = midpoint.searchObjects(UserType.class, query)
                                	return objects.size();
                          		</code>
                        	</script>
                    	</expression>
					</export>
                </column>
            </view>
		</presentation>

...