1. #1
    Sencha Premium Member
    Join Date
    Nov 2011
    Posts
    102
    Vote Rating
    1
    anarchos78 is on a distinguished road

      0  

    Default Extjs4 stores and records length

    Extjs4 stores and records length


    Hello friends

    I have in a viewport a textfield that it is for searching purpose. I have also a store that holds the data from the search queries. When user conducts a search and if query has results the store is populated with records. Each time user makes a search the store is updating with the new records. It is likely that some queries will not return results. So, what I want is when the search query don,t return any results not to update the store but retain the last successful query results. How can I do that?

    Thanks

    Tom

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,927
    Vote Rating
    443
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    You could have a search store that updates the main store on success.

    Regards,
    Scott.

  3. #3
    Sencha Premium Member
    Join Date
    Nov 2011
    Posts
    102
    Vote Rating
    1
    anarchos78 is on a distinguished road

      0  

    Default


    Hello,
    Thank for the reply. In my app i have only one store holding search results. Is it possible to achieve the above functionality with one store? If not can you point me in how to do it with two stores?

    Thank you again

    Tom

  4. #4
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,927
    Vote Rating
    443
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    I will have to look into this. The idea is to maintain the previous results if the new result is null and display an error?

    I guess you could return success: false from the server if no records found to maintain current set.

    Scott.

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi