feat(xo-server/rest-api): add groups collection
See https://xcp-ng.org/forum/post/70500
This commit is contained in:
parent
a6e93c895c
commit
bcdcfbf20b
@ -7,6 +7,8 @@
|
||||
|
||||
> Users must be able to say: “Nice enhancement, I'm eager to test it”
|
||||
|
||||
- [REST API] Add `/groups` collection [Forum#70500](https://xcp-ng.org/forum/post/70500)
|
||||
|
||||
### Bug fixes
|
||||
|
||||
> Users must be able to say: “I had this issue, happy to know it's fixed”
|
||||
@ -31,7 +33,7 @@
|
||||
|
||||
<!--packages-start-->
|
||||
|
||||
- xo-server patch
|
||||
- xo-server minor
|
||||
- xo-server-load-balancer patch
|
||||
- xo-web patch
|
||||
|
||||
|
@ -319,6 +319,14 @@ export default class RestApi {
|
||||
}
|
||||
|
||||
collections.backup = {}
|
||||
collections.groups = {
|
||||
getObject(id) {
|
||||
return app.getGroup(id)
|
||||
},
|
||||
async getObjects(filter, limit) {
|
||||
return handleArray(await app.getAllGroups(), filter, limit)
|
||||
},
|
||||
}
|
||||
collections.restore = {}
|
||||
collections.tasks = {}
|
||||
collections.users = {
|
||||
|
Loading…
Reference in New Issue
Block a user