v2013.2.1024 declarative binding an endless scrolling list view is broken

14 posts, 0 answers
  1. Dean
    Dean avatar
    73 posts
    Member since:
    Oct 2012

    Posted 31 Oct 2013 Link to this post

    My endless scrolling listviews were working (excepting a couple of bugs that I've already brought up on this forum) until I updated to v2013.2.1024 and now I get the following error: 

    "Uncaught Error: the DataSource does not have page size configured. Page Size setting is mandatory for the mobile listview virtual scrolling to work as expected."

    I found that this only happens when I use declarative binding. This problem also occurs in the latest available beta v2013.3.1030.

    Cheers
    Dean
  2. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 01 Nov 2013 Link to this post

    Hi Dean,

    This sounds like a bug we have introduced. Is it possible for you to share some sample code? We will look into it immediately. 

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
  4. Dean
    Dean avatar
    73 posts
    Member since:
    Oct 2012

    Posted 03 Nov 2013 Link to this post

    I copied the endless-scrolling example and changed it to use declarative binding. You'll need to unzip and put the attached html file in the same directory so that the file paths for links and scripts work:
    kendoui.mobile.2013.2.1024.commercial\examples\mobile\listview

    While creating this example I noticed the problem is with:
    data-bind="source: dataSource"
    but this works:
    data-source="dataSource"

    Cheers
    Dean
  5. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 04 Nov 2013 Link to this post

    Hello Dean,

    Thank you for your example. I can confirm this problem - we will try to target this for our next official release, due later this month. Your telerik points have been updated. 

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  6. Dean
    Dean avatar
    73 posts
    Member since:
    Oct 2012

    Posted 21 Nov 2013 Link to this post

    I've just tried v2013.3.1119 and I am very disappointed to find this hasn't been addressed. I can't upgrade until it is fixed because I use declarative binding throughout my app.
  7. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 25 Nov 2013 Link to this post

    Hello Dean,

    I am sorry for the inconvenience - we fixed a very similar case, but it looks like this one remains broken. We are going to resolve it in our upcoming internal builds, most probably by the end of this week. 

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  8. Brandon Peterson
    Brandon Peterson avatar
    47 posts
    Member since:
    May 2007

    Posted 06 Dec 2013 Link to this post

    I am getting the same error when using MVVM binding although the DataSource pageSize property is set:
    "the DataSource does not have page size configured. Page Size setting is mandatory for the mobile listview virtual scrolling to work as expected."
    <div data-role="view" id="home" data-title="Home" data-model="vm">
        <ul data-role="listview" data-bind="source: albumList, click: itemClick" data-template="album-template" data-pull-to-refresh="true" data-endless-scroll="true"></ul>
        <script type="text/x-kendo-tmpl" id="album-template">
            <img data-bind="attr: { src: artwork }" />
            <div class="info">
                <h3 data-bind="text: title"></h3>
                <em data-bind="text: artist"></em>
            </div>
        </script>
    </div>
    http://jsfiddle.net/bYKYE/315/

    If I use data-soure="vm.albumList" instead then I lose all MVVM template binding capabilities and have to modify like so:
    <ul data-role="listview" data-source="vm.albumList" data-bind="click: itemClick" data-template="album-template" data-pull-to-refresh="true" data-endless-scroll="true"></ul>
        <script type="text/x-kendo-tmpl" id="album-template">
            <img src="#:artwork#" />
            <div class="info">
                <strong>#= title#</strong>
                <em>#= artist#</em>
            </div>
        </script>
    http://jsfiddle.net/bYKYE/313/

    I would prefer not to refactor my entire app to implement a workaround for this bug. Is there a plan to correct the issue in upcoming releases?
  9. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 09 Dec 2013 Link to this post

    Hi Brandon,

    the fix I refer to is published as an internal build - please give it a try. 

    On a side note, I do want to mention that using MVVM bindings with endless scrolling yields increased memory usage and affects performance in general. The effect is especially visible on a mobile device. 

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  10. Durendal
    Durendal avatar
    6 posts
    Member since:
    May 2011

    Posted 11 Dec 2013 Link to this post

    This issue renders the demos in GitHub unusable against the latest KendoUI release.  This means that users cannot take advantage of the latest mobile widgets.

    What are the plans to update the GitHub demos please.   New user like myself who cloned the demos as a base for our POCs are finding this out the hard way.

    If the demos are not QA against the latest release, please consider removing them, or at least add a warning/disclaimer. This way, newbies do not end up investing efforts needlessly.  Thanks.
  11. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 12 Dec 2013 Link to this post

    Hello Durendal,

    thank you for your feedback - indeed, the published demos are lagging behind our current release. We are looking into updating them, especially the ones which feature outdated practices. 

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  12. Brandon Peterson
    Brandon Peterson avatar
    47 posts
    Member since:
    May 2007

    Posted 26 Dec 2013 Link to this post

    Petyo, Internal Build 2013.3.1220 is working well with data- attributes. Thank you for the performance tip as well.

    MVVM binding does make sense though in item templates for my scenario where a listview item is selected and then edited in a detail view. Upon navigating back from the detail view to the listview view, the item has been updated "inline" without having to re-bind the listview and lose the scroll position. If there is a more performant method of rebinding, repainting, and maintaining listview scroll position I'd appreciate any suggestions.
  13. Alexander Valchev
    Admin
    Alexander Valchev avatar
    2875 posts

    Posted 30 Dec 2013 Link to this post

    Hello Brandon,

    If I understood correctly, you are binding the ListView because you do not want to loose the scroller position after edit changes are saved. The ListView Editing demo also uses detail view for editing the selected item however the scroll position is never lost. Could you please check it and let me know what I am missing?

    Regards,
    Alexander Valchev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  14. Kelly
    Kelly avatar
    73 posts
    Member since:
    Apr 2011

    Posted 19 Mar 2014 Link to this post

    I'm completely confused.  Is this still a bug or not? I'm getting the exact behavior reported by Brandon above.  I'm trying to implement endless scrolling and pull to refresh with code very similar to his.  I'm using the latest kit, and I still get this error.  I'm binding attributes in a template, which is crucial for my app.  If I use data-bind="source: blah" I get the error.  If I use data-source="fully.qualified.blah", there is no error, but I lose the attribute bindings.

    If this won't work, I'll have to ditch the DataSource I'm using for no other reason than to implement endless scrolling.  I really like letting the user control refreshes and fetching with scrolling.  I don't want to clutter my interface with a bunch of "More" and "Refresh" buttons.  Are there any examples available for hooking into the listview scroller to implement one's own version of endless scrolling and pull to refresh?  A way to just provide my own pulltorefresh and fetchnextpage functions to the listview would be great.  I know they don't exist, but can anyone think of a way to jury-rig them?

    Thanks,

    Kelly
  15. Kelly
    Kelly avatar
    73 posts
    Member since:
    Apr 2011

    Posted 20 Mar 2014 in reply to Kelly Link to this post

    Never mind!  I see that the Scroller is where the pull is implemented, so all the events I was asking about are already there ...perfect!  Thanks.
Back to Top
Kendo UI is VS 2017 Ready