Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
en:entwickler:plugin_manager [2025/08/21 18:14] – mightymcoder | en:entwickler:plugin_manager [2025/08/21 18:22] (current) – [Make your plugin compatible with the Plugin Manager (Admidio 5)] mightymcoder | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ======== Plugin Manager ======== | + | ========= Plugin Manager |
{{ : | {{ : | ||
The Plugin Manager module provides a simple user interface and standardized procedures for | The Plugin Manager module provides a simple user interface and standardized procedures for | ||
Line 9: | Line 9: | ||
plugins in Admidio. | plugins in Admidio. | ||
- | ======= Make your plugin compatible with the Plugin Manager (Admidio 5) ======= | + | ======== Make your plugin compatible with the Plugin Manager (Admidio 5) ======== |
To make your plugin compatible with the Plugin Manager certain requirements must first be met. These include: | To make your plugin compatible with the Plugin Manager certain requirements must first be met. These include: | ||
* [[en: | * [[en: | ||
* A consistent [[en: | * A consistent [[en: | ||
* Use of the new plugin namespace //Plugins// | * Use of the new plugin namespace //Plugins// | ||
- | * A [[en: | + | * A [[en: |
* A [[en: | * A [[en: | ||
* A JSON [[en: | * A JSON [[en: | ||
- | ====== Naming conventions ====== | + | ======= Naming conventions |
To use the new plugin namespace //Plugins// some naming conventions must be observed: | To use the new plugin namespace //Plugins// some naming conventions must be observed: | ||
- No plugin folder or file may contain delimiters such as //" | - No plugin folder or file may contain delimiters such as //" | ||
- For better readability file and folder names containing multiple words should follow CamelCase notation. | - For better readability file and folder names containing multiple words should follow CamelCase notation. | ||
- | ====== Folder structure ====== | + | ======= Folder structure |
The basic folder structure of any plugin is shown below using the " | The basic folder structure of any plugin is shown below using the " | ||
{{: | {{: | ||
- | ===== classes folder ===== | + | ====== classes folder |
- | ==== Presenter classes ==== | + | ===== Presenter classes |
- | === Plugin-specific classes === | + | ==== Plugin-specific classes |
Inside the // | Inside the // | ||
- | === Plugin preferences class === | + | ==== Plugin preferences class ==== |
+ | === Single FormPresenter element | ||
If the plugin provides preferences there should be a class //" | If the plugin provides preferences there should be a class //" | ||
Line 93: | Line 94: | ||
- | === Plugin preferences class with multiple form presenter | + | === Multiple FormPresenter elements |
With Admidio 5 the preference page has been redesigned. It is now possible to display multiple " | With Admidio 5 the preference page has been redesigned. It is now possible to display multiple " | ||
Line 238: | Line 239: | ||
This makes it possible to show seperate forms on the same page. There are no limits to the display options whether as cards (as in the example), tabs, or accordions. With this approach each available Bootstrap/ | This makes it possible to show seperate forms on the same page. There are no limits to the display options whether as cards (as in the example), tabs, or accordions. With this approach each available Bootstrap/ | ||
- | ==== Entity, Service and ValueObjects classes ==== | + | ===== Entity, Service and ValueObjects classes |
If the plugin has specific //Entity//, // | If the plugin has specific //Entity//, // | ||
- | ==== Main plugin class ==== | + | ===== Main plugin class ===== |
The main [[en: | The main [[en: | ||
- | ===== db_scripts folder ===== | + | ====== db_scripts folder |
This folder is optional and is used to place plugin-specific database scripts used when installing (// | This folder is optional and is used to place plugin-specific database scripts used when installing (// | ||
Line 279: | Line 280: | ||
</ | </ | ||
- | ===== languages folder ===== | + | ====== languages folder |
This folder contains the plugin-specific translation files. | This folder contains the plugin-specific translation files. | ||
- | ===== templates folder ===== | + | ====== templates folder |
To move away from the deprecated // | To move away from the deprecated // | ||
- | ===== Root plugin folder ===== | + | ====== Root plugin folder |
| | ||
| | ||
- | ==== Main plugin file ==== | + | ===== Main plugin file ===== |
Inside the root plugin folder a main plugin file is required. This file can contain plugin-specific logic (similar to Admidio’s module entry files) or simply initialize the [[en: | Inside the root plugin folder a main plugin file is required. This file can contain plugin-specific logic (similar to Admidio’s module entry files) or simply initialize the [[en: | ||
<code php> | <code php> | ||
Line 317: | Line 318: | ||
</ | </ | ||
- | ==== Plugin configuration file ==== | + | ===== Plugin configuration file ===== |
Each plugin must provide a JSON configuration file containing basic plugin information and configuration (see: [[en: | Each plugin must provide a JSON configuration file containing basic plugin information and configuration (see: [[en: | ||
- | ====== Configuration file ====== | + | ======= Configuration file ======= |
Each plugin has to provide a JSON configuration file. The following table gives an overview of all keys currently available: | Each plugin has to provide a JSON configuration file. The following table gives an overview of all keys currently available: | ||
Line 435: | Line 436: | ||
</ | </ | ||
- | ====== Plugin class ====== | + | ======= Plugin class ======= |
The //Plugin// class extends the basic functionality provided by the abstract class // | The //Plugin// class extends the basic functionality provided by the abstract class // | ||
Line 473: | Line 474: | ||
</ | </ | ||
- | ======= PluginAbstract class ======= | + | ======== PluginAbstract class ======== |
<WRAP center round todo 60%> | <WRAP center round todo 60%> | ||
methods documentation | methods documentation | ||
</ | </ |