Results 1 to 2 of 2

Thread: How do I display a value that's in a store?

  1. #1
    Sencha User
    Join Date
    Apr 2012
    Vote Rating

    Default Unanswered: How do I display a value that's in a store?

    I have a store with only 1 field in it, vehicleMake. I have a second store, searchResults, which has a number of fields, one of which is "make_index". This make_index is the array index value for the vehicleMake store, so what I want to do is use the index from one store to lookup the value in the second store.

    In a template, {make_index} displays the number. I want to do something like vehicleStore[{make_index}] to display the name of the make (which is the value stored in the vehicleMake store).

    I just don't know the syntax for the store lookup. Thanks.

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Gainesville, FL
    Vote Rating


    You should use a template method in your XTemplate. The template method would then return whatever value you need to display.
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    Learn BBCode and use it!

    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2

    Think my support is good? Get more personalized support via a support subscription.

    Need more help with your app? Hire Sencha Services

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts