src/Model/Customer.php
protected function compileLabel($aData)
    {
        if (!empty($aData['organisation'])) {
            return trim($aData['organisation']);
        } else {
            return implode(
                ' ',
                array_filter([
                    !empty($aData['first_name']) ? trim($aData['first_name']) : '',
                    !empty($aData['last_name']) ? trim($aData['last_name']) : '',
                ])
            );
        }
    }
protected function compileLabel($aData)
    {
        if (!empty($aData['organisation'])) {
            return trim($aData['organisation']);
        } else {
            return implode(
                ' ',
                array_filter([
                    !empty($aData['first_name']) ? trim($aData['first_name']) : '',
                    !empty($aData['last_name']) ? trim($aData['last_name']) : '',
                ])
            );
        }
    }
protected function compileLabel ( $ aData ) { if ( ! empty ( $ aData [ 'organisation' ] ) ) { return trim ( $ aData [ 'organisation' ] ) ; } else { return implode ( ' ' , array_filter ( [ ! empty ( $ aData [ 'first_name' ] ) ? trim ( $ aData [ 'first_name' ] ) : '' , ! empty ( $ aData [ 'last_name' ] ) ? trim ( $ aData [ 'last_name' ] ) : '' , ] ) ) ; } }
Compile the customer label

@param  array $aData The data passed to create() or update()

@return string
Compile the customer label