Changing column names in List - Simple widget
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2023 11:16 AM
I am building a experience and want to display a list of records. Selecting the "List - Simple" widget, I can add columns, but two of them are references to customer_account and customer_contact, both of which have a "name" property.
How can I change the "Same" columns to something like "Customer" and "User", respectively?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2023 12:46 PM
Hi @Mike Hashemi ,
Hope You are doing great.
Modify the Widget Instance:
- Access the properties of the "List - Simple" widget instance.
- Look for the properties related to customer_account and customer_contact references.
Customize the Column Labels:
- Find the property responsible for defining the column labels, usually named "columns" or something similar.
- The "columns" property is typically an array that contains objects defining each column.
- Locate the objects representing the customer_account and customer_contact columns.
Update the Column Labels:
- Within the objects representing the customer_account and customer_contact columns, find the property responsible for defining the column label, often named "label" or "displayName".
- Modify the value of the "label" property to the desired label, such as "Customer" for customer_account and "User" for customer_contact.
please find below code for reference.
{
"widget": {
"instance": {
"columns": [
{
"label": "Customer", // Modify this label for customer_account
"field": "customer_account"
},
{
"label": "User", // Modify this label for customer_contact
"field": "customer_contact"
},
// Other columns...
]
}
}
}
Regards,
Riya Verma
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2023 02:45 PM
I do not see any reference to customer_account or customer_contact (other than what is the screenshot I shared). The rest of the properties are:
What am I missing?