Installing a custom package through Module Loader causes labels to dissapear

Hi All

I have a CRM instance that was originally deployed as SugarCRM 6.5 CE and I upgraded to SuiteCRM 7.1. I have found that installing modules through the Module Loader is a bit buggy. The labels seem to disappear after installing the package.

The problem only seems to occur in the contacts module. If I change the package manifest to install the field on to the leads module It seems to work fine. Is there some way I can step through and debug why this is happening and fix it? What classes would I be looking into?


# manifest.php
<?php
    $manifest = array(
        'acceptable_sugar_flavors' => array('CE','PRO','CORP','ENT','ULT'),
        'acceptable_sugar_versions' => array(
            'exact_matches' => array(),
            'regex_matches' => array('[6-7]\\.[0-9]\\.[0-9]'),
        ),
        'author' => 'ACC Limited',
        'description' => 'Custom fields',
        'icon' => '',
        'is_uninstallable' => true,
        'name' => 'Custom Fields B',
        'published_date' => date('Y-m-d H-i-s'),
        'type' => 'module',
        'version' => '1.4.5 B',
    );

    $installdefs = array(
        'id' => 'IB4T_MKT_FLDS_B',
        'language'=> array (    
            array(
                'from' => '<basepath>/Files/Language/Contacts/en_us.custom.lang.php',
                'to_module' => 'Contacts',
                'language' => 'en_us'
            ),
        ),
        'custom_fields' => array (
            array(
                'name' => 'current_customer_c',
                'label' => 'LBL_CURRENT_CUSTOMER2',
                'type' => 'bool',
                'module' => 'Contacts',
                'audited' => true, 
                'mass_update' => true, 
                'duplicate_merge' => false,
                'reportable' => true, 
                'importable' => 'true',
            ),
        ),
    );
?>

# en_us.custom.lang.php
<?php

$mod_strings['LBL_CURRENT_CUSTOMER2'] = 'Current Customer 2';

Hi sone,
This is commonly a permissions issue, but just to rule it out, Run a Quick Repair & Rebuild and check if the labels have returned.

If not, What is the Environment of the SuiteCRM Instance’s host? Is it Linux/Windows based?

Also, If you find the config.php file in your SuiteCRM instance, look for the array:

 'default_permissions' => 
  array (
    'dir_mode' => ,
    'file_mode' => ,
    'user' => ' ',
    'group' => ' ',
  ),

What settings do you have for these?


220   'default_permissions' =>
221   array (
222     'dir_mode' => 1528,
223     'file_mode' => 432,
224     'user' => '',
225     'group' => '',
226   ),

Hi John

Are these values correct? I’ve made sure to chmod everything 775 this time round but problem still there. This only seems to be affecting the Contacts module. I’ve tested installing fields in Accounts and Leads and they work as expected.

I’m running a CentOS 6.5 on most of our servers.

Hi Sone,

For dir_mode and file_mode we normally recommend:

‘dir_mode’ => 1517,
‘file_mode’ => 420,

Your user and group may be different depending on your distribution, but I think for CentOS it is:

‘user’ => ‘apache’,
‘group’ => ‘apache’,

If you then run a Quick Repair & Rebuild again, clear your browser’s cache and CTRL+F5, do the labels return to normal?

Hi John

I’ve tried your values and it does not seem to fix the issue.

I’ve currently got
‘default_permissions’ =>
array (
‘dir_mode’ => 1528,
‘file_mode’ => 432,
‘user’ => ‘’,
‘group’ => ‘’,
),

Not sure user and groups are needed as files created seem to be owned by apache anyway.

Hi Sone,

if you’re sure that setting dir_mode to 1517, file_mode to 420 and resetting permissions on your instance did not help;

Are you able to change these Labels through studio? You may just be able to navigate to Admin > Studio > (module name) > Labels. Here you should be able to change the Labels to whatever you’d like. Keep in mind that It may take a few saves for the changes to take effect.

If this doesn’t help, maybe this thread will have something of assistance: https://suitecrm.com/forum/suitecrm-7-0-discussion/2562-renaming-relationship-label