# SchedulerAgendaViewBuilder

## Methods

### EventDateTemplate(System.String)

Defines the template used by the Agenda view to render the date of the Scheduler events. The available field in the template is "date", which represents the event date.

#### Parameters

##### eventDateTemplate - `System.String`

The value that configures the template content.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventDateTemplate("<strong>#= kendo.toString(date, 'dd-MM-yyyy')#</strong>"));
               })
            )
             
```

### EventDateTemplateId(System.String)

Defines the template used by the Agenda view to render the date of the Scheduler events. The available field in the template is "date", which represents the event date.

#### Parameters

##### eventDateTemplateId - `System.String`

The "id" attribute of the external Kendo UI Template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventDateTemplateId("eventDateTemplate"));
               })
            )
            <script id="eventDateTemplate" type="text/x-kendo-template">
                <strong>#= kendo.toString(date, 'dd-MM-yyyy')#</strong>
            </script>
             
```

### EventDateTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)

Defines the template used by the Agenda view to render the date of the Scheduler events. The available field in the template is "date", which represents the event date.

#### Parameters

##### eventDateTemplateView - `Microsoft.AspNetCore.Html.IHtmlContent`

The Razor View that contains the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventDateTemplateView(Html.Partial("TemplateView")));
               })
            )
             
```

### EventDateTemplateHandler(System.String)

Defines the template used by the Agenda view to render the date of the Scheduler events. The available field in the template is "date", which represents the event date.

#### Parameters

##### eventDateTemplateHandler - `System.String`

The JavaScript function that returns the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventDateTemplateHandler("getEventDateTemplate"));
               })
            )
            <script>
                function getEventDateTemplate(data) {
                    return `<strong>${kendo.toString(data.date, 'dd-MM-yyyy')}</strong>`;
                }
            </script>
             
```

### EventDateTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used by the Agenda view to render the date of the Scheduler events. The available field in the template is "date", which represents the event date.

#### Parameters

##### template - TemplateBuilder\<TModel>

A Template component that configures the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventDateTemplate(Html.Kendo().Template().AddHtml("<strong>${kendo.toString(data.date, 'dd-MM-yyyy')}</strong>")));
               })
            )
             
```

### EventTimeTemplate(System.String)

Defines the template used by the Agenda view to render the time of the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: If "true", the event is "all day". - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTimeTemplate - `System.String`

The value that configures the template content.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventTimeTemplate("template content"));
               })
            )
             
```

### EventTimeTemplateId(System.String)

Defines the template used by the Agenda view to render the time of the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: If "true", the event is "all day". - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTimeTemplateId - `System.String`

The "id" attribute of the external Kendo UI Template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventTimeTemplateId("TemplateID"));
               })
            )
             
```

### EventTimeTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)

Defines the template used by the Agenda view to render the time of the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: If "true", the event is "all day". - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTimeTemplateView - `Microsoft.AspNetCore.Html.IHtmlContent`

The Razor View that contains the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventTimeTemplateView(Html.Partial("Template")));
               })
            )
             
```

### EventTimeTemplateHandler(System.String)

Defines the template used by the Agenda view to render the time of the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: If "true", the event is "all day". - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTimeTemplateHandler - `System.String`

The JavaScript function that returns the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventTimeTemplateHandler("getEventTimeTemplate"));
               })
            )
             
```

### EventTimeTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used by the Agenda view to render the time of the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - isAllDay: If "true", the event is "all day". - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### template - TemplateBuilder\<TModel>

A Template component that configures the template.

#### RETURNS

Returns the current [SchedulerAgendaViewBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/scheduleragendaviewbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
               .Name("scheduler")
               .Views(views =>
               {
                   views.AgendaView(x=>x.EventTimeTemplate(Html.Kendo().Template().AddHtml("${kendo.toString(data.start, "t")} - ${kendo.toString(data.end, "t")}")));
               })
            )
             
```

### Title(System.String)

The user-friendly title of the view displayed by the scheduler.

#### Parameters

##### title - `System.String`

