Hello guys,
I have table data fetch via API for hubspot deals, my problem here is when displaying the table without filling “Deal owner” everything in the table rows will break. See image attached but if the deal has owner everything on the table row shows perfectly.
Is it possible to add a if else condition on the code table display if the deal has owner it will display the owner and if no owner being inputed. it would just display text “No owner” so the rest data will show. Here is the JS code that calls the data and displayed on the table. Here’s the code I tried to achieved feel free to give me some idea what may cause the code below is not working ![]()
if ( getOwnerDetails.ownerId === null ) {
cell = row.insertCell()
cell.innerHTML = 'No data'
} else {
cell = row.insertCell()
cell.innerHTML = getOwnerDetails(ownersDetails, element['properties']['hubspot_owner_id'])
}
Hope someone can give me some help on this one what’s the cause . Thank you very much!
