AnsweredAssumed Answered

How to create custom filter on contact with accounts_cstm.accounttype_c

Question asked by Gabor Meszaros on Mar 12, 2018
Latest reply on Mar 14, 2018 by Gabor Meszaros

Hi All,

I tried to custom filter on Contact.

I create custom by this way:

1. Create new vardef by creating this file custom/Extension/modules/Contacts/Ext/Vardefs/accountType.php with:

$dictionary['Contact']['fields']['account_type'] = array(
    'name' => 'account_type',
    'source' => 'non-db',
    'massupdate' => false,
    'type' => 'enum',
    'options' => 'account_type_dom'

2. Add below code to file custom/modules/Contacts/clients/base/filters/default/default.php

'account_type' => array(
              'dbFields' => array(
                  0 => 'accounts_cstm.accounttype_c',
              'type' => 'enum',
              'vname' => 'LBL_ACCOUNTTYPE',

After Rebuild, I got the below error(see image). I really want to filter on accounts_cstm.accounttype_c (I try with accounts.account_type, it's work)