Overloading of virtual pages in the organization chart and directory


This feature is available from version 2.12.

  1. Organization chart
    1. Description
    2. Overloads
  2. Directory
    1. Description
    2. Overloads
  3. Example

Organization chart

Description

In the flowchart, there is a type of virtual page.

Overloads

Description

Overload file name

Default configuration file 

Organization tree pages of any level

userdirectory.orgunit.xml

<model template="udorgunit">
    <zone id="default"> 
        <content view="main"/>
    </zone>
</model> 

Reminder: The overload file should therefore be named: userdirectory.orgunit.xml

Directory

Description

There are two types of virtual pages in the directory.

Overloads

Description

Overload file name

Default configuration file 

Intermediate pages in the directory tree

userdirectory.user-transitional.xml

<model template="page">
    <zone id="default"> 
      <service id="org.ametys.web.service.SitemapService">
            <depth i18n="false">1</depth>
            <all i18n="false">false</all>
            <includeInvisiblePage i18n="false">true</includeInvisiblePage>
        </service>
    </zone>
</model>

Last pages of the directory tree

userdirectory.user.xml

<model template="user-page">
    <zone id="default">
        <content view="main"/>
    </zone>
</model>

If this file redefines the content view, it will be ignored: the view defined when configuring the directory root will prevail. 

Reminder: Overload files should therefore be named: userdirectory.user-transitional.xml for intermediate pages in the tree structure and userdirectory.user.xml for pages containing users.

Example

Configuration file overload for virtual pages in the directory tree (userdirectory.orgunit.xml), or last-level virtual pages in the directory tree (userdirectory.user.xml)

<model template="page">
    <zone id="default">
<service id="org.ametys.web.service.SitemapService">
            <depth i18n="false">1</depth>
            <all i18n="false">false</all>
            <includeInvisiblePage i18n="false">true</includeInvisiblePage>
        </service>
        <content view="main"/>
    </zone>
</model>
  • Change template to "page
  • Addition of the "default" zone
    • Add a service to the zone
    • Placing content (the user) after the service
Back to top

User directory