CUL-DigitalServices/avocet-hilary — pull request #8 by Coenego (2014-03-19 13:51:00+00:00)
Title: Added departments module

### Importing departments
Importing departments is only enabled for global- and tenant admins. To import a set of departments, a `POST` request needs to be sent to `/api/departments/import`.
```
'data': {
'departments': file.csv
}
```

The `.CSV`-file must be constructed in a way where the first 'column' contains the ID of the department. The second 'column' contains the department name ("Department of Zoology").

### Searching for departments
Since we want to use the departments for an autosuggest feature in the front-end, we registered a search endpoint. Searching for departments can be done using the `/api/search/departments` endpoint. The endpoint accepts the 'q', 'limit', 'start' and 'sort' parameters (e.g. /api/search/departments?q=asian&limit=10).