Wiki

Articles tagged with "cgridview", sorted by ratingX
Displaying 21-30 of 38 result(s).

Displaying, sorting and filtering HasMany & ManyMany relations in CGridView

Created 8 months ago by yJeroenTutorials8 comments – viewed 16,189 times – ( +11 )
This tutorial gives you multiple options of how to fully implement showing, sorting and filtering related data in gridviews.

Search method of a model for filters when using dates - unixtimestamp in database

Created 2 years ago by MukkeTips1 comment – viewed 14,980 times – ( +10 )
I ran into a problem and on irc we worked it out. Since there is a lack on information on filters in genral i thought i'd start sharing all my findings, might be usefull for other people.

Using filters with CGridView and CArrayDataProvider

Created about a year ago by marcovtwoutHow-tos12 comments – viewed 24,186 times – ( +10 )
Using filters on CGridView with CActiveDataProvider is easy, but with CArrayDataProvider it is a bit tricky.

Change buttons on our CGridView extending yii

Created about a year ago by sensorarioTips4 comments – viewed 13,517 times – ( +9 )
In this tip, I'll help you to change in few second buttons of your CGridView. I hope you like it =).

Limit a CGridView field to some preset length.

Created 2 months ago by le_topHow-tos1 comment – viewed 2,230 times – ( +8 )
Sometimes text inside a gridview column is just too long. That's why I figured out a way to make the column smaller while still providing the information.

Displaying image in a CGridView column.

Created about a year ago by sirin kHow-tos5 comments – viewed 22,426 times – ( +12 / -1 )
This is a simple example of how we can display images in CGridviews.Imagine that you have an image field in your table ie either a location field or a blob type field used to store the images.
tags: CGridView, image

BootProgressColumn - Progress Bar Inside GridView Column compatible with 'bootstrap' extension

Created 10 months ago by LuizTips1 comment – viewed 5,842 times – ( +6 )
A little hint of how to create a progress bar inside the column of the grid, using the 'bootstrap' extension.

CButtonColumn: Use special variable $data for the 'id' in the 'options' of a button

Created 8 months ago by bluezedTutorials4 comments – viewed 6,904 times – ( +6 )
In an application I had a CGridView with a CButtonColumn and for an Ajax-Request I needed to make sure that the IDs of the buttons would not change when the GridView was updated so in effect I wanted to link them to the $data->id. So I tried:

Adding a date range search for CGridView the easy way

Created 2 months ago by mikewalenTips2 comments – viewed 3,569 times – ( +5 )
After a lot of research, everything I found on adding date range searching to a CGridView advanced search form seemed to involve adding two new public variables (e.g. $date_from, $date_to), 'safe' rules for the new variables, and a rather chunky if/elseif/else check in the search() method. This probably isn't a hassle for most, but because many of the tables in my database contain two or three and sometimes four date columns (e.g. date_created, date_modified, date_deleted etc.), it meant I was having to add up to eight public variables, the corresponding safe rules, and modifying the search() criteria for each date attribute. So, I set about creating a better way and I thought I'd share my work with the community.

CGridView keep focus on the control after filtering

Created about a year ago by jayalaHow-tos0 comments – viewed 5,088 times – ( +4 )
You can find the reason why I wrote this article here.
tags: CGridView, filter