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

Callback only happening once for me

1 Answer 114 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
sitefinitysteve
Top achievements
Rank 2
Iron
Iron
Veteran
sitefinitysteve asked on 21 Sep 2011, 07:58 PM
Hey There, quick question

Video: http://screencast.com/t/FcBAyj1xG0

Why is the callback only happening initially and subsequent searches only filter on those 5 returned results...?

$("#search-box").kendoAutoComplete({
        minLength: 3,
        filter: "contains",
        dataTextField: "Title",
        dataValueField: "Title",
        dataSource: new kendo.data.DataSource({
            type: "jsonp",
            severFiltering: false,
            serverPaging: false,
            pageSize: 5,
            template: '<dl>' +
                        '<dt>Title:</dt><dd>${Title}</dd>' +
                        '<dt>Date:</dt><dd>${Date}</dd>' +
                        '<dt>By:</dt><dd>${Speaker}</dd>' +
                      '</dl>',
            transport: {
                read: {
                    cache: true, // to prevent jQuery from adding cache buster
                    dataType: "jsonp",
                    url: alfresco.BaseURL + "/alfresco/service/medportal/autocomplete",
                    data: {
                        alf_ticket: alfresco.Ticket,
                        format: "json"
                    }
                }
            }
        }),
        change: function () {
            callbackToAlfresco();
        }
    });


***EDIT*** My Bad, needed to turn these on
severFiltering: true,
serverPaging: true,


(Also, the templates for some reason are not being applied if you notice)

1 Answer, 1 is accepted

Sort by
0
sitefinitysteve
Top achievements
Rank 2
Iron
Iron
Veteran
answered on 21 Sep 2011, 08:56 PM
**REMOVED**

Template not applying due to it being in the Datasource (whoops :)
Tags
AutoComplete
Asked by
sitefinitysteve
Top achievements
Rank 2
Iron
Iron
Veteran
Answers by
sitefinitysteve
Top achievements
Rank 2
Iron
Iron
Veteran
Share this question
or