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

Custom Edit Template Data json Server delay

1 Answer 64 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Markus
Top achievements
Rank 1
Markus asked on 25 Feb 2015, 10:55 AM
Hi

I have following example:  http://dojo.telerik.com/IqIYI/2

In the example there is a custom edit template when you double click on the calendar to make a new event.

There is a container for "Contacts" which has an array as data-source.

When I open the page I have to get data from the server (which takes 1-2 seconds -> simulated in the example via setTimeout function). Because this takes a few seconds it seems that the template does not catch the data properly - hence the field having no data in the popup template.

How can I "load" data into the edit template or deffer its creation?


<div data-container-for="Contact" class="k-edit-field">
        <select id="Contact" multiple="multiple" name="Contact"
            data-role="multiselect"
            data-bind="value:Contact"
            data-source=kontaktdata     <----------------
            data-text-field="text"
            data-value-field="value"
            data-value-primitive="true"
            ></select>
    </div>


Many thanks

1 Answer, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 27 Feb 2015, 09:09 AM
Hello Markus,

If you would like to bind the widget asynchronously, then you will need to set the data source instance and then to add the new data to it. Check the updated Dojo demo.

Regards,
Georgi Krustev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Scheduler
Asked by
Markus
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Share this question
or