feat(xen-api/getRecords): fetch multiple records
This commit is contained in:
parent
29b4cf414a
commit
04b31db41b
@ -552,6 +552,10 @@ export class Xapi extends EventEmitter {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getRecords(type, refs) {
|
||||||
|
return Promise.all(refs.map(ref => this.getRecord(type, ref)))
|
||||||
|
}
|
||||||
|
|
||||||
async getAllRecords(type) {
|
async getAllRecords(type) {
|
||||||
return map(
|
return map(
|
||||||
await this._sessionCall(`${type}.get_all_records`),
|
await this._sessionCall(`${type}.get_all_records`),
|
||||||
|
Loading…
Reference in New Issue
Block a user