Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion samples/grids/grid/binding-nested-data-1/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ export default class Sample extends React.Component<any, any> {
field="Employees"
header="Employees"
bodyTemplate={this.webGridNestedDataCellTemplate}
width="20%">
width="20%"
minWidth="275px">
</IgrColumn>
<IgrColumn
field="City"
Expand Down
14 changes: 7 additions & 7 deletions samples/grids/tree-grid/column-moving-styles/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@ const mods: any[] = [
mods.forEach((m) => m.register());

export default class Sample extends React.Component<any, any> {
private treeGrid: IgrTreeGrid
private treeGridRef(r: IgrTreeGrid) {
this.treeGrid = r;
private grid: IgrTreeGrid
private gridRef(r: IgrTreeGrid) {
this.grid = r;
this.setState({});
}

constructor(props: any) {
super(props);

this.treeGridRef = this.treeGridRef.bind(this);
this.gridRef = this.gridRef.bind(this);
}

public render(): JSX.Element {
Expand All @@ -35,8 +35,8 @@ export default class Sample extends React.Component<any, any> {
<div className="container fill">
<IgrTreeGrid
autoGenerate={false}
ref={this.treeGridRef}
id="treeGrid"
ref={this.gridRef}
id="grid"
data={this.employeesFlatDetails}
primaryKey="ID"
foreignKey="ParentID"
Expand Down Expand Up @@ -137,7 +137,7 @@ export default class Sample extends React.Component<any, any> {
}

public toggleColumnPin(field: string) {
var treeGrid = this.treeGrid;
var treeGrid = this.grid;
var col = treeGrid.getColumnByName(field);
col.pinned = !col.pinned;
treeGrid.markForCheck();
Expand Down