UserReportsDataSource
Defined in: js-api/src/dapi.ts:2227
Common functionality for handling collections of entities stored on the server. Works with Datagrok REST API, allows to get filtered and paginated lists of entities, Can be extended with specific methods. (i.e. UsersDataSource)
The fluent methods (filter, order, page, by, include, ...) are immutable: each returns a new source and leaves this one as it was, so a source can be kept in a variable and reused as a starting point.
Example
const projects = grok.dapi.projects.order('createdOn', true);
const recent = await projects.filter('createdOn > -1w').list({pageSize: 20});
const all = await projects.list(); // still unfiltered
Extends
Constructors
Constructor
new UserReportsDataSource(
s):UserReportsDataSource
Defined in: js-api/src/dapi.ts:2228
Parameters
| Parameter | Type |
|---|---|
s | any |
Returns
UserReportsDataSource
Overrides
Properties
| Property | Type | Inherited from | Defined in |
|---|---|---|---|
clsName | string | HttpDataSource.clsName | js-api/src/dapi.ts:323 |
dart | any | HttpDataSource.dart | js-api/src/dapi.ts:322 |
Methods
allPackageVersions()
allPackageVersions():
this
Defined in: js-api/src/dapi.ts:404
A source without package version isolation: entities of all package versions, not only the current one.
Returns
this
Inherited from
HttpDataSource.allPackageVersions
by()
by(
i):this
Defined in: js-api/src/dapi.ts:409
A source that returns at most [i] entities per page. See also page.
Parameters
| Parameter | Type |
|---|---|
i | number |