Preparing search index...
The search index is not available
Forest Admin - API reference
Forest Admin - API reference
@forestadmin/datasource-toolkit
CollectionDecorator
Class CollectionDecorator
Hierarchy
CollectionDecorator
Implements
Collection
Index
Constructors
constructor
Properties
child
Collection
data
Source
Accessors
name
native
Driver
schema
Methods
aggregate
create
delete
execute
get
Form
list
mark
Schema
As
Dirty
refine
Filter
refine
Schema
render
Chart
update
Constructors
constructor
new
Collection
Decorator
(
childCollection
:
Collection
, dataSource
:
DataSource
<
Collection
>
)
:
CollectionDecorator
Parameters
childCollection:
Collection
dataSource:
DataSource
<
Collection
>
Returns
CollectionDecorator
Properties
Protected
child
Collection
child
Collection
:
Collection
Readonly
data
Source
data
Source
:
DataSource
<
Collection
>
Accessors
name
get
name
(
)
:
string
Returns
string
native
Driver
get
nativeDriver
(
)
:
unknown
Returns
unknown
schema
get
schema
(
)
:
CollectionSchema
Returns
CollectionSchema
Methods
aggregate
aggregate
(
caller
:
Caller
, filter
:
Filter
, aggregation
:
Aggregation
, limit
?:
number
)
:
Promise
<
AggregateResult
[]
>
Parameters
caller:
Caller
filter:
Filter
aggregation:
Aggregation
Optional
limit:
number
Returns
Promise
<
AggregateResult
[]
>
create
create
(
caller
:
Caller
, data
:
RecordData
[]
)
:
Promise
<
RecordData
[]
>
Parameters
caller:
Caller
data:
RecordData
[]
Returns
Promise
<
RecordData
[]
>
delete
delete
(
caller
:
Caller
, filter
:
Filter
)
:
Promise
<
void
>
Parameters
caller:
Caller
filter:
Filter
Returns
Promise
<
void
>
execute
execute
(
caller
:
Caller
, name
:
string
, data
:
RecordData
, filter
?:
Filter
)
:
Promise
<
ActionResult
>
Parameters
caller:
Caller
name:
string
data:
RecordData
Optional
filter:
Filter
Returns
Promise
<
ActionResult
>
get
Form
get
Form
(
caller
:
Caller
, name
:
string
, data
?:
RecordData
, filter
?:
Filter
, metas
?:
GetFormMetas
)
:
Promise
<
ActionFormElement
[]
>
Parameters
caller:
Caller
name:
string
Optional
data:
RecordData
Optional
filter:
Filter
Optional
metas:
GetFormMetas
Returns
Promise
<
ActionFormElement
[]
>
list
list
(
caller
:
Caller
, filter
:
PaginatedFilter
, projection
:
Projection
)
:
Promise
<
RecordData
[]
>
Parameters
caller:
Caller
filter:
PaginatedFilter
projection:
Projection
Returns
Promise
<
RecordData
[]
>
Protected
mark
Schema
As
Dirty
mark
Schema
As
Dirty
(
)
:
void
Returns
void
Protected
refine
Filter
refine
Filter
(
caller
:
Caller
, filter
?:
PaginatedFilter
)
:
Promise
<
PaginatedFilter
>
Parameters
caller:
Caller
Optional
filter:
PaginatedFilter
Returns
Promise
<
PaginatedFilter
>
Protected
refine
Schema
refine
Schema
(
subSchema
:
CollectionSchema
)
:
CollectionSchema
Parameters
subSchema:
CollectionSchema
Returns
CollectionSchema
render
Chart
render
Chart
(
caller
:
Caller
, name
:
string
, recordId
:
CompositeId
)
:
Promise
<
unknown
>
Parameters
caller:
Caller
name:
string
recordId:
CompositeId
Returns
Promise
<
unknown
>
update
update
(
caller
:
Caller
, filter
:
Filter
, patch
:
RecordData
)
:
Promise
<
void
>
Parameters
caller:
Caller
filter:
Filter
patch:
RecordData
Returns
Promise
<
void
>
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
Modules
Forest
Admin -
API reference
@forestadmin/agent
@forestadmin/datasource-
customizer
@forestadmin/datasource-
mongoose
@forestadmin/datasource-
sequelize
@forestadmin/datasource-
sql
@forestadmin/datasource-
toolkit
@forestadmin/plugin-
aws-
s3
@forestadmin/plugin-
export-
advanced
Collection
Decorator
constructor
child
Collection
data
Source
name
native
Driver
schema
aggregate
create
delete
execute
get
Form
list
mark
Schema
As
Dirty
refine
Filter
refine
Schema
render
Chart
update