This is a migrated thread and some comments may be shown as answers.

Get raw data from DataSource?

3 Answers 105 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Brian Vallelunga
Top achievements
Rank 1
Brian Vallelunga asked on 04 Feb 2014, 09:31 PM
Is there a way to get at the original data from a data source once it has been fetched from the server? I need to look at which fields were defined in the actual data payload and can't do it until after the data has been sent over. Doing this in the schema parse event won't work for my needs.

3 Answers, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 05 Feb 2014, 10:17 AM
Hello Brian,

The raw (not parsed by the DataSource) server response is available in the requestEnd event. Parsed DataSource records can be retrieved via dataSource.data method.

Regards,
Alexander Valchev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Brian Vallelunga
Top achievements
Rank 1
answered on 07 Feb 2014, 06:36 PM
Just to be clear, given a data source that has already received data, and is past the requestEnd event, there's no way to get at the original data, right?
0
Alexander Valchev
Telerik team
answered on 10 Feb 2014, 09:40 AM
Hi Brian,

The raw (not parsed) server response is not stored anywhere. Once the requestEnd has passed there is no way to get it.
You can get the parsed data (all dataSource items) at any time through the dataSource.data() method.

Regards,
Alexander Valchev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
General Discussions
Asked by
Brian Vallelunga
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
Brian Vallelunga
Top achievements
Rank 1
Share this question
or