Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
147985 | Sep 30,2019 08:04 PM UTC | Oct 4,2019 03:48 AM UTC | Angular - EJ 2 | 3 |
![]() |
Tags: Grid |
App.component.html
<div class="control-section">
<ejs-grid #grid [dataSource]='data' [query]="query" [pageSettings]='pageSettings'>
<e-columns>
<e-column field='UserName' headerText='Customer ID' width='160'></e-column>
<e-column field='FirstName' width='120' textAlign='Right'></e-column>
<e-column field='LastName' width='150' ></e-column>
</e-columns>
</ejs-grid>
</div>
|
App.component.ts
const SERVICE_URI: string = 'https://services.odata.org/V4/(S(0j5uiuuhvaybfuc2llcclf3g))/TripPinServiceRW/People';
@Component({
selector: 'app-root',
templateUrl: 'app.component.html'
})
export class AppComponent {
public data: DataManager;
public pageSettings: Object;
public query:any
@ViewChild('grid',{static: true})
public grid: GridComponent;
ngOnInit(): void {
this.data= new DataManager({ url: SERVICE_URI, adaptor: new ODataV4Adaptor })
this.query = new Query().expand('Trips');
}
}
|
this.query = new Query().expand('Products($expand=Customer)'); |
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.