I have created a custom module and related it to contacts. This custom module appears as a contacts subpanel. I must also modify the columns of the subpanel. For this I have created the file
public/legacy/custom/modules/<custom_module>/metadata/subpanels/default.php
Content
<?php
if (!defined('sugarEntry') || !sugarEntry) {
die('Not A Valid Entry Point');
}
$subpanel_layout = [
'list_fields' => [
'field_a' => array(
'vname' => 'LBL_FIELD_A_C',
'widget_class' => 'SubPanelDetailViewLink',
'module' => 'Contacts',
'width' => '25%',
),
'field_b' => array(
'vname' => 'LBL_FIELD_B_C',
'widget_class' => 'SubPanelDetailViewLink',
'module' => 'Contacts',
'width' => '25%',
),
'date_sent_c' => array(
'vname' => 'LBL_DATE_SENT_C',
'widget_class' => 'SubPanelDetailViewLink',
'module' => 'Contacts',
'width' => '25%',
),
]
];
``
This is going well. But I must show data obtained from a SQL query in a new column. Is it possible to do it this way?
Thanks for your suggestions