new 2 Yii

I am new to yii and trying to port some existing flash grids into a yii framework. Since I have some existing code I am trying to understand where to go to replicate what my flash grids do

  1. I have a parent grid loaded from a search button click which by default loads a child grid based on data from the first parent row returned and then loads multiple tabs based on the first child row returned. Some of these tabs contain grids and some html table data

  2. when my sql returns and fills the grids and tabs you can then filter the returned data without calling sql again as it filters the data in memory in real time… so for example if you click in a desc filter it filters and loads the grids as each letter is typed. so the more you type the less rows are returned.

i found some parent child type examples and made so I would assume the first question is doable, but didnt find any examples the preloaded the grids , they all seemed to load after clicking a row… not a bid deal i think?

for the second thing i havent searched properly or is it not something generally done in Yii? I really dont want to force a sql query and button click everytime i modify my filters as the query is quite complicated and is joining dozens of tables so it can run for awhile under certain criteria.

thoughts?

For the 2nd question, see the guide sections on data caching. If you know the data is fairly static (or even if it’s not and you don’t care), you can work off of filtering cached results which will bypass the db. http://www.yiiframework.com/doc-2.0/guide-caching-data.html. You can use the debugger to see whether or not the queries are being executing or not and when.

HTML5 I believe has a way to store data on the client, that you could then use for the filtering. Not sure how to do this, but it might something to look into.