1 vote
closed
GridRenderer should allow for body start and end

Description

 
Please add support for start and end of the item set in the GridRenderer, so that the HtmlTableGridRenderer can render the <tbody> tag.

I was able to implement this by modifying the GridRenderer.RenderItems() method like so:

protected virtual void RenderItems()
{
RenderBodyStart();

bool isAlternate = false;
foreach(var item in DataSource)
{
RenderItem(new GridRowViewData<T>(item, isAlternate));
isAlternate = !isAlternate;
}

RenderBodyEnd();
}

And making the following additions:

To GridRenderer:

protected abstract void RenderBodyStart();
protected abstract void RenderBodyEnd();

To HtmlTableGridRenderer:

protected override void RenderBodyStart()
{
RenderText("<tbody>");
}

protected override void RenderBodyEnd()
{
RenderText("</tbody>");
}

File Attachments


No files are attached


Closed Mar 29 2009 at 12:53 PM  by JeremyS
Fixed in revision 920

Comments

most recent at top (show oldest at top)
paulwhit wrote Mar 28 2009 at 1:34 AM
This was important to get the grid working as a jQuery datatable.

Updating...
© 2006-2010 Microsoft | About CodePlex | Privacy Statement | Terms of Use | Code of Conduct | Advertise With Us | Version 2010.1.12.16187