The title

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views =>
                {
                    views.DayView(dayView => {
                        dayView.Title("Day");
                    });
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### Editable(System.Action)

Sets the editing configuration of the current scheduler view.

#### Parameters

##### configurator - System.Action<[SchedulerViewEditableSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/schedulervieweditablesettingsbuilder)>

The lambda which configures the editing

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Editable(editable =>
                {
                    editable.Confirmation(false);
                    editable.TemplateId("customEditTemplate");
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### Editable(System.Boolean)

If set to true the user would be able to create new scheduler events and modify or delete existing ones. Default value is true.

#### Parameters

##### isEditable - `System.Boolean`

The isEditable

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views =>
                {
                    views.DayView(dayView => {
                        dayView.Title("Day");
                        dayView.Editable(false);
                    });
                    views.AgendaView();
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### EventTemplate(System.String)

Defines the template used by the view to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTemplate - `System.String`

The value that configures the template content.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
            	.Name("scheduler")
                .Views(views =>
                {
                    views.DayView(dayView => dayView.EventTemplate(
            		"<div style='color:white'>" +
            			"<img src='" + Url.Content("~/Content/web/scheduler/") + "#= Image #' style='float:left'>" +
            			"<p>" +
            				"#: kendo.toString(Start, 'hh:mm') # - #: kendo.toString(End, 'hh:mm') #" +
            			"</p>" +
            			"<h3>#: title #</h3>" +
            				"<a href='#= Imdb #' style='color:white'>Movie in IMDB</a>" +
            		"</div>"));
                })
            )
             
```

### EventTemplateId(System.String)

Defines the template used by the view to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTemplateId - `System.String`

The "id" attribute of the external Kendo UI Template.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Screening>()
            	.Name("scheduler")
                .Views(views =>
                {
                    views.DayView(dayView => dayView.EventTemplateId("customEventTemplate"));
                })
            )
             
```

### EventTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)

Defines the template used by the view to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTemplateView - `Microsoft.AspNetCore.Html.IHtmlContent`

The Razor View that contains the template.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .Views(views =>
                {
                    views.DayView(dayView => dayView.EventTemplateView(Html.Partial("EventTemplateView")));
                })
            )
             
```

### EventTemplateHandler(System.String)

Defines the template used by the view to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### eventTemplateHandler - `System.String`

The JavaScript function that returns the template.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .Views(views =>
                {
                    views.DayView(dayView => dayView.EventTemplateHandler("getEventTemplate"));
                })
            )
             
```

### EventTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)

Defines the template used by the view to render the Scheduler events. The available fields in the template are: - description: The event description. - end: The event end date. - resources: The event resources. - start: The event start date. - title: The event title.

#### Parameters

##### template - TemplateBuilder\<TModel>

A Template component that configures the template.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Activity>()
                .Name("scheduler")
                .Views(views =>
                {
                    views.DayView(dayView => dayView.EventTemplate(Html.Kendo().Template().AddHtml("<h3>${data.title}</h3>")));
                })
            )
             
```

### SelectedDateFormat(System.String)

The format used to display the selected date. Uses kendo.format. Contains two placeholders - "{0}" and "{1}" which represent the start and end date displayed by the view.

#### Parameters

##### selectedDateFormat - `System.String`

The selectedDateFormat.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views =>
                {
                    views.DayView(dayView => {
                        dayView.Title("Day");
                        dayView.Editable(false);
                        dayView.SelectedDateFormat("{0:dd-MM-yyyy}");
                    });
                    views.AgendaView();
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### SelectedShortDateFormat(System.String)

The format used to display the short selected date. Uses kendo.format. Contains two placeholders - "{0}" and "{1}" which represent the start and end date displayed by the view.

#### Parameters

##### selectedShortDateFormat - `System.String`

The selectedShortDateFormat.

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views =>
                {
                    views.DayView(dayView => {
                        dayView.Title("Day");
                        dayView.Editable(false);
                        dayView.SelectedShortDateFormat("{0:dd-MM-yyyy}");
                    });
                    views.AgendaView();
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### Selected(System.Boolean)

If set to true the view will be initially selected by the scheduler widget. Default value is false.

#### Parameters

##### isSelected - `System.Boolean`

The isSelected

#### RETURNS

Returns the current  instance.

#### Example

```
 
            @(Html.Kendo().Scheduler<Kendo.Mvc.Examples.Models.Scheduler.Task>()
                .Name("scheduler")
                .Date(new DateTime(2013, 6, 13))
                .Views(views =>
                {
                    views.DayView(dayView => {
                        dayView.Title("Day");
                        dayView.Editable(false);
                        dayView.SelectedDateFormat("{0:dd-MM-yyyy}");
                        dayView.Selected(true);
                    });
                    views.AgendaView();
                })
                .DataSource(d => d
                    .Model(m => m.Id(f => f.TaskID))
                        .Read("Read", "Scheduler")
                        .Create("Create", "Scheduler")
                        .Destroy("Destroy", "Scheduler")
                        .Update("Update", "Scheduler")
                )
            )
             
```

### Groups(Kendo.Mvc.UI.SchedulerGroupOrientation)

Sets the orientation of the group headers

#### Parameters

##### orientation - [SchedulerGroupOrientation](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui/schedulergrouporientation)

The orientation

#### Example

```
 
                @(Html.Kendo().Scheduler<Activity>()
                    .Name("scheduler")
                    .Views(v=> { v.TimelineMonthView(t => t.Groups(SchedulerGroupOrientation.Default)); })
                )
             
```

### Groups(System.Boolean)

Sets grouping by date

#### Parameters

##### date - `System.Boolean`

The grouping by date

#### RETURNS

Returns the current  instance.

#### Example

```
 
                @(Html.Kendo().Scheduler<Activity>()
                    .Name("scheduler")
                    .Views(v=> { v.TimelineMonthView(t => t.Groups(true)); })
                )
             
```

### Groups(System.Action)

Sets the resources grouping configuration of the view.

#### Parameters

##### configuration - System.Action<[SchedulerGroupBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/schedulergroupbuilder)>

The lambda which configures the view grouping

#### RETURNS

Returns the current  instance.

#### Example

```
 
                @(Html.Kendo().Scheduler<Activity>()
                    .Name("scheduler")
                    .Views(v=> { v.TimelineMonthView(t => t.Groups(x=>x.Date(true))); })
                )
             
```
