import FilterBuilder from 'spaceinvoices-js-sdk/src/services/filterBuilder.js'FilterBuilder
Test:
Constructor Summary
| Public Constructor | ||
| public |
|
|
Member Summary
| Private Members | ||
| private |
_deleted: * |
|
| private |
_fields: * |
|
| private |
_include: * |
|
| private |
_limit: * |
|
| private |
_order: * |
|
| private |
_param: * |
|
| private |
_skip: * |
|
| private |
_where: {} |
|
Method Summary
| Public Methods | ||
| public |
Logical AND operator |
|
| public |
buildObject(): * |
|
| public |
|
|
| public |
deleted(): * Also return deleted records. |
|
| public |
fields(fields: *): * Include or exclude certain fields |
|
| public |
include(model: *): * Used to include related models |
|
| public |
Limit amount of data returned |
|
| public |
Logical OR operator |
|
| public |
Order results by property |
|
| public |
reset() |
|
| public |
Number of results to skip |
|
| public |
where(fields: *): * Where query filter Accepts operators, see Where operators section for details. |
|
| Private Methods | ||
| private |
_flattenFilter(ob: *, lvl: number): * |
|
| private |
_operator(operation: *, fields: *) |
|
Public Constructors
public constructor() source
Private Members
private _deleted: * source
private _fields: * source
private _include: * source
private _limit: * source
private _order: * source
private _param: * source
private _skip: * source
private _where: {} source
Public Methods
public and(fields: string): * source
Logical AND operator
Params:
| Name | Type | Attribute | Description |
| fields | string |
Return:
| * |
public deleted(): * source
Also return deleted records. Only available on models that implement soft delete
Return:
| * |
public fields(fields: *): * source
Include or exclude certain fields
Params:
| Name | Type | Attribute | Description |
| fields | * |
Return:
| * |
public include(model: *): * source
Used to include related models
Params:
| Name | Type | Attribute | Description |
| model | * |
Return:
| * |
public limit(limit: number): * source
Limit amount of data returned
Params:
| Name | Type | Attribute | Description |
| limit | number |
Return:
| * |
public or(fields: string): * source
Logical OR operator
Params:
| Name | Type | Attribute | Description |
| fields | string |
Return:
| * |
public reset() source
public skip(skip: number): * source
Number of results to skip
Params:
| Name | Type | Attribute | Description |
| skip | number |
Return:
| * |
public where(fields: *): * source
Where query filter Accepts operators, see Where operators section for details.
Params:
| Name | Type | Attribute | Description |
| fields | * |
Return:
| * |
Private Methods
private _flattenFilter(ob: *, lvl: number): * source
Params:
| Name | Type | Attribute | Description |
| ob | * | ||
| lvl | number |
|
Return:
| * |
private _operator(operation: *, fields: *) source
Params:
| Name | Type | Attribute | Description |
| operation | * | ||
| fields | * |
