Could any of you explain to me what exactly means the sort/field
and the columns/key
field in the frontend-config.js
?
I’ve read the relevant part of the documentation (Customizable table views), but it’s not explained there, the following snippet is from the docs:
export const customViews = (userId, party, role) => ({
customview1: {
type: "table-view",
title: "Filtered contracts",
source: {
type: "contracts",
filter: [
{
field: "id",
value: "1",
}
],
search: "",
sort: [
{
field: "id",
direction: "ASCENDING"
}
]
},
columns: [
{
key: "id",
title: "Contract ID",
createCell: ({rowData}) => ({
type: "text",
value: rowData.id
}),
sortable: true,
width: 80,
weight: 0,
alignment: "left"
},