detailsViewSettings: {
columns: [
{
field: "name",
headerText: "Name",
minWidth: 120,
template: '<span class="e-fe-text">${name}</span>',
customAttributes: { class: "e-fe-grid-name" },
},
{
field: "date",
headerText: "Date Created",
type: "dateTime",
minWidth: 120,
width: "190",
template: "${dateCreated}",
},
{
field: "size",
headerText: "Size",
minWidth: 80,
width: "90",
template: "${size}",
},
],
}, |
detailsViewSettings: {
columns: [
{
field: "name",
headerText: "Name",
minWidth: 120,
template: '<span class="e-fe-text">${name}</span>',
customAttributes: { class: "e-fe-grid-name" },
},
{
field: '_fm_modified', headerText: 'Date Modified', type: 'dateTime',
format: 'MMMM d, yyyy', minWidth: 120, width: '190'
},
{
field: 'size', headerText: 'Size', minWidth: 80, width: '90',
template: '<span class="e-fe-size">${size}</span>',
},
],
|
fetchDate: function (date) {
//Returns the date in mentioned format
return moment(new Date(date)).format("MMMM D, YYYY");
},
fileLoad: function (args) {
if (args.module === "DetailsView") {
//Method call to format the date
var date = this.fetchDate(args.fileDetails.dateModified);
var cell = args.element.querySelector('[aria-colindex="' + 3 + '"]');
//Append the date inside column
cell.innerText = date;
}
}, |