-
Notifications
You must be signed in to change notification settings - Fork 41
Closed
Labels
priority:high 🚑High priority issueHigh priority issuetype:enhancement 😃New feature or requestNew feature or request
Milestone
Description
Description
Add a button to "create a new <document type>
" where <document type>
is the current document type being viewed (e.g., "Article").
Requirements
-
Button Text:
- The button should display text like "Add new Article". The exact text is available in the document type object
titleSingular
field.
- The button should display text like "Add new Article". The exact text is available in the document type object
-
Create New Document:
- Clicking the button should create a new empty document in the
documents
collection. - All fields should be set, and the
data
field should be set to an empty object{}
.
- Clicking the button should create a new empty document in the
-
Navigation:
- After creating the new document, navigate to the "edit document" page for that document.
Steps
-
Add the Button:
- Place the button prominently on the current document type page.
-
Button Functionality:
- Implement the button click functionality to:
- Create a new document in the
tanam-documents
collection. - Set all fields appropriately, with
data
being an empty object{}
. - Navigate to the "edit document" page for the newly created document.
- Create a new document in the
- Implement the button click functionality to:
Example
In this example, the button should say "Add new Article". Upon clicking the button:
- A new document is created in the
tanam-documents
collection. - The user is redirected to the edit page for the new document.
Acceptance Criteria
- The button is visible and appropriately labeled based on the current document type.
- Clicking the button successfully creates a new document in the
tanam-documents
collection. - The user is redirected to the "edit document" page for the newly created document.
Screenshot
Related Issues
Metadata
Metadata
Assignees
Labels
priority:high 🚑High priority issueHigh priority issuetype:enhancement 😃New feature or requestNew feature or request
Type
Projects
Status
Done