jQuery UI Widgets Forums Lists ListBox Additem shows originalItem = null

This topic contains 3 replies, has 2 voices, and was last updated by  Peter Stoev 8 years, 10 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • Additem shows originalItem = null #84518

    edilson88
    Participant

    When adding a new item like :
    var item = {
    label:’Main’,
    value: 0,
    videoname: ‘Main’,
    video_id: 0,
    msg_id: 0
    }
    $(“#jqxWidgetA”).jqxListBox(‘insertAt’, item, 0 );

    the resulting originalitem for the item created is always null

    Additem shows originalItem = null #84536

    Peter Stoev
    Keymaster

    Hi edilsonamaral,

    1. originalItem is internal API so you should better not use it.
    2. It is correct the originalItem to be null because you do not have originalItem in this case as there is no data bound item.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    Additem shows originalItem = null #84567

    edilson88
    Participant

    Is there a way to create an item with the information above to be retrieved later ?

    Additem shows originalItem = null #84579

    Peter Stoev
    Keymaster

    Hi edilsonamaral,

    It’s wrong to try to use Internal API. What happens when tomorrow we change the internal property’s name? Your application will be broken.
    The Item properties can be found on the ListBox’s documentation. Each item has Label and Value and for the ListBox we consider this to be enough to hold display information and value information.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.