Ggridview check box list

I am new in yii2. I generated a search with gridwiew! But I want to add to this search some options, when you have lets say products, you see list of products from databse.

I would like to add check box for each of them, so clicking on 2 country to see all rows with these 2 countries.

I solve it adding this manually, can someone help me to solve it with gridview, because I want to learn to use it in this way.

Any tips, suggestion will be great for me. I will attach the PrintScreen like example what I want to do.

Tx in advance!

[color="#006400"]/* Moved from "Tips" to "General Discussions" */[/color]

Do you want to use a checkbox list in the filter row of the gridview?

Would you please make your question clearer?

No, It is a dropdown list, witch echo data from db, then at this list user have possibility to chose more then one value with check box.

I see.

But, sorry, I don’t have any idea about that. :(


First of all, “dropdown with checkbox” is something very special. You have to implement it before you try to use it in GridView. I tried to google it and found some attempts to implement it. I don’t know which one to choose.

Once you’ve got one that satisfies your needs, then you have to write some additional code to integrate it with GridView, probably extending DataColumn.

It doesn’t look very easy to me.

Tx! If I will find a solution I will try add it here!