AWM Page Creation
Description
In AppWithinMinutes we want to simplify page creation. We don't want users to have to give the title of a page before they start editing the content of the page. This should happen automatically based on a rule that is set for this creation.
Add the "create" action
- The create action would be protected by the "create" right in the Space in which it is called
- The create action would be called on the home page of a space
- The create action would support an additional parameter called "namingrule"
In general the create would behave like the save but with the differences listed before. Preview should still be supported.
Save and Continue/Save should be replaced by "Create".
Naming Rules
The following naming rules should be available:
| Rule name | Rule |
|---|---|
| title | Use the title field. |
| titleclean | Use the title field and add optional cleaning of fields. The cleaning rule can be additional parameters. |
| field | Use the title field. |
| fieldclean | Use the title field and add optional cleaning of fields. The cleaning rule can be additional parameters. |
| prefix | Use a provided prefix. The clean rule can be additional parameters. |
| custom | Use a groovy script provided to generate the page name. |
The "namingcounter" parameter would add automatically and additional counter. The counter could be handled automatically in a counter queue or use a value in the page.
The following types of counter are possible
- none (in this case the creation fails if the page already exists)
- page name counter (extract the counter from the page name)
- field value counter (extract the counter from a field)
- queue counter (extact the counter from a counter queue in the database)
- queue counter with uniqueness (extact the counter from a counter queue in the database without the possibility to reuse an existing number)
Adding a create view
The create view would allow to have a custom view and custom buttons during the creation process. This can be called directly from the "Add" button in XWiki.
The create view should use either parameters provided in the URL or the provided template to find the "create sheet" and the page naming parameters to use.
Validation
The "create" process should support the validation system in place for editing.
Ludovic Dubost