Does anyone have/know of any examples for something similar to this: Telerik Sample For Multiple Resources
Except, with multi-valued resources? I'm new to entity data sources, and I'm just inheriting a project that has an existing model that works. But the owner is asking for a new resource type to be added that has a one-to-many relationship for "department(s)". If this was a standard 3-tier system, I would have no trouble getting this completed.
I've got the database updated to the model I THINK by creating a link table Called "EventDepartments" (Model Layout is attached). and I have the UI populating with the checkbox list. But...
ResourceType:
Source:
Except, with multi-valued resources? I'm new to entity data sources, and I'm just inheriting a project that has an existing model that works. But the owner is asking for a new resource type to be added that has a one-to-many relationship for "department(s)". If this was a standard 3-tier system, I would have no trouble getting this completed.
I've got the database updated to the model I THINK by creating a link table Called "EventDepartments" (Model Layout is attached). and I have the UI populating with the checkbox list. But...
- There is an Integrity error on insert/update: "The type of the key field 'ID' is expected to be 'System.Int32', but the value provided is actually of type 'System.Object[]'."
- I have no idea where to go from here, as I don't know where to look for the issue since the appointment form is auto-generated/handled.
ResourceType:
<
telerik:ResourceType
KeyField
=
"ID"
Name
=
"Departments"
AllowMultipleValues
=
"true"
TextField
=
"Text"
ForeignKeyField
=
"DepartmentID"
DataSourceID
=
"EDSDepartments"
/>
Source:
<
asp:EntityDataSource
runat
=
"server"
ID
=
"EDSDepartments"
ConnectionString
=
"name=OlympiaEntities"
DefaultContainerName
=
"OlympiaEntities"
EntitySetName
=
"Resources"
EnableInsert
=
"True"
Where
=
"it.ResourceTypeID = 4 && Not it.ParentID Is NULL"
EnableUpdate
=
"True"
>
</
asp:EntityDataSource
>