New to Kendo UI for Angular? Start a free 30-day trial

BaseEditService

A base implementation of the edit service which persists data to traditional CRUD services such as OData.

To support custom models, the BaseEditService class requires a field map as a constructor parameter. Subclasses require you to implement the read operation, which is not called directly by the base class, and the save method which persists the created, updated, and deleted entities.

The events observable will publish the current data which is set upon subscription by using, for example, an async pipe (more information).

Implementations which utilize dedicated services, such as Google Calendar and Microsoft Exchange, will typically implement the EditService of the Scheduler directly.

See example in this article.

Selector

``

Fields

NameTypeDefaultDescription

events

Observable<TEvent[]>

An observable stream with the current events.

fields

SchedulerModelFields

The model field map that will be used during the reading and updating of data items.

Methods

create

Creates a new event.

Parameters

event

TEvent

The event that will be created.

createException

Creates an exception to an existing recurring event. The recurrenceId field of the recurrence exception or the custom field that is set by the model map will point to the master recurring event.

Parameters

event

TEvent

The instance of the occurrence that will be removed from the series.

value

TEvent

An object which contains the updated field values, for example, a form group value.

findRecurrenceMaster

Returns the master recurring event for a specified recurring event.

Parameters

event

TEvent

An event from the recurrence series.

Returns

any

the master recurring event for the series.

isException

Checks if the event is a recurrence exception.

Parameters

event

any

The event that will be checked.

Returns

boolean

true if the event is a unique event which belongs to a recurrence series. Otherwise, returns false.

isRecurring

Checks if the event is part of the recurrence series.

Parameters

event

any

The event that will be checked.

Returns

boolean

true if the event is an occurrence, an exception, or a master event. Otherwise, returns false.

remove

Removes a non-recurring event.

Parameters

event

TEvent

A reference to the event that will be removed.

removeOccurrence

Removes a single occurrence from a series of recurring events. The recurrenceId field of the occurrence or the custom field which is set by a model map will point to the master recurring event.

Parameters

event

TEvent

A reference to the occurrence.

removeSeries

Removes the recurrence series and exceptions, if any.

Parameters

event

TEvent

Any event from the recurrence series.

update

Updates the specified event by copying the changed fields from the supplied value object.

Parameters

event

TEvent

The event that will be updated.

value

any

An object which contains the new field values, for example, a form group value.