this.columnDefinitions = [
{
id: 'edit',
field: 'id',
excludeFromColumnPicker: true,
excludeFromGridMenu: true,
excludeFromHeaderMenu: true,
formatter: Formatters.editIcon,
minWidth: 30,
maxWidth: 30,
onCellClick: (e: Event, args: OnEventArgs) => {
this.router.navigate(['/transaction/transaction-detail/' + args.dataContext.id]);
}
},
{ id: 'cin', field: 'customer.cin', name: 'CIN', filterable: true, sortable: true, formatter: Formatters.complexObject },
{ id: 'branch', field: 'branch.name', name: 'Branch', filterable: true, sortable: true, formatter: Formatters.complexObject },
{ id: 'valueDate', field: 'valueDate', name: 'Transaction Date ', dateFormat: 'DD-MM-YYYY'},
{ id: 'amount', field: 'amount', name: 'Amount', sortable: true, maxWidth: 200, type: FieldType.number, filter: { model: Filters.inputNumber } },
];
<div class="card-body">
<div class="form-group row" id="grid-container">
<angular-slickgrid gridId="transactionGrid" [columnDefinitions]="columnDefinitions"
[gridOptions]="gridOptions" [dataset]="dataset"
(onAngularGridCreated)="angularGridReady($event)">
</angular-slickgrid>
</div>
</div>
I need to change the date format to DD-MM-YYYY OR DD/MM/YYYY ( remove time)
How to do that in angular slickgrid
Now showng like below...date coming in date format..is we can use pipe to convert date as string
question from:
https://stackoverflow.com/questions/65650139/angular-slickgrid-date-format-change-only-display-in-grid 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…