New to Telerik UI for ASP.NET MVC? Download free 30-day trial

DataSourceOrgChartModelDescriptorFactory

Methods

Avatar(System.Linq.Expressions.Expression)

Specify the member used for the parentId field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Avatar(f => f.Avatar);
                        })
                    )
                )

Avatar(System.String)

Specify the member used for the parentId field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Avatar("Avatar");
                        })
                    )
                )

Expanded(System.Linq.Expressions.Expression)

Specify the member used for the expanded field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Expanded(f=>f.Expanded);
                        })
                    )
                )

Expanded(System.String)

Specify the member used for the expanded field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Expanded("Expanded");
                        })
                    )
                )

Expanded(System.Boolean)

Specify the default value of the expanded field.

Parameters

defaultValue - System.Boolean

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Expanded(true);
                        })
                    )
                )

HasChildren(System.Linq.Expressions.Expression)

Specify the member used for the name field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.HasChildren(f=>f.HasChildren);
                        })
                    )
                )

HasChildren(System.String)

Specify the member used for the parentId field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.HasChildren("HasChildren");
                        })
                    )
                )

Id(System.String)

Specify the member used to identify an unique Model instance.

Parameters

fieldName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Id("Id");
                        })
                    )
                )

Id(System.Linq.Expressions.Expression)

Specify the member used to identify an unique Model instance.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                           m.Id(f => f.ID);
                        })
                    )
                )

Name(System.Linq.Expressions.Expression)

Specify the member used for the name field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                           m.Name(f => f.Name);
                        })
                    )
                )

Name(System.String)

Specify the member used for the parentId field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Name("Name");
                        })
                    )
                )

ParentId(System.Linq.Expressions.Expression)

Specify the member used for the parentId field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                           m.ParentId(f => f.ParentId);
                        })
                    )
                )

ParentId(System.String)

Specify the member used for the parentId field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.ParentId("ParentId");
                        })
                    )
                )

Title(System.Linq.Expressions.Expression)

Specify the member used for the parentId field.

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the member

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                           m.Title(f => f.Title);
                        })
                    )
                )

Title(System.String)

Specify the member used for the parentId field.

Parameters

memberName - System.String

The member name.

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Title("Title");
                        })
                    )
                )

Field(System.Linq.Expressions.Expression)

Describes a Model field

Parameters

expression - System.Linq.Expressions.Expression<Func>

Member access expression which describes the field

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Field(f => f.Name);
                        })
                    )
                )

Field(System.String,System.Type)

Describes a Model field

Parameters

memberName - System.String

Field name

memberType - System.Type

Field type

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Field("Title", typeof(string));
                        })
                    )
                )

Field(System.String)

Describes a Model field

Parameters

memberName - System.String

Member name

Example


                @(Html.Kendo().OrgChart<OrgChartEmployeeViewModel>()
                    .Name("orgchart")
                    .DataSource(dataSource => dataSource
                        .Read(read => read.Action("RemoteDataBindingData", "OrgChart"))
                        .Model(m => {
                            m.Field("Title");
                        })
                    )
                )

In this article
Not finding the help you need?