Thanks a lot, I was able to fix this, but I still face some issues :-(
Maybe you can give me some other hints.
I address the Data to the grid via WebAPI, my Controller for this looks like that
public object GetAttributes()
{
var dt = Database.db.GetCustomAttributes(Properties.Settings.Default.DBCon);
string json = JsonConvert.SerializeObject(dt, Formatting.Indented);
JArray customAttributes = Newtonsoft.Json.JsonConvert.DeserializeObject<dynamic>(json);
return new { result = customAttributes, count = customAttributes.Count() };
}
The response looks like this
{
"result": [
{
"WORKGROUP": "Homemade",
"AV_PARTNER": "Inv",
"BUSINESS_UNIT": "Operation",
"COMPANY": "Invoco",
"COMPLEXITY": "Advanced",
"CONTACT_INTENSITY": "Intern",
"COST_CENTER": null,
"E_WFM_QUEUE": null,
"INTERNAL_EXTERNAL": "External",
"LANGUAGE": "German",
"OUTBOUND_ANI": null,
"OUTBOUND_MAIL_ADDRESS": null,
"OUTBOUND_MAIL_NAME": null,
"OVERRIDE_ROUTING": null,
"PARTNER_ROUTING_ACTIVE": null,
"PARTNER_TARGET_NUMBER": null,
"QUEUE_GROUP": "800",
"QUEUE_TYPE": "Call Inbound",
"SALES_POTENTIAL": "0",
"SERVICE_GROUP": "10RES",
"SHORT_NUMBER": null,
"SIGNATURE": null,
"TIMEOUT": null,
"UNIT": null,
"USE_SALUTATION": null,
"USE_SIGNATURE": null,
"WAIT_FOR_AGENT_PROMPT": null,
"WORKGROUP_SERVICE": "Advanced_Activation_OTOID_Call",
"ACD_PRIORITY": null,
"IN_QUEUE_TIME_LIMIT_TARGET_WG": null,
"IN_QUEUE_TIME_LIMIT": null,
"SUPERVISOR_ROLE": null,
"OP_BA_01": null,
"OP_BA_02": null,
"OP_BA_03": null,
"OP_BA_09": null,
"OP_BA_10": null,
"OP_BA_04": null,
"OP_BA_05": null
},
{
"WORKGROUP": "myBestFriends",
"AV_PARTNER": null,
"BUSINESS_UNIT": "Operation",
.........
the reponse in total is about 800 rows
two things:
1. The grid is so slow by presenting the data, her is how I have the grid setup, as you can see I have not defined the columns, I take them from the Data itself.
<ej:Grid ID="Grid1" AllowPaging="True" AllowScrolling="True" AllowResizeToFit="true" AllowTextWrap="True" runat="server" OnServerEditRow="Grid1_ServerEditRow">
<DataManager Adaptor="WebApiAdaptor" URL="/api/Attributes"/>
<EditSettings AllowEditing="True"></EditSettings>
<ScrollSettings Height="800" Width="auto" />
<ToolbarSettings ShowToolbar="True" ToolbarItems="edit,update,cancel,search"></ToolbarSettings>
<FilterSettings FilterBarMode="Immediate" ShowFilterBarStatus="True" StatusBarWidth="300"></FilterSettings>
<ClientSideEvents DataBound="setPrimaryKey" />
</ej:Grid>
2. If I try to edit one set, it is very slow until I am able to modify it, and after modifying I am not able to save it. It is also not possible to edit a second row.
What did I do wrong?
How can I speed the things.
Thanks for helping
Martin