What I'm trying to do in Angular ui-grid seems pretty common, but I'm having trouble finding anything that describes a solution.
I have a table. Like many tables the first row is really a "row header".
Now what specifically do I mean by that:
- Like column headers, the values are always the same. They are not "data"
- Like column headers, they are styled differently than non-header data cells to indicate that they are not "data".
- You should not be able to "sort" nor "remove" the header row
- Ideally, the column for the row headers is "frozen" in that it doesn't scroll
It perhaps is worth mentioning that the row header labels COME from the data as in:
{
rowHeader : "Fixed Rate",
TenYear: .02,
TwentyYear: .03
},
{
rowHeader : "Variable Rate",
TenYear: .04,
TwentyYear: .05
}
So what I'm looking for in the above example, is a table where the first column has row headers of "Fixed Rate" and "Variable Rate". The styling of that column should "look like" a header cell rather than a data cell.
Now I know that some of these things like "frezeing" and turning off sorting are available via columnDefs in gridOptions. But what I'm unclear of is if there's a way to just declare that the first column is a header, and I just get all of these things.
This seems to be a common table paradigm.