📣 We're Hiring!

Global search shows all records from module

Hello

I have some custom modules and just see that two of them just shown all their records in the result page of the Global search. Whatever I try to search those modules it showed all records…

What do those modules contain? There is nothing interesting. It’s just a Basic template and searches should display results by only one filed = Name
Logs haven’t any error and debug log shown one interesting thing.
There is fully search queries to all my module except for those two (debug log just haven’t any query information for those two modules)

Please can you leave any suggestions for me?
Some time ago everything works fine and I didn’t do any configuration change (no Updated, no changed LAMP version…)

What search settings have you enabled? Is AOD disabled or enabled? Are you scheduler jobs all working? (AOD requires your cron jobs to be working).

no, it’s use just basic search.
AOD is disable

Let’s have a look at the SearchFields.php file for the custom module causing an issue. It maybe perhaps permissions issue and that file isn’t saving correctly.

I have already set www-data with 777 right for testing and it’s nothing effect

This for the SearchFields.php? What does this contain may I ask?

a set this right for all my suitecrm directory

in my modules/people/SearchFields.php I have
<?php
if (!defined(‘sugarEntry’) || !sugarEntry) {
die(‘Not A Valid Entry Point’);
}

$module_name = 'people';
$searchFields[$module_name] = array(
    'name' => array('query_type' => 'default'),
    'current_user_only' => array(
        'query_type' => 'default',
        'db_field' => array('assigned_user_id'),
        'my_items' => true,
        'vname' => 'LBL_CURRENT_USER_FILTER',
        'type' => 'bool'
    ),
    'assigned_user_id' => array('query_type' => 'default'),

    //Range Search Support
    'range_date_entered' => array('query_type' => 'default', 'enable_range_search' => true, 'is_date_field' => true),
    'start_range_date_entered' => array(
        'query_type' => 'default',
        'enable_range_search' => true,
        'is_date_field' => true
    ),
    'end_range_date_entered' => array(
        'query_type' => 'default',
        'enable_range_search' => true,
        'is_date_field' => true
    ),
    'range_date_modified' => array('query_type' => 'default', 'enable_range_search' => true, 'is_date_field' => true),
    'start_range_date_modified' => array(
        'query_type' => 'default',
        'enable_range_search' => true,
        'is_date_field' => true
    ),
    'end_range_date_modified' => array(
        'query_type' => 'default',
        'enable_range_search' => true,
        'is_date_field' => true
    ),
    //Range Search Support
);

and my custom/modules/people/SearchFields.php I have

<?php
// created: 2021-04-02 13:18:54
$searchFields['people'] = array (
    'name' =>
        array (
            'query_type' => 'default',
        ),
    'current_user_only' =>
        array (
            'query_type' => 'default',
            'db_field' =>
                array (
                    0 => 'assigned_user_id',
                ),
            'my_items' => true,
            'vname' => 'LBL_CURRENT_USER_FILTER',
            'type' => 'bool',
        ),
    'assigned_user_id' =>
        array (
            'query_type' => 'default',
        ),
    'range_date_entered' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
    'start_range_date_entered' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
    'end_range_date_entered' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
    'range_date_modified' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
    'start_range_date_modified' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
    'end_range_date_modified' =>
        array (
            'query_type' => 'default',
            'enable_range_search' => true,
            'is_date_field' => true,
        ),
);

UPD
Please Note I have custom module named “people” (I created this and deleted prefix, sure it was working and right now I have another unprefixed custom modules that haven’t any problem with search)