• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..Today-

conf/H28-Sep-2020-2514

images/H28-Sep-2020-

lang/H28-Sep-2020-9970

redmine/H28-Sep-2020-11697

README.mdH A D05-Jul-20185.9 KiB14194

action.phpH A D05-Jul-20181.7 KiB5940

plugin.info.txtH A D05-Jul-2018140 86

server.jsonH A D05-Jul-2018241 1110

style.cssH A D05-Jul-20182.1 KiB136118

syntax.phpH A D05-Jul-201815.8 KiB345295

README.md

1# Plugin Redissue
2
3Plugin Dokuwiki display issues of Redmine and keep the rights of Redmine too. Redissue have the following features:
4
5* Name of issue
6* Number, percentage, author of issue
7* Make a link to the choosen issue in Redmine and the related project.
8* Display more or less information depending on your rights.
9* Compatible with [Bootstrap](http://getbootstrap.com/) (like with [Dokuwiki Temaplte Bootstrap3](https://github.com/LotarProject/dokuwiki-template-bootstrap3/)).
10
11## Requirements
12
13Redissue needs [Php-Redmine-API](https://github.com/kbsali/php-redmine-api) to work. Download it inside the ROOT of your redissue's folder or inside ``/usr/share/php`` folder. The last place is better if you use [Redproject](https://www.dokuwiki.org/plugin:redissue) too, as you've just to install API once time.
14
15In any case, Php-Redmine-API must be located inside a `vendor` folder !
16
17```bash
18mkdir vendor
19cd vendor
20git clone https://github.com/kbsali/php-redmine-api.git
21cd php-redmine-api
22# Go to last version. Use "git describe --abbrev=0" to see last tag.
23git checkout v1.5.x
24```
25
26Don't forget to install the **requirements** of PhP-Redmine-API :
27
28```bash
29sudo apt-get install php5-curl php5-common
30```
31
32## Install
33
34Download Redissue plugin into your ``${dokuwiki_root}/lib/plugins`` folder and restart dokuwiki.
35
36## Configuration
37
38You can configure Redissue in the Config Manager of DokuWiki:
39
40* redissue.url: Put your Redmine's url server, without a slash ending. Example : ``http://myredmine.com``. This setting can be override by _server_ option.
41* redissue.img: Maybe you have a custom icon for your Redmine installation. You can put image'url here. Example : ``http://www.example.com/image.png``
42* redissue.theme: If you have the theme [Bootstrap 3](https://www.dokuwiki.org/template:bootstrap3) installed (or another supported _Bootstrap_ theme), you can set redissue to bootstrap. Otherwise, simply choose theme Dokuwiki.
43* redissue.API: Set your Redmine API's key, preference Administrator key. This setting can be override by _server_ option.
44* redissue.view: Choose the view you want to display. This will depend on the wiki user's access rights in Redmine.
45  * Impersonate: select this if your wiki's users have the same UID as Redmine's users. e.g. : LDAP authentication. Redissue then will manage rights based on private or public projects.
46  * Userview: doesn't manage access rights and display issue even if it's in private project.
47
48Some advanced settings are also available below.
49
50## Syntax
51
52### Single issue syntax:
53
54```php
55<redissue id="#number_issue" text="text_if_no_rights_or_API" />
56```
57
58* id: id of the wanted issue.
59* text: displays a text other than the default if the user does not have the rights or the issue does not exist
60
61### Multiple issue syntax
62
63If you want to get all issues of a specific project and/or a specific tracker, it's also possible. You've **2** other options:
64
65* project: the **right** identifier of the project (Available in the settings of redmine project): project="myproject"
66* tracker: the identifier number of your tracker. (You can found this number if you look at the number in the link of a tracker): tracker="3"
67
68In this case, the twice parameter **must be set** but one can be empty. E.g: if you want to have all issues of a project for all trackers, you can leave tracker empty
69
70* limit: set the limit of issues displayed. Default is 25.
71
72**Examples:**
73
74```php
75// Display the first 25 issues with tracker 1 for project "myproject"
76<redissue project="myproject" tracker="1" />
77// Display the first 25 issues for project "myproject"
78<redissue project="myproject" tracker="" />
79// Display the first 50 issues with tracker 4 for all projects (if you have rights)
80<redissue project="" tracker="4" limit="50" />
81```
82
83You can also sort the issues according to your interests.
84
85* sort: choose how issues will be displayed. by default they are displayed by **id** number, from the most recent to the oldest (descending).
86
87You can choose to sort by : id, subject, project, tracker, ...
88
89**Examples:**
90
91```php
92// Sort issue by ascending "id", for project "myproject" and tracker "1"
93<redissue project="myproject" tracker="1" sort="id" />
94// Sort issue by "subject" for project "myproject" and all trackers
95<redissue project="myproject" tracker="" sort="subject"/>
96```
97
98### Manage Multiple Servers
99
100* server: In case you have multiple server, you can override the server url and the API key defined in the Redissue **settings**. You must define these in a json file called `server.json` (already available in plugin folder). This file must be at root of redissue folder.
101
102Example of _server.json_ file:
103
104```json
105{
106    "first": {
107        "url": "http://myfirst.redmine.com",
108        "api_token": "abcdefghijklmnopqrstuvwxyz0123456789"
109    },
110    "second": {
111        "url": "http://mysecond.redmine.com",
112        "api_token": "zyxwvutsrqponmlkjihgfedcba9876543210"
113    }
114}
115```
116
117Then simply add your server with: `server="first"` in redissue syntax.
118
119**Note:** If server url or key in json file is wrong or if you put a wrong name in "server" parameter(e.g: call _flirt_ instead _first_), redissue take the one who is set in dokuwiki settings. If **url** or **api_token** are wrong everywhere, an error message will be displayed instead of redissue.
120
121### Other options
122
123* title: you can override issue title if it's too long or for other reasons with: `title="my new title"`.
124* short: (**dokuwiki theme only**, bootstrap not needed this functionnality). If you've dokuwiki theme, you can hide additional information with short: `short="1"`.
125
126Then, Redissue will display all the issue of this tracker for this specific project. If "project" or "tracker" identifiers are bad, Redissue display only issue with Id you have defined in "id" option.
127
128## Preview
129
130Here is a preview of redissue:
131
132* Dokuwiki theme
133
134![Dokuwiki Theme](images/redissue_dokuwiki.png)
135
136* With a bootstrap Theme
137
138![Bootstrap Theme](images/redissue_bootstrap.png)
139
140For further information, see also [Redissue on dokuwiki.org](https://www.dokuwiki.org/plugin:redissue)
141