Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
145524 | Jun 26,2019 03:24 PM UTC | Jun 27,2019 08:46 AM UTC | React - EJ 2 | 1 |
![]() |
Tags: Grid |
export class Default extends SampleBase {
show() {
var gridInst = document.getElementsByClassName("e-grid")[0].ej2_instances[0];
var data = gridInst.getPersistData(); // here you can get the persisted data
console.log(JSON.parse(data));
}
render() {
this.show = this.show.bind(this);
return (<div className='control-pane'>
<div className='control-section'>
<ButtonComponent cssClass= 'e-flat' onClick= { this.show }>Show</ButtonComponent>
<GridComponent dataSource={orderDetails} allowFiltering={true} allowPaging={true} enablePersistence={true} ref={g => this.grid = g} height='350'>
<ColumnsDirective>
<ColumnDirective field='OrderID' headerText='Order ID' width='120' textAlign='Right'></ColumnDirective>
. . . . .
</ColumnsDirective>
<Inject services={[Filter, Page]} />
</GridComponent>
</div>
</div>);
}
}
render(<Default />, document.getElementById('sample')); |
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.