We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 13428 ☆ A M B ☆
    • 1,031 Posts
    I have some problems with the speed of a JsonStore. At the moment the JsonStore is filled when the combo box is opened, which is quite slow (Code). Would it be better to fill that JsonStore during initializing the CMP? If yes, how could that be done? If not, are there other possiblilities to speed it up?
      • 3749
      • 24,544 Posts
      I don't have a direct answer, but I dimly remember modifying the grid locally in the Example CMP rather than having refresh call the getlist processor every time something changed. It doesn't speed up the initial load, but it makes a tremendous improvement in performance after that. One down side is that the paging no longer works, so you have to make sure the grid will hold all rows on one page.

      One not-particularly-good option is to display the grid empty and add a 'Load Grid' button. It doesn't cut down the time, but users might perceive it as faster.
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 13428 ☆ A M B ☆
        • 1,031 Posts
        Sorry, not the grid is slow but the combo box in an MODx.Window. I have two superboxselect combo boxes in the same MODx.Window that are showing the same data (list of all ressources of that installation). The superboxselect combo boxes are filled during opening the MODx.Window (if they contain a value) and they are filled after each other (connector runs twice), which is sometimes slow. Is it possible to get the data once?
          • 3749
          • 24,544 Posts
          I would think you could call a getlist processor to initialize the store and use the store for both grids, but I'm not sure how.
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting