DBListManager Application

Last modified by Andreea Popescu on 2021/03/17 21:44

application_formHelper to manage Database List values (used like a Static list) of a class
TypeXAR
Category
Developed by

Guillaume Delhumeau

Rating
0 Votes
Websitehttp://xwiki.kephpage.net
LicenseGNU Lesser General Public License 2.1

Installable with the Extension Manager

Description

This application is a helper for simple users that allows them to design the fields of a DataBase List, which is used as a Static List that users can easily edit, without needing editing rights on the class.

If you need an internationalized version of this extension, see MultiLingualDBListManager Application. It supports translated values.

Usage

Just write:

{{dblist_manager property='..' wikiclass='..' showQuery='true|false' documentHandler='..' showTitle='true|false' /}}

Where :

  • "property" is the property of the class to manage (must be a Database List!).
  • "wikiclass" is the class which contains the property.
  • "showQuery" (optional) is for the class designer: display or not the query to put on the "Hibernate Query" field of the property. (default: false)
  • "documentHandler" (optional) is the document where the Database list entries will be saved. Default: the current document where is used this macro.
  • "showTitle" (optional) shows or not the title. (default: true)

Then, in your class, you can create a 'Database List' property and fill in the 'Hibernate Query' the content that you can display with showQuery parameter of the macro.

Example of use

  1. In your class, add a Database List field
    Screen1.png
  2. In the page where you want the user can customise it, call the macro:
    Screen2.png
    (or)
    Screen3.png
  3. Get the Hibernate Query
    Screen4.png
  4. Put it on the "Hibernate Query" field of your property in your class:
    Screen5.png
  5. Add some values using the macro
    Screen6.png
  6. Enjoy the results, when you create an object of your class:
    Screen7.png

Maven

Developers, if you want to add this application as a dependency of your own XAR, just add the following lines in your pom.xml file:

  <dependencies>
   <dependency>
     <groupId>org.xwiki.contrib</groupId>
     <artifactId>xwiki-dblistmanager-application</artifactId>
     <version>1.0</version>
     <type>xar</type>
   </dependency>
 </dependencies>

Prerequisites & Installation Instructions

We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.

You can also use the following manual method, which is useful if this extension cannot be installed with the Extension Manager or if you're using an old version of XWiki that doesn't have the Extension Manager:

  1. Log in the wiki with a user having Administration rights
  2. Go to the Administration page and select the Import category
  3. Follow the on-screen instructions to upload the downloaded XAR
  4. Click on the uploaded XAR and follow the instructions
  5. You'll also need to install all dependent Extensions that are not already installed in your wiki

Don't forget to add Macros.DBListManagerTranslations to your translation files.

Release Notes

v1.0

First release!

Tags:
    

Get Connected