I have a CGridView with columns from a table "product" => {'product_id','category_id',...}
I have another table "category" => {'category_id','category_name'}
category_id is the FK in the product table.
Now i want a dropdown list of the category table and on selecting a particular value the CGridView of product should be updated to show only the rows with that category_id.
I also need the column filtering/sorting for the CGridView to work (using AJAX).
I was able to refresh the CGridView when a value is selected from the dropdown, however i am not
able to send the category_id with the ‘data’ for the CGridView:
The above solution, however, needs the category_id in the columns option of CGridView. If it is removed the filtering on other columns does not work. If it is kept the filtering on other columns work, but the category_id is present in the grid( which is not required) Need a way to hide the category_id column in CGridView or some other solution.