ASP.net
Awesome
Learn
Forum
Buy
Demos
Sign In
☾
☀
Switch to
Dark
Light
Mode
this site works best with javascript enabled
Ask Question
Awesome Grid set cell style
Title:
B
I
{code}
?
This is my grid, how can you see last column is for the action (I would like to put a dropdown menu button). but the menu is trigged by the cell. I have debugged and the cause is this .. .awe-row td, { overflow: hidden;} to resolve the problem I have to set (only on the action column) <td style="overflow: visible;"> How can I do this ? Thank you Mark view: @(Html.Awe().Grid("TeacherGrid") .Url(Url.Action("GetItems", "TeacherGrid")) .Parent("search", "search") .Persistence(Persistence.Session) .Selectable(SelectionType.Multiple) .PageSize(FujiyBlog.Web.Models.Settings.SettingRepository.GridRowsPerPage) .Columns( new Column { Name = "Id", Width = 60, Header = "ID" }, new Column { Name = "FirstName", Header = "FirstName" }, new Column { Name = "LastName", Header = "LastName" }, new Column { ClientFormat = ".Actions", Width = 120} )) controller: public virtual ActionResult GetItems(GridParams g, string search) { var list = db.Teachers.Where(o => o.IsDeleted == false); if (!string.IsNullOrEmpty(search)) list = list.Where(o => o.UserName.StartsWith(search)); list = list.OrderBy(o => o.Name); return Json(new GridModelBuilder<Teacher>(list.AsQueryable(), g) { Map = teacher => new { teacher.Id, teacher.FirstName, teacher.LastName, Actions = this.RenderView("Actions/GridActions", new FujiyBlog.Web.ViewModels.ActionBtn { Id = teacher.Id, IsDeleted = teacher.IsDeleted, Controller = "Teacher" }) } }.Build()); } GridActions view <div class="btn-group open"> <button type="button" class="btn btn-warning dropdown-toggle btn-flat btn-xs" data-toggle="dropdown"><span class="caret"></span></button> <ul class="dropdown-menu"> <li><a href="#" onclick="FormRecord('Teacher','Details', 293);" title="Show record"><i class="fa fa-file"></i> Details</a></li> <li><a href="#" onclick="FormRecord('Teacher','Edit', 293);" title="Edit record"><i class="fa fa-edit"></i> Edit</a></li> </ul> </div>
Save Changes
Cancel
mtugnoli
asked at 28 Nov 2014
Answers
B
I
{code}
?
not sure why you need that, maybe increasing the column width should be enough, but anyway if you want to add a style attribute to the cell you can do this: ClientFormat = "<td style='overflow:visible'> .Actions </td>"
Save Changes
Cancel
Omu
answered at 28 Nov 2014
Yes !!!, now is OK
at 28 Nov 2014
mtugnoli
please
Sign In
to leave an answer
By accessing this site, you agree to store cookies on your device and disclose information in accordance with our
cookie policy
and
privacy policy
.
OK