Today I have released version 1.2.3 of Blossom and Blossom Data Extension 1.0, an extension for using Blossom style dialogs with the Magnolia Data Module. It introduces a new annotation @DataTypeDialogFactory which is used for creating dialogs for data module types. It has the same feature set as @DialogFactory and is used in the same way.
In this release the feature set TabBuilder is expanded adding support for the multi select control, the include control and for adding any control by type. It's now also possible to get the dialog and the DialogCreationContext from the TabBuilder.
This is an example of how a dialog used for the type 'category':
To use the Data Extension you need to add it to your pom.xml
Add this line to your blossom-servlet.xml or equivalent.
And if you're using classpath scanning you'll also want to add an include-filter for the new annotation.
For more details see the Blossom Data Extension wiki page.
In this release the feature set TabBuilder is expanded adding support for the multi select control, the include control and for adding any control by type. It's now also possible to get the dialog and the DialogCreationContext from the TabBuilder.
This is an example of how a dialog used for the type 'category':
@DataTypeDialogFactory("category") public class CategoryDialog { @TabFactory("Settings") public void settingsTab(TabBuilder tab) { tab.addEdit("name", "Name", ""); tab.addEdit("maxResults", "Max results", ""); } }
To use the Data Extension you need to add it to your pom.xml
<dependency> <groupId>info.magnolia</groupId> <artifactId>magnolia-module-blossom-extension-data</artifactId> <version>1.0</version> </dependency>
Add this line to your blossom-servlet.xml or equivalent.
<bean class="info.magnolia.module.blossom.extension.data.DataDialogExporter" />
And if you're using classpath scanning you'll also want to add an include-filter for the new annotation.
<context:component-scan base-package="package-containing-dialogs" use-default-filters="false"> ... <context:include-filter type="annotation" expression="info.magnolia.module.blossom.extension.data.DataTypeDialogFactory"/> </context:component-scan>
For more details see the Blossom Data Extension wiki page.