Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
141920 | Jan 10,2019 01:09 PM UTC | Jan 21,2019 07:25 AM UTC | Angular - EJ 2 | 10 |
![]() |
Tags: Grid |
<ejs-grid #grid [dataSource]='data | async' .... (dataSourceChanged)= 'dataSourceChanged($event)'>
...
</ejs-grid>
export class AsyncPipeComponent {
...
@ViewChild('grid')
public grid: GridComponent
....
public dataSourceChanged(state: DataStateChangeEventArgs): void {
//On error use closeEdit method.
this.grid.closeEdit();
}
}
|
<ejs-grid #grid [dataSource]='data | async' [editSettings]='editSettings' (actionComplete)="actionComplete($event)" [toolbar]='toolbar'
(dataSourceChanged)='dataSourceChanged($event)' (dataStateChange)= 'dataStateChange($event)'>
. . . . .
</ejs-grid>
. . . . .
actionComplete(args) {
if ((args.requestType === 'beginEdit' || args.requestType === 'add')) {
let dialog = args.dialog;
// you can customize the dialog as per your requirement
dialog.height = "300px";
dialog.width = "500px"
}
}
|
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.