Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
147649 | Sep 18,2019 03:18 PM UTC | Jun 23,2020 09:30 AM UTC | Angular - EJ 2 | 9 |
![]() |
Tags: Grid |
<e-column field="studyDate" headerText="Erstellung" type="date"></e-column>I get "Mon Aug 26 2019 02:00:00 GMT+0200 (Mitteleuropäische Sommerzeit)", so the grid parses the date correctly.
<e-column field="studyDate" headerText="Erstellung" [format]="{type: 'date', format: 'dd.MM.yyyy'}" ></e-column>
public ngOnInit(): void {
localdata[0].OrderDate = new Date(localdata[0].OrderDate);
this.gridData = localdata;
this.pageSettings = { pageCount: 5 };
} |
[app.component.html]
<ejs-grid #grid [dataSource]='data' allowPaging='true' [pageSettings]='pageSettings'>
<e-columns>
<e-column field='OrderID' headerText='Order ID' width='120' textAlign='Right'></e-column>
<e-column field='CustomerID' headerText='Customer Name' width='150'></e-column>
<e-column field='OrderDate' headerText='Order Date' width='130' type="date" [format]="orderDateFormat" textAlign='Right'></e-column>
<e-column field='Freight' headerText='Freight' width='120' format='C2' textAlign='Right'></e-column>
<e-column field='ShipCountry' headerText='Ship Country' width='150'></e-column>
</e-columns>
</ejs-grid>
[app.component.ts]
public orderDateFormat: any = {type:"date", format:"dd.MM.yyyy"};
|
Hi Michael,Thanks for your update.We are happy to hear your requirement has been resolved and you are good to go.Regards,Seeni Sakthi Kumar S
<e-column field='OrderDate' headerText='Order Date' width='150' [format]='dateFormatOptions' textAlign='Right'></e-column>
|
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.