A plugin that configures resources.
Use the following statement to import a plugin with embedded theme components:
import { Resources } from '@devexpress/dx-react-scheduler-material-ui';
If you want to use custom components, you can import the themeless plugin:
import { Resources } from '@devexpress/dx-react-scheduler';
Name | Type | Default | Description |
---|---|---|---|
data | Array<Resource> | Resource data objects. | |
mainResourceName? | string | Specifies which of several resources provides colors for appointments. | |
palette? | Palette | [red, pink, purple, deepPurple, indigo, blue, lightBlue, cyan, teal, green, lightGreen, lime, yellow, ember, orange, deepOrange] | A palette used if a resource instance color is not defined. |
Configures a resource.
Field | Type | Description |
---|---|---|
id | number | string | The resource ID. |
fieldName | string | A data field name used to assign appointments to this resource. This field should be present in appointment data objects. |
instances | Array<ResourceInstance> | Resource instances. |
title? | string | The resource title. |
allowMultiple? | boolean | Indicates whether an appointment can be assigned to several instances of this resource. |
Configures a resource instance.
Field | Type | Description |
---|---|---|
id | number | string | The resource instance ID. |
text? | string | The resource instance text. |
color? | string | Color | The resource instance color. |
Specifies a palette that provides colors for resource instances with undefined colors.
Type: Array<string | Color>
An object that provides information about a resource.
Field | Type | Description |
---|---|---|
fieldName | string | A data field name used to assign an appointment to this resource. |
title | string | The resource title. |
allowMultiple | boolean | Indicates whether an appointment can be assigned to several instances of this resource. |
isMain | boolean | true if this resource's name is assigned to the mainResourceName property. |
instances | Array<ValidResourceInstance> | Resource instances. |
An object that provides information about a resource instance.
Field | Type | Description |
---|---|---|
id | number | string | The resource instance ID. |
fieldName | string | A data field name used to assign an appointment to the instance's resource. |
text | string | The resource instance text. |
title | string | The title of the instance's resource. |
allowMultiple | boolean | Indicates whether the instance's resource allows users to assign an appointment to several resource instances. |
isMain | boolean | true if the name of the instance's resource is assigned to the mainResourceName property. |
color? | string | Color | The resource instance color. |
The Material-UI Color object. See these examples for information on how to use it.
Type: object