Custom database contributor groups

As part of the CMS Ametys integration process, it is necessary to define how contributor groups will be managed.

CMS Ametys offers a number of predefined group managers. However, you can also define your own group manager to use an existing group database in your information system.

The handler that can be used in this case is the database handler:

Database connection

If the database is not the default database on CMS, you must first define a new connection pool to this database or"data source".

Go to SQL (data source) and follow the procedure to create a new connection pool.

Declaration of a new user group database

The new user group manager is declared in the plugin.xml file of a plugin.

You may need to create a new plugin; to do this, follow the instructions on the Architecture page. plugin Ametys

Example of a group base declaration

<extension point=""
    	<table>Groups</table> 	<!-- Nom de la table SQL portant les groupes -->
        <id>Id</id>				<!-- Nom de la colonne contenant l'identifiant du groupe -->
        <label>Label</label>    <!-- Nom de la colonne contenant le libellé du groupe -->
    	<table>Groups_Users</table> <!-- Nom de la table SQL reliant un groupe aux utilisateurs -->
        <group>Group_Id</group>		<!-- Nom de la colonne contenant l'identifiant du groupe -->
        <user>Login</user>			<!-- Nom de la colonne contenant l'identifiant de l'utilisateur -->

It is your responsibility to modify and maintain the script SQL corresponding to your group table.


You can then select this new extension point using either the "Plugins and Workspaces"This can be done via the administration interface, or by directly modifying the WEB-INF/param/runtime.xml (see Runtime file.xml) .

Extract from the runtime file.xml








Back to top