Hello,
we have a web service that uses authentication by Windows Integrated Authentication. It uses CORS to enable calls from other domains. We read data from this web service with Kendo UI DataSource.
In Internet Explorer 11, with "Access data sources across domains" set to enabled, it works fine, a prompt for user credentials is displayed and data is returned. But without this setttings, no window for user credentials is displayed and reading from web service returns an error. There is no meaningful message, in xhr.statusText there is only text "error".
This is the code of the DataSource (I have omitted the schema of the DataSource, because I think it is not needed here):
equipmentsDataSource = new kendo.data.DataSource({
error: function(e) {debugger;},
transport: {
read: {
url: "http://192.168.55.47:7081/Portal.svc/GetEquipments",
type: "post",
dataType: "json",
contentType: "application/json",
data: {
"equipmentids": favoriteEquipmentIds,
"relationstoreturn": "ge_equipment_ge_public_tender_subject_equipmentid", "ge_ge_certifikace_equipment"],
"fieldstoreturn": ["equipmentid", "ge_alias", "ge_nameen"]
}
//beforeSend: function (xhr) {
// debugger;
// xhr.setRequestHeader('Authorization', window.auth);
//}
},
parameterMap: function (data) {
return kendo.stringify(data);
}
},
...
});
I tried to use beforeSend event (the commented part of the code), but it also doesn't work, because window.auth is undefined.
Is there something missing in my code, or maybe in our web service, that should be set?
Thanks for help,
Boris.