Content
View differences
Updated by Dominic Bräunlein 14 days ago
In OpenProject:
* There are two new entries Macros in the "+ Insert" dropdown of the work package toolbar
* "New wiki page" and "Existing "Add wiki page"
* When user clicks on "New wiki page" the _new wiki page_ dialog will appear:
* The user will be invited to enter a title for the provider first Wiki.
* Then They will also be able to select the title for the Wiki and the parent to which this Wiki will belong.
* The newly-created wiki page will appear in the work package description in-line, as well as in the Wiki tab under "Mentioned in description" since it is also automatically linked with the work package.
* The corresponding link will appear in-line. Clicking on this link will take the user to the newly-created page on XWiki.
* When user clicks on "Existing "Add wiki page" the _add wiki page_ dialog will appear:
* The user will be invited to enter the provider first
* The user will be invited to select a Wiki page.
* ~~All All available wiki pages are shown as tree view with meta information and a search~~
* A search is available to find the right page
* The user can also paste a URL of an existing wiki page
* The selected wiki page will appear in the work package description in-line, as well as in the Wiki tab under "Mentioned in description" since it is also automatically linked with the work package.
* The corresponding link will appear in-line. Clicking on this link will take the user to the selected page on XWiki.
### Implementation
* Prerequisites:
* See [document](https://community.openproject.org/documents/192) (assumed to be present) OpenProject's rich text editor has a generic slash-command UX pattern implemented, generically allowing "providers" to register commands (Currently not yet available. Implementation outside the scope of this here. Will be done by OpenProject independently)
* (assumed to be present) XWiki API for listing spaces
* (assumed to be present) XWiki API endpoints for listing pages, optionally filtering by space
* (Implementation needed in XWiki) XWiki API for pages that allow for creating a link to a OpenProject work package
* (Implementation needed in XWiki and OpenProject) Bi-directional OAuth setup on administrator level. Defined in ##55601.
* Editor macro "Create new wiki page"
* Effort:
* UI to guide the user to grant OpenProject access to XWiki via OAuth unless a valid access token is already present.
* Implement macro for **creating** wiki pages
* Modal window with a form for creating a wiki page
* Inputs
* Select target parent
* Text field for page title
* On form submit
* create page by sending a POST request to XWiki to create the page
* send POST request to XWiki to create the link between work package and freshly created wiki page
* Show optional link "Edit page in XWiki"
* On modal close
* send POST request to XWiki to create the link
* update the current work package "Wiki" tab to show new link
* Insert OpenProject rich text editor macro for showing a link to the wiki page.
### Visuals (Outdated)
<br>
**Macros to add existing or create new wiki page**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918453/content">
**Select wiki page dialog**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918454/content">
**Create new wiki page dialog**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918456/content">
**The link also appears in the Wikis tab in the right-hand split screen:**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918457/content">
###
* There are two new entries
* "New wiki page" and "Existing
* When user clicks on "New wiki page" the _new wiki page_ dialog will appear:
* The user will be invited to enter
* Then
* The newly-created wiki page will appear in the work package description in-line, as well as in the Wiki tab under "Mentioned in description"
*
* When user clicks on "Existing
* The user will be invited to enter the provider first
* The user will be invited to select a Wiki page.
* ~~All
* A search is available to find the right page
* The user can also paste a URL of an existing wiki page
* The selected wiki page will appear in the work package description in-line, as well as in the Wiki tab under "Mentioned in description"
*
### Implementation
* Prerequisites:
* See [document](https://community.openproject.org/documents/192)
* (assumed to be present) XWiki API
* (assumed to be present) XWiki
* (Implementation needed in
* (Implementation needed in XWiki
* Editor macro "Create new wiki page"
* Effort:
* Implement macro for **creating** wiki pages
* Modal window with a form for creating a wiki page
* Inputs
* Select target parent
* Text field for page title
* On form submit
* create page by sending a POST request to XWiki to create the page
* send POST request to XWiki to create the link between work package and freshly created wiki page
* Show optional link "Edit page in XWiki"
* On modal close
* send POST request to XWiki to create the link
* update the current work package "Wiki" tab to show new link
* Insert OpenProject rich text editor macro for showing a link to the wiki page.
### Visuals (Outdated)
**Macros to add existing or create new wiki page**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918453/content">
**Select wiki page dialog**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918454/content">
**Create new wiki page dialog**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918456/content">
**The link also appears in the Wikis tab in the right-hand split screen:**
<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/918457/content">