Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions packages/devextreme-angular/src/ui/scheduler/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import dxScheduler from 'devextreme/ui/scheduler';
import dxSortable from 'devextreme/ui/sortable';
import dxDraggable from 'devextreme/ui/draggable';
import DataSource from 'devextreme/data/data_source';
import { AllDayPanelMode, ViewType, dxSchedulerAppointment, CellAppointmentsLimit, AppointmentAddedEvent, AppointmentAddingEvent, AppointmentClickEvent, AppointmentContextMenuEvent, AppointmentDblClickEvent, AppointmentDeletedEvent, AppointmentDeletingEvent, AppointmentFormOpeningEvent, AppointmentRenderedEvent, AppointmentTooltipShowingEvent, AppointmentUpdatedEvent, AppointmentUpdatingEvent, CellClickEvent, CellContextMenuEvent, ContentReadyEvent, DisposingEvent, InitializedEvent, OptionChangedEvent, RecurrenceEditMode, dxSchedulerScrolling, dxSchedulerToolbar } from 'devextreme/ui/scheduler';
import { AllDayPanelMode, ViewType, dxSchedulerAppointment, SchedulerAppointmentFormIconDisplay, CellAppointmentsLimit, AppointmentAddedEvent, AppointmentAddingEvent, AppointmentClickEvent, AppointmentContextMenuEvent, AppointmentDblClickEvent, AppointmentDeletedEvent, AppointmentDeletingEvent, AppointmentFormOpeningEvent, AppointmentRenderedEvent, AppointmentTooltipShowingEvent, AppointmentUpdatedEvent, AppointmentUpdatingEvent, CellClickEvent, CellContextMenuEvent, ContentReadyEvent, DisposingEvent, InitializedEvent, OptionChangedEvent, RecurrenceEditMode, dxSchedulerScrolling, dxSchedulerToolbar } from 'devextreme/ui/scheduler';
import { event } from 'devextreme/events/events.types';
import { DataSourceOptions } from 'devextreme/data/data_source';
import { Store } from 'devextreme/data/store';
Expand Down Expand Up @@ -393,10 +393,10 @@ export class DxSchedulerComponent extends DxComponent implements OnDestroy, OnCh

*/
@Input()
get editing(): boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void) } } {
get editing(): boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void), showIcons?: SchedulerAppointmentFormIconDisplay } } {
return this._getOption('editing');
}
set editing(value: boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void) } }) {
set editing(value: boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void), showIcons?: SchedulerAppointmentFormIconDisplay } }) {
this._setOption('editing', value);
}

Expand Down Expand Up @@ -679,10 +679,10 @@ export class DxSchedulerComponent extends DxComponent implements OnDestroy, OnCh

*/
@Input()
get resources(): { allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[] {
get resources(): { allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, icon?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[] {
return this._getOption('resources');
}
set resources(value: { allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[]) {
set resources(value: { allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, icon?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[]) {
this._setOption('resources', value);
}

Expand Down Expand Up @@ -1202,7 +1202,7 @@ export class DxSchedulerComponent extends DxComponent implements OnDestroy, OnCh
* This member supports the internal infrastructure and is not intended to be used directly from your code.

*/
@Output() editingChange: EventEmitter<boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void) } }>;
@Output() editingChange: EventEmitter<boolean | { allowAdding?: boolean, allowDeleting?: boolean, allowDragging?: boolean, allowResizing?: boolean, allowTimeZoneEditing?: boolean, allowUpdating?: boolean, form?: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void), showIcons?: SchedulerAppointmentFormIconDisplay } }>;

/**

Expand Down Expand Up @@ -1356,7 +1356,7 @@ export class DxSchedulerComponent extends DxComponent implements OnDestroy, OnCh
* This member supports the internal infrastructure and is not intended to be used directly from your code.

*/
@Output() resourcesChange: EventEmitter<{ allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[]>;
@Output() resourcesChange: EventEmitter<{ allowMultiple?: boolean, colorExpr?: string, dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string, displayExpr?: ((resource: any) => string) | string, fieldExpr?: string, icon?: string, label?: string, useColorAsDefault?: boolean, valueExpr?: Function | string }[]>;

/**

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {


import { dxFormButtonItem, dxFormEmptyItem, dxFormGroupItem, dxFormSimpleItem, dxFormTabbedItem } from 'devextreme/ui/form';
import { SchedulerAppointmentFormIconDisplay } from 'devextreme/ui/scheduler';

import {
DxIntegrationModule,
Expand Down Expand Up @@ -81,10 +82,10 @@ export class DxoSchedulerEditingComponent extends NestedOption implements OnDest
}

@Input()
get form(): undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void) } {
get form(): undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void), showIcons?: SchedulerAppointmentFormIconDisplay } {
return this._getOption('form');
}
set form(value: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void) }) {
set form(value: undefined | { items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>, onCanceled?: ((formData: any) => void), onSaved?: ((formData: any) => void), showIcons?: SchedulerAppointmentFormIconDisplay }) {
this._setOption('form', value);
}

Expand Down
9 changes: 9 additions & 0 deletions packages/devextreme-angular/src/ui/scheduler/nested/form.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import {


import { dxFormButtonItem, dxFormEmptyItem, dxFormGroupItem, dxFormSimpleItem, dxFormTabbedItem } from 'devextreme/ui/form';
import { SchedulerAppointmentFormIconDisplay } from 'devextreme/ui/scheduler';

import {
DxIntegrationModule,
Expand Down Expand Up @@ -67,6 +68,14 @@ export class DxoSchedulerFormComponent extends NestedOption implements OnDestroy
this._setOption('onSaved', value);
}

@Input()
get showIcons(): SchedulerAppointmentFormIconDisplay {
return this._getOption('showIcons');
}
set showIcons(value: SchedulerAppointmentFormIconDisplay) {
this._setOption('showIcons', value);
}


protected get _optionPath() {
return 'form';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,14 @@ export class DxiSchedulerResourceComponent extends CollectionNestedOption {
this._setOption('fieldExpr', value);
}

@Input()
get icon(): string {
return this._getOption('icon');
}
set icon(value: string) {
this._setOption('icon', value);
}

@Input()
get label(): string {
return this._getOption('label');
Expand Down
1 change: 1 addition & 0 deletions packages/devextreme-metadata/make-angular-metadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Ng.makeMetadata({
removeMembers(/\/grids:LoadPanel.indicatorOptions/),
removeMembers(/\/scheduler:Toolbar/),
removeMembers(/\/scheduler:dxSchedulerOptions\.editing\.form/),
removeMembers(/\/scheduler:dxSchedulerOptions\.resources\.icon/),
removeMembers(/\/stepper:/),
removeMembers(/\/speech_to_text:/),
],
Expand Down
5 changes: 4 additions & 1 deletion packages/devextreme-react/src/scheduler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import dxScheduler, {
import { Component as BaseComponent, IHtmlOptions, ComponentRef, NestedComponentMeta } from "./core/component";
import NestedOption from "./core/nested-option";

import type { ViewType, AppointmentAddedEvent, AppointmentAddingEvent, AppointmentClickEvent, AppointmentContextMenuEvent, AppointmentDblClickEvent, AppointmentDeletedEvent, AppointmentDeletingEvent, AppointmentFormOpeningEvent, AppointmentRenderedEvent, AppointmentTooltipShowingEvent, AppointmentUpdatedEvent, AppointmentUpdatingEvent, CellClickEvent, CellContextMenuEvent, ContentReadyEvent, DisposingEvent, InitializedEvent, SchedulerPredefinedToolbarItem, DateNavigatorItemProperties, SchedulerPredefinedDateNavigatorItem, dxSchedulerToolbarItem, AllDayPanelMode, AppointmentCollectorTemplateData, AppointmentTemplateData, AppointmentTooltipTemplateData, CellAppointmentsLimit, dxSchedulerScrolling } from "devextreme/ui/scheduler";
import type { ViewType, AppointmentAddedEvent, AppointmentAddingEvent, AppointmentClickEvent, AppointmentContextMenuEvent, AppointmentDblClickEvent, AppointmentDeletedEvent, AppointmentDeletingEvent, AppointmentFormOpeningEvent, AppointmentRenderedEvent, AppointmentTooltipShowingEvent, AppointmentUpdatedEvent, AppointmentUpdatingEvent, CellClickEvent, CellContextMenuEvent, ContentReadyEvent, DisposingEvent, InitializedEvent, SchedulerAppointmentFormIconDisplay, SchedulerPredefinedToolbarItem, DateNavigatorItemProperties, SchedulerPredefinedDateNavigatorItem, dxSchedulerToolbarItem, AllDayPanelMode, AppointmentCollectorTemplateData, AppointmentTemplateData, AppointmentTooltipTemplateData, CellAppointmentsLimit, dxSchedulerScrolling } from "devextreme/ui/scheduler";
import type { ContentReadyEvent as ButtonContentReadyEvent, DisposingEvent as ButtonDisposingEvent, InitializedEvent as ButtonInitializedEvent, dxButtonOptions, ClickEvent, OptionChangedEvent } from "devextreme/ui/button";
import type { ContentReadyEvent as ButtonGroupContentReadyEvent, DisposingEvent as ButtonGroupDisposingEvent, InitializedEvent as ButtonGroupInitializedEvent, OptionChangedEvent as ButtonGroupOptionChangedEvent, dxButtonGroupItem, ItemClickEvent, SelectionChangedEvent } from "devextreme/ui/button_group";
import type { ContentReadyEvent as TabPanelContentReadyEvent, DisposingEvent as TabPanelDisposingEvent, InitializedEvent as TabPanelInitializedEvent, OptionChangedEvent as TabPanelOptionChangedEvent, dxTabPanelOptions, ItemClickEvent as TabPanelItemClickEvent, SelectionChangedEvent as TabPanelSelectionChangedEvent, dxTabPanelItem, ItemContextMenuEvent, ItemHoldEvent, ItemRenderedEvent, SelectionChangingEvent, TitleClickEvent, TitleHoldEvent, TitleRenderedEvent } from "devextreme/ui/tab_panel";
Expand Down Expand Up @@ -401,6 +401,7 @@ type IEditingProps = React.PropsWithChildren<{
items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>;
onCanceled?: ((formData: any) => void);
onSaved?: ((formData: any) => void);
showIcons?: SchedulerAppointmentFormIconDisplay;
};
}>
const _componentEditing = (props: IEditingProps) => {
Expand Down Expand Up @@ -476,6 +477,7 @@ type IFormProps = React.PropsWithChildren<{
items?: Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>;
onCanceled?: ((formData: any) => void);
onSaved?: ((formData: any) => void);
showIcons?: SchedulerAppointmentFormIconDisplay;
}>
const _componentForm = (props: IFormProps) => {
return React.createElement(NestedOption<IFormProps>, {
Expand Down Expand Up @@ -923,6 +925,7 @@ type IResourceProps = React.PropsWithChildren<{
dataSource?: Array<any> | DataSource | DataSourceOptions | null | Store | string;
displayExpr?: ((resource: any) => string) | string;
fieldExpr?: string;
icon?: string;
label?: string;
useColorAsDefault?: boolean;
valueExpr?: (() => void) | string;
Expand Down
7 changes: 6 additions & 1 deletion packages/devextreme-vue/src/scheduler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import {
RecurrenceEditMode,
dxSchedulerScrolling,
dxSchedulerToolbar,
SchedulerAppointmentFormIconDisplay,
SchedulerPredefinedToolbarItem,
DateNavigatorItemProperties,
SchedulerPredefinedDateNavigatorItem,
Expand Down Expand Up @@ -750,11 +751,13 @@ const DxFormConfig = {
"update:items": null,
"update:onCanceled": null,
"update:onSaved": null,
"update:showIcons": null,
},
props: {
items: Array as PropType<Array<dxFormButtonItem | dxFormEmptyItem | dxFormGroupItem | dxFormSimpleItem | dxFormTabbedItem>>,
onCanceled: Function as PropType<((formData: any) => void)>,
onSaved: Function as PropType<((formData: any) => void)>
onSaved: Function as PropType<((formData: any) => void)>,
showIcons: String as PropType<SchedulerAppointmentFormIconDisplay>
}
};

Expand Down Expand Up @@ -1184,6 +1187,7 @@ const DxResourceConfig = {
"update:dataSource": null,
"update:displayExpr": null,
"update:fieldExpr": null,
"update:icon": null,
"update:label": null,
"update:useColorAsDefault": null,
"update:valueExpr": null,
Expand All @@ -1194,6 +1198,7 @@ const DxResourceConfig = {
dataSource: [Array, Object, String] as PropType<Array<any> | DataSource | DataSourceOptions | null | Store | string | Record<string, any>>,
displayExpr: [Function, String] as PropType<(((resource: any) => string)) | string>,
fieldExpr: String,
icon: String,
label: String,
useColorAsDefault: Boolean,
valueExpr: [Function, String] as PropType<((() => void)) | string>
Expand Down
13 changes: 13 additions & 0 deletions packages/devextreme/js/ui/scheduler.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ export type CellAppointmentsLimit = 'auto' | 'unlimited';
/** @public */
export type RecurrenceEditMode = 'dialog' | 'occurrence' | 'series';
/** @public */
export type SchedulerAppointmentFormIconDisplay = 'both' | 'main' | 'recurrence' | 'none';
/** @public */
export type ViewType = 'agenda' | 'day' | 'month' | 'timelineDay' | 'timelineMonth' | 'timelineWeek' | 'timelineWorkWeek' | 'week' | 'workWeek';
/** @public */
export type SchedulerPredefinedToolbarItem = 'today' | 'dateNavigator' | 'viewSwitcher';
Expand Down Expand Up @@ -656,6 +658,12 @@ export interface dxSchedulerOptions extends WidgetOptions<dxScheduler> {
* @public
*/
onCanceled?: ((formData: any) => void);
/**
* @docid
* @default "main"
* @public
*/
showIcons?: SchedulerAppointmentFormIconDisplay;
} | undefined;
};
/**
Expand Down Expand Up @@ -912,6 +920,11 @@ export interface dxSchedulerOptions extends WidgetOptions<dxScheduler> {
* @default ""
*/
fieldExpr?: string;
/**
* @docid
* @default ""
*/
icon?: string;
/**
* @docid
* @default ""
Expand Down
1 change: 1 addition & 0 deletions packages/devextreme/js/ui/scheduler_types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export {
AllDayPanelMode,
CellAppointmentsLimit,
RecurrenceEditMode,
SchedulerAppointmentFormIconDisplay,
ViewType,
SchedulerPredefinedToolbarItem,
SchedulerPredefinedDateNavigatorItem,
Expand Down
13 changes: 13 additions & 0 deletions packages/devextreme/ts/dx.all.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26174,6 +26174,11 @@ declare module DevExpress.ui {
DevExpress.common.core.events.ChangedOptionInfo;
export type Properties = dxSchedulerOptions;
export type RecurrenceEditMode = 'dialog' | 'occurrence' | 'series';
export type SchedulerAppointmentFormIconDisplay =
| 'both'
| 'main'
| 'recurrence'
| 'none';
export type SchedulerPredefinedDateNavigatorItem =
| 'prev'
| 'next'
Expand Down Expand Up @@ -26464,6 +26469,10 @@ declare module DevExpress.ui {
* [descr:dxSchedulerOptions.editing.form.onCanceled]
*/
onCanceled?: (formData: any) => void;
/**
* [descr:dxSchedulerOptions.editing.form.showIcons]
*/
showIcons?: DevExpress.ui.dxScheduler.SchedulerAppointmentFormIconDisplay;
}
| undefined;
};
Expand Down Expand Up @@ -26652,6 +26661,10 @@ declare module DevExpress.ui {
* [descr:dxSchedulerOptions.resources.fieldExpr]
*/
fieldExpr?: string;
/**
* [descr:dxSchedulerOptions.resources.icon]
*/
icon?: string;
/**
* [descr:dxSchedulerOptions.resources.label]
*/
Expand Down
Loading