Suitecrm: Dynamicly created labels, potentially removed by mistake

Created on 20 Sep 2017  路  16Comments  路  Source: salesagility/SuiteCRM

After an automated process removed all labels that weren't referenced _directly_ in the codebase, we realized that many labels are referenced dynamically by concatenating bits of string and _then_ using that as a label. This means that many labels were incorrectly removed and should be put back. But it's not easy to understand which ones. This Issue is for organizing that work.

Ok, @horus68 and @Dillon-Brown, I made a search over the entire codebase with a really weird grep to find lines that:

  • include the string LBL
  • either include the string _' or the string '_, to look for places where strings are being composed from parts

That gave me 135 lines. I cleaned that list up manually (hard work that strained my poor eyes) to the list below which has 67 lines, and which I sub-divided into logical groups we can handle one by one.

Each group will be labeled in three stages:
馃摍 needs list of strings
馃摌 strings listed, needs PR to put them back
馃摋 done

I will keep editing this initial post to update the statuses on the list.

GROUP A - 馃摍 needs list of strings

modules/ModuleBuilder/javascript/ModuleBuilder.js:288:              ModuleBuilder.history.popup_window.setHeader( module_str + ' : ' + SUGAR.language.get('ModuleBuilder', 'LBL_' + layout.toUpperCase()) + SUGAR.language.get('ModuleBuilder', 'LBL_HISTORY_TITLE'));
modules/ModuleBuilder/javascript/studio2.js:388:        var panelLabel = 'lbl_' + view +  '_panel' + panelNumber;
modules/ModuleBuilder/javascript/studio2PanelDD.js:124:                 var panelLabelNoID = 'lbl_' + view +  '_panel';
modules/ModuleBuilder/views/view.searchview.php:109:                $searchLabel = 'LBL_' . strtoupper ( $this->editLayout) ;
modules/ModuleBuilder/views/view.module.php:78:            $translated_type[$type]=translate('LBL_TYPE_'.strtoupper($type),'ModuleBuilder');
modules/ModuleBuilder/MB/MBLanguage.php:187:                'LBL_'.strtoupper($this->key_name).'_SUBPANEL_TITLE'=>$this->label,
modules/ModuleBuilder/MB/MBField.php:64:        if(empty($this->vname))$this->vname = 'LBL_' . strtoupper($this->name);

GROUP B - 馃摌 strings listed, needs PR to put them back

modules/ModuleBuilder/parsers/relationships/ActivitiesRelationship.php:128:                'system_label' => 'LBL_' . strtoupper($this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()) . '_TITLE',
modules/ModuleBuilder/parsers/relationships/ActivitiesRelationship.php:133:                'system_label' => 'LBL_' . strtoupper($this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel()) . '_TITLE',
modules/ModuleBuilder/parsers/relationships/OneToOneRelationship.php:98:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel() ) . '_TITLE' ,
modules/ModuleBuilder/parsers/relationships/OneToOneRelationship.php:102:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()   ) . '_TITLE'  ,
modules/ModuleBuilder/parsers/relationships/OneToOneRelationship.php:111:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()   ) . '_TITLE' ) ;
modules/ModuleBuilder/parsers/relationships/OneToOneRelationship.php:113:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel() ) . '_TITLE' ) ;
modules/ModuleBuilder/parsers/relationships/OneToManyRelationship.php:121:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel() ) . '_TITLE',
modules/ModuleBuilder/parsers/relationships/OneToManyRelationship.php:127:                'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()  ) . '_TITLE');
modules/ModuleBuilder/parsers/relationships/OneToManyRelationship.php:133:                'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()  ) . '_TITLE');
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:240:               'system_label' => isset($rightSysLabel)?$rightSysLabel : 'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel() ) . '_TITLE' ,
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:245:               'system_label' =>  isset($leftSysLabel)?$leftSysLabel :'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel() ) . '_TITLE' ,
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:310:           $subpanelDefinition [ 'title_key' ] = 'LBL_' . strtoupper ( $relationshipName . '_FROM_' . $titleKeyName ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:312:           $subpanelDefinition [ 'title_key' ] = 'LBL_' . strtoupper ( $relationshipName . '_FROM_' . $sourceModule ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:393:           $vardef [ 'vname' ] = 'LBL_' . strtoupper ( $relationshipName . '_FROM_' . $vnameLabel ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:395:           $vardef [ 'vname' ] = 'LBL_' . strtoupper ( $relationshipName . '_FROM_' . $sourceModule ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:698:           $title_key = 'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $titleKeyName ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/AbstractRelationship.php:700:           $title_key = 'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $sourceModule ) . '_TITLE' ;
modules/ModuleBuilder/parsers/relationships/ManyToManyRelationship.php:93:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getLeftModuleSystemLabel() ) . '_TITLE' ) ;
modules/ModuleBuilder/parsers/relationships/ManyToManyRelationship.php:95:            'LBL_' . strtoupper ( $this->relationship_name . '_FROM_' . $this->getRightModuleSystemLabel()  ) . '_TITLE' ) ;

GROUP C - 馃摌 strings listed, needs PR to put them back

modules/Spots/Spots.php:266:                $labelPrefix = 'LBL_AN_ACCOUNTS_';
modules/Spots/Spots.php:269:                $labelPrefix = 'LBL_AN_LEADS_';
modules/Spots/Spots.php:272:                $labelPrefix = 'LBL_AN_SALES_';
modules/Spots/Spots.php:275:                $labelPrefix = 'LBL_AN_SERVICE_';
modules/Spots/Spots.php:278:                $labelPrefix = 'LBL_AN_ACTIVITIES_';
modules/Spots/Spots.php:281:                $labelPrefix = 'LBL_AN_MARKETING_';
modules/Spots/Spots.php:287:                $labelPrefix = 'LBL_AN_QUOTES_';

GROUP D - 馃摌 strings listed, needs PR to put them back

modules/Import/Importer.php:492:                    $this->importSource->writeError($mod_strings['LBL_ERROR_INVALID_'.strtoupper($fieldDef['type'])],$fieldTranslated,$rowValue,$focus);
modules/Import/views/view.step3.php:271:                        && isset($mod_strings['LBL_IMPORT_FIELDDEF_' . strtoupper($properties['type'])]) )
modules/Import/views/view.step3.php:272:                    $fieldtype = ' [' . $mod_strings['LBL_IMPORT_FIELDDEF_' . strtoupper($properties['type'])] . '] ';
modules/Import/views/view.step3.php:348:                            && isset($mod_strings['LBL_IMPORT_FIELDDEF_' . strtoupper($properties['type'])]) )
modules/Import/views/view.step3.php:349:                        $fieldtype = ' [' . $mod_strings['LBL_IMPORT_FIELDDEF_' . strtoupper($properties['type'])] . '] ';

GROUP E - 馃摌 strings listed, needs PR to put them back

modules/Import/views/view.step3.php:228:                if (!empty($moduleStrings['LBL_EXPORT_'.strtoupper($fieldname)]) )
modules/Import/views/view.step3.php:230:                     $displayname = str_replace(":","", $moduleStrings['LBL_EXPORT_'.strtoupper($fieldname)] );

include/export_utils.php:827:     if (!empty($mod_strings['LBL_EXPORT_'.strtoupper($field_db_name)])){
include/export_utils.php:829:         $fieldLabel = $mod_strings['LBL_EXPORT_'.strtoupper($field_db_name)];
include/export_utils.php:833:     elseif (!empty($app_strings['LBL_EXPORT_'.strtoupper($field_db_name)])){
include/export_utils.php:835:         $fieldLabel = $app_strings['LBL_EXPORT_'.strtoupper($field_db_name)];
include/export_utils.php:846:     elseif (!empty($mod_strings['LBL_'.strtoupper($field_db_name)])){
include/export_utils.php:847:         $fieldLabel = $mod_strings['LBL_'.strtoupper($field_db_name)];
include/export_utils.php:850:     elseif (!empty($app_strings['LBL_'.strtoupper($field_db_name)])){
include/export_utils.php:851:         $fieldLabel = $app_strings['LBL_'.strtoupper($field_db_name)];

GROUP F - 馃摋 strings listed, PR's merged, done.

modules/Schedulers/Scheduler.php:1062:              self::$job_strings['function::' . $v] = $mod_strings['LBL_'.strtoupper($v)];
modules/Schedulers/EditView.php:159:        $job_function .= ">".$mod_strings['LBL_'.strtoupper($function)]."</option>";

GROUP G - 馃摍 needs list of strings

modules/AOW_Actions/actionLines.php:67:            $app_list_actions[$action_value] = translate('LBL_'.strtoupper($action_value),'AOW_Actions');
modules/AOW_Actions/actionLines.php:109:            $html .= "<tr><td>". $action_name->action_order ."</td><td>".$action_name->name."</td><td>". translate('LBL_'.strtoupper($action_name->action),'AOW_Actions')."</td></tr>";

GROUP X - not really a group, just loose items - 馃摍馃摍馃摍 needs several lists of strings

modules/Configurator/LogView.php:68:<input type='button' onclick='document.logview.doaction.value="next";document.logview.submit()' name='next' value='{$mod_strings['LBL_NEXT_']}'>
modules/Configurator/language/en_us.lang.php:186:    'LBL_NEXT_' => 'Next>>',
modules/Campaigns/language/en_us.lang.php:204:  'LBL_EDIT_OPT_OUT_'=>'Opt-out Link?',
modules/SugarFeed/Dashlets/SugarFeedDashlet/SugarFeedDashlet.php:574:            $linkTypes[$key] = translate('LBL_LINK_TYPE_'.$value,'SugarFeed');
modules/EAPM/CheckLogins.php:76:                $translateKey = 'LBL_EXTAPI_'.strtoupper($apiName);
modules/DynamicFields/templates/Fields/TemplateAddress.php:57:            $systemLabel = strtoupper( "LBL_" . $this->name . '_' . $addressFieldName );
modules/Emails/EmailUI.php:469:         if(strpos($k, 'LBL_EMAIL_') !== false) {
modules/Emails/javascript/EmailUI.js:1828:                text:   app_strings['LBL_EMAIL_QC_' + module.toUpperCase()],
modules/AOS_PDF_Templates/views/view.edit.php:53:                    $value = $mod_strings['LBL_'.strtoupper($value)];
modules/Connectors/controller.php:715:                      'label' => 'LBL_' . strtoupper($field_name),
include/InlineEditing/inlineEditing.js:252:    message_field = 'LBL_' + field.toUpperCase();
include/SugarFields/Parsers/Rules/AddressRule.php:77:                  $panels[$name][$rowCount][$key]['label'] = 'LBL_' . strtoupper($match[1]) . '_ADDRESS';
modules/Studio/TabGroups/TabGroupHelper.php:91:         $labelID = (!empty($params['tablabelid_' . $index]))?$params['tablabelid_' . $index]: 'LBL_GROUPTAB' . $count . '_'. time();

These are the ones that need to be inspected more closely to see if they are creating dynamic label names that we might have excluded. This shouldn't be as hard as it might look:

  • Some of these we already fixed, I think.
  • Some of these work in groups, so we only have to fix one place and we solve several labels at once
  • Others might be harmless, just labels that end with _ but are not used in composition

But at least this gives us an idea of what problems we potentially have created...

Language Bug

Most helpful comment

@pgorod I'm guessing that its both a mix of these hard to find, rarely seen labels and that only version 7.9.x and 7.10 beta have these removed. I'll take another look at languages this week and see if I can make some new PR's.

All 16 comments

@Dillon-Brown @likhobory @Mausino We need your eyes here!

I'm keeping my grep tool busy and this is the list of the Relationship labels composed with FROM in the middle, and TITLE in the end:

GROUP B - List of strings

modules/jjwg_Areas/language/en_us.lang.php:86:$mod_strings['LBL_JJWG_MAPS_JJWG_AREAS_FROM_JJWG_MAPS_TITLE'] = 'Maps';
modules/AOS_Product_Categories/language/en_us.lang.php:83:    'LBL_AOS_PRODUCT_CATEGORIES_AOS_PRODUCTS_FROM_AOS_PRODUCTS_TITLE' =>  'Product Categories: Product from Product Title',
modules/jjwg_Maps/language/en_us.lang.php:185:$mod_strings['LBL_JJWG_MAPS_JJWG_AREAS_FROM_JJWG_AREAS_TITLE'] = 'Areas';
modules/jjwg_Maps/language/en_us.lang.php:186:$mod_strings['LBL_JJWG_MAPS_JJWG_MARKERS_FROM_JJWG_MARKERS_TITLE'] = 'Markers';
modules/AM_TaskTemplates/language/en_us.lang.php:87:    'LBL_AM_TASKTEMPLATES_AM_PROJECTTEMPLATES_FROM_AM_PROJECTTEMPLATES_TITLE' => 'Project Templates',
modules/AM_TaskTemplates/language/en_us.lang.php:89:    'LBL_AM_TASKTEMPLATES_AM_PROJECTTEMPLATES_FROM_AM_TASKTEMPLATES_TITLE' => 'Task Templates: Project Templates from Task Templates Title',
modules/Project/language/en_us.lang.php:136:    'LBL_AM_PROJECTTEMPLATES_PROJECT_1_FROM_AM_PROJECTTEMPLATES_TITLE' => 'Project Template',
modules/Project/language/en_us.lang.php:154:    'LBL_PROJECT_USERS_1_FROM_USERS_TITLE' => 'Resources',
modules/Project/language/en_us.lang.php:188:    'LBL_PROJECT_CONTACTS_1_FROM_CONTACTS_TITLE' => 'Project Contacts from Contacts Title',
modules/Project/language/en_us.lang.php:189:    'LBL_AM_PROJECTTEMPLATES_PROJECT_1_FROM_PROJECT_TITLE' => 'Project Templates: Project from Project Title',
modules/jjwg_Markers/language/en_us.lang.php:86:$mod_strings['LBL_JJWG_MAPS_JJWG_MARKERS_FROM_JJWG_MAPS_TITLE'] = 'Maps';
modules/Leads/language/en_us.lang.php:247:    'LBL_FP_EVENTS_LEADS_1_FROM_FP_EVENTS_TITLE' => 'Events',
modules/Users/language/en_us.lang.php:833:    'LBL_PROJECT_USERS_1_FROM_PROJECT_TITLE' => 'Project Users from Project Title',
modules/Prospects/language/en_us.lang.php:175:    'LBL_FP_EVENTS_PROSPECTS_1_FROM_FP_EVENTS_TITLE' => 'Events',
modules/Campaigns/language/en_us.lang.php:175:  'LBL_FROM_MAILBOX_TITLE'=>'Bounce Handling Mail Account:',
modules/Employees/language/en_us.lang.php:159:  'LBL_PROJECT_USERS_1_FROM_PROJECT_TITLE' => 'Project Users from Project Title',
modules/Employees/language/en_us.lang.php:160:  'LBL_PROJECT_CONTACTS_1_FROM_CONTACTS_TITLE' => 'Project Contacts from Contacts Title',
modules/Contacts/language/en_us.lang.php:220:    'LBL_FP_EVENTS_CONTACTS_FROM_FP_EVENTS_TITLE' => 'Events',
modules/Contacts/language/en_us.lang.php:240:    'LBL_PROJECT_CONTACTS_1_FROM_PROJECT_TITLE' => 'Project Contacts from Project Title',
modules/FP_events/language/en_us.lang.php:114:    'LBL_FP_EVENTS_CONTACTS_FROM_CONTACTS_TITLE' => 'Contacts',
modules/FP_events/language/en_us.lang.php:115:    'LBL_FP_EVENT_LOCATIONS_FP_EVENTS_1_FROM_FP_EVENT_LOCATIONS_TITLE' => 'Locations',
modules/FP_events/language/en_us.lang.php:116:    'LBL_FP_EVENTS_LEADS_1_FROM_LEADS_TITLE' => 'Leads',
modules/FP_events/language/en_us.lang.php:117:    'LBL_FP_EVENTS_PROSPECTS_1_FROM_PROSPECTS_TITLE' => 'Targets',
modules/FP_events/language/en_us.lang.php:118:    'LBL_FP_EVENTS_FP_EVENT_DELEGATES_1_FROM_FP_EVENT_DELEGATES_TITLE' => 'Delegates',
modules/FP_events/language/en_us.lang.php:142:  'LBL_FP_EVENT_LOCATIONS_FP_EVENTS_1_FROM_FP_EVENTS_TITLE' => 'Event Locations from Events Title',
modules/FP_Event_Locations/language/en_us.lang.php:83:    'LBL_FP_EVENT_LOCATIONS_FP_EVENTS_1_FROM_FP_EVENTS_TITLE' => 'Events',
modules/AOR_Reports/language/en_us.lang.php:103:    'LBL_AOR_SCHEDULED_REPORTS_AOR_REPORTS_FROM_AOR_SCHEDULED_REPORTS_TITLE' => 'Scheduled Reports',
modules/AM_ProjectTemplates/language/en_us.lang.php:80:    'LBL_AM_TASKTEMPLATES_AM_PROJECTTEMPLATES_FROM_AM_TASKTEMPLATES_TITLE' => 'Task Templates',
modules/AM_ProjectTemplates/language/en_us.lang.php:107:    'LBL_PROJECT_USERS_1_FROM_USERS_TITLE' => 'Resources',
modules/AM_ProjectTemplates/language/en_us.lang.php:145:    'LBL_AM_PROJECTTEMPLATES_PROJECT_1_FROM_PROJECT_TITLE' => 'Project Templates Project from Project Title',
modules/AM_ProjectTemplates/language/en_us.lang.php:146:    'LBL_AOS_PRODUCTS_AM_PROJECTTEMPLATES_1_FROM_AM_PROJECTTEMPLATES_TITLE' => 'Product: Project Templates from Project Templates Title',
modules/AM_ProjectTemplates/language/en_us.lang.php:147:    'LBL_AM_PROJECTTEMPLATES_PROJECT_1_FROM_PROJECT_TITLE' => 'Project Templates: Project from Project Title',

These labels are from SuiteCRM 7.9.3.

Guys, please check my updated posts, I'm trying to make this an ongoing project to get everything fixed. I will try to work on managing everything (keeping the original post updated), and on generating lists of wrongly deleted strings from my pre-7.9.6 install, and posting those as comments here. But I'm not getting too much free time so this might have to wait.

If other people can work on doing the PR (or PR's) to put them back, I'd appreciate it.

Question: is any of these groups already done? There were a couple of PR's putting back strings, am I right?

GROUP C - List of strings

modules/Spots/language/en_us.lang.php:84:    'LBL_AN_AREA_FOR_ANALYSIS' => 'Area for Analysis',
modules/Spots/language/en_us.lang.php:85:    'LBL_AN_CONFIGURATION' => 'Configuration',
modules/Spots/language/en_us.lang.php:86:    'LBL_AN_SALES' => 'Sales',
modules/Spots/language/en_us.lang.php:87:    'LBL_AN_ACCOUNTS' => 'Accounts',
modules/Spots/language/en_us.lang.php:88:    'LBL_AN_LEADS' => 'Leads',
modules/Spots/language/en_us.lang.php:89:    'LBL_AN_SERVICE' => 'Service',
modules/Spots/language/en_us.lang.php:90:    'LBL_AN_MARKETING' => 'Marketing',
modules/Spots/language/en_us.lang.php:91:    'LBL_AN_MARKETING_ACTIVITY' => 'Marketing Activity',
modules/Spots/language/en_us.lang.php:92:    'LBL_AN_ACTIVITIES' => 'Activities',
modules/Spots/language/en_us.lang.php:93:    'LBL_AN_QUOTES' => 'Quotes',
modules/Spots/language/en_us.lang.php:95:    'LBL_AN_UNSUPPORTED_DB' => 'Sorry, Suite Spots are currently configured for MySQL and MS SQL only',
modules/Spots/language/en_us.lang.php:98:    'LBL_AN_ACCOUNTS_ACCOUNT_NAME' => 'Name',
modules/Spots/language/en_us.lang.php:99:    'LBL_AN_ACCOUNTS_ACCOUNT_TYPE' => 'Account Type',
modules/Spots/language/en_us.lang.php:100:    'LBL_AN_ACCOUNTS_ACCOUNT_INDUSTRY' => 'Industry',
modules/Spots/language/en_us.lang.php:101:    'LBL_AN_ACCOUNTS_ACCOUNT_BILLING_COUNTRY' => 'Billing Country',
modules/Spots/language/en_us.lang.php:104:    'LBL_AN_LEADS_ASSIGNED_USER' => 'Assigned User',
modules/Spots/language/en_us.lang.php:105:    'LBL_AN_LEADS_STATUS' => 'Status',
modules/Spots/language/en_us.lang.php:106:    'LBL_AN_LEADS_LEAD_SOURCE' => 'Lead Source',
modules/Spots/language/en_us.lang.php:107:    'LBL_AN_LEADS_CAMPAIGN_NAME' => 'Campaign Name',
modules/Spots/language/en_us.lang.php:108:    'LBL_AN_LEADS_YEAR' => 'Year',
modules/Spots/language/en_us.lang.php:109:    'LBL_AN_LEADS_QUARTER' => 'Quarter',
modules/Spots/language/en_us.lang.php:110:    'LBL_AN_LEADS_MONTH' => 'Month',
modules/Spots/language/en_us.lang.php:111:    'LBL_AN_LEADS_WEEK' => 'Week',
modules/Spots/language/en_us.lang.php:112:    'LBL_AN_LEADS_DAY' => 'Day',
modules/Spots/language/en_us.lang.php:115:    'LBL_AN_SALES_ACCOUNT_NAME' => 'Account Name',
modules/Spots/language/en_us.lang.php:116:    'LBL_AN_SALES_OPPORTUNITY_NAME' => 'Opportunity Name',
modules/Spots/language/en_us.lang.php:117:    'LBL_AN_SALES_ASSIGNED_USER' => 'Assigned User',
modules/Spots/language/en_us.lang.php:118:    'LBL_AN_SALES_OPPORTUNITY_TYPE' => 'OpportunityType',
modules/Spots/language/en_us.lang.php:119:    'LBL_AN_SALES_LEAD_SOURCE' => 'Lead Source',
modules/Spots/language/en_us.lang.php:120:    'LBL_AN_SALES_AMOUNT' => 'Amount',
modules/Spots/language/en_us.lang.php:121:    'LBL_AN_SALES_STAGE' => 'Sales Stage',
modules/Spots/language/en_us.lang.php:122:    'LBL_AN_SALES_PROBABILITY' => 'Probability',
modules/Spots/language/en_us.lang.php:123:    'LBL_AN_SALES_DATE' => 'Sales Date',
modules/Spots/language/en_us.lang.php:124:    'LBL_AN_SALES_QUARTER' => 'Sales Quarter',
modules/Spots/language/en_us.lang.php:125:    'LBL_AN_SALES_MONTH' => 'Sales Month',
modules/Spots/language/en_us.lang.php:126:    'LBL_AN_SALES_WEEK' => 'Sales Week',
modules/Spots/language/en_us.lang.php:127:    'LBL_AN_SALES_DAY' => 'Sales Day',
modules/Spots/language/en_us.lang.php:128:    'LBL_AN_SALES_YEAR' => 'Sales Year',
modules/Spots/language/en_us.lang.php:129:    'LBL_AN_SALES_CAMPAIGN' => 'Campaign',
modules/Spots/language/en_us.lang.php:132:    'LBL_AN_SERVICE_ACCOUNT_NAME' => 'Account Name',
modules/Spots/language/en_us.lang.php:133:    'LBL_AN_SERVICE_STATE' => 'State',
modules/Spots/language/en_us.lang.php:134:    'LBL_AN_SERVICE_STATUS' => 'Status',
modules/Spots/language/en_us.lang.php:135:    'LBL_AN_SERVICE_PRIORITY' => 'Priority',
modules/Spots/language/en_us.lang.php:136:    'LBL_AN_SERVICE_CREATED_DAY' => 'Created Day',
modules/Spots/language/en_us.lang.php:137:    'LBL_AN_SERVICE_CREATED_WEEK' => 'Created Week',
modules/Spots/language/en_us.lang.php:138:    'LBL_AN_SERVICE_CREATED_MONTH' => 'Created Month',
modules/Spots/language/en_us.lang.php:139:    'LBL_AN_SERVICE_CREATED_QUARTER' => 'Created Quarter',
modules/Spots/language/en_us.lang.php:140:    'LBL_AN_SERVICE_CREATED_YEAR' => 'Created Year',
modules/Spots/language/en_us.lang.php:141:    'LBL_AN_SERVICE_CONTACT_NAME' => 'Contact Name',
modules/Spots/language/en_us.lang.php:142:    'LBL_AN_SERVICE_ASSIGNED_TO' => 'Assigned User',
modules/Spots/language/en_us.lang.php:145:    'LBL_AN_ACTIVITIES_TYPE' => 'Type',
modules/Spots/language/en_us.lang.php:146:    'LBL_AN_ACTIVITIES_NAME' => 'Name',
modules/Spots/language/en_us.lang.php:147:    'LBL_AN_ACTIVITIES_STATUS' => 'Status',
modules/Spots/language/en_us.lang.php:148:    'LBL_AN_ACTIVITIES_ASSIGNED_TO' => 'Assigned User',
modules/Spots/language/en_us.lang.php:151:    'LBL_AN_MARKETING_STATUS' => 'Status',
modules/Spots/language/en_us.lang.php:152:    'LBL_AN_MARKETING_TYPE' => 'Type',
modules/Spots/language/en_us.lang.php:153:    'LBL_AN_MARKETING_BUDGET' => 'Budget',
modules/Spots/language/en_us.lang.php:154:    'LBL_AN_MARKETING_EXPECTED_COST' => 'Expected Cost',
modules/Spots/language/en_us.lang.php:155:    'LBL_AN_MARKETING_EXPECTED_REVENUE' => 'Expected Revenue',
modules/Spots/language/en_us.lang.php:156:    'LBL_AN_MARKETING_OPPORTUNITY_NAME' => 'Opportunity Name',
modules/Spots/language/en_us.lang.php:157:    'LBL_AN_MARKETING_OPPORTUNITY_AMOUNT' => 'Opportunity Amount',
modules/Spots/language/en_us.lang.php:158:    'LBL_AN_MARKETING_OPPORTUNITY_SALES_STAGE' => 'Opportunity Sales Stage',
modules/Spots/language/en_us.lang.php:159:    'LBL_AN_MARKETING_OPPORTUNITY_ASSIGNED_TO' => 'Opportunity Assigned To',
modules/Spots/language/en_us.lang.php:160:    'LBL_AN_MARKETING_ACCOUNT_NAME' => 'Account Name',
modules/Spots/language/en_us.lang.php:163:    'LBL_AN_MARKETINGACTIVITY_CAMPAIGN_NAME' => 'Campaign Name',
modules/Spots/language/en_us.lang.php:164:    'LBL_AN_MARKETINGACTIVITY_ACTIVITY_DATE' => 'Activity Date',
modules/Spots/language/en_us.lang.php:165:    'LBL_AN_MARKETINGACTIVITY_ACTIVITY_TYPE' => 'Activity Type',
modules/Spots/language/en_us.lang.php:166:    'LBL_AN_MARKETINGACTIVITY_RELATED_TYPE' => 'Related Type',
modules/Spots/language/en_us.lang.php:167:    'LBL_AN_MARKETINGACTIVITY_RELATED_ID' => 'Related ID',
modules/Spots/language/en_us.lang.php:170:    'LBL_AN_QUOTES_OPPORTUNITY_NAME' => 'Opportunity Name',
modules/Spots/language/en_us.lang.php:171:    'LBL_AN_QUOTES_OPPORTUNITY_TYPE' => 'Opportunity Type',
modules/Spots/language/en_us.lang.php:172:    'LBL_AN_QUOTES_OPPORTUNITY_LEAD_SOURCE' => 'Opportunity Lead Source',
modules/Spots/language/en_us.lang.php:173:    'LBL_AN_QUOTES_OPPORTUNITY_SALES_STAGE' => 'Opportunity Sales Stage',
modules/Spots/language/en_us.lang.php:174:    'LBL_AN_QUOTES_ACCOUNT_NAME' => 'Account Name',
modules/Spots/language/en_us.lang.php:175:    'LBL_AN_QUOTES_CONTACT_NAME' => 'Contact Name',
modules/Spots/language/en_us.lang.php:176:    'LBL_AN_QUOTES_ITEM_NAME' => 'Item Name',
modules/Spots/language/en_us.lang.php:177:    'LBL_AN_QUOTES_ITEM_TYPE' => 'Item Type',
modules/Spots/language/en_us.lang.php:178:    'LBL_AN_QUOTES_ITEM_CATEGORY' => 'Item Category',
modules/Spots/language/en_us.lang.php:179:    'LBL_AN_QUOTES_ITEM_QTY' => 'Item Qty',
modules/Spots/language/en_us.lang.php:180:    'LBL_AN_QUOTES_ITEM_LIST_PRICE' => 'Item List Price',
modules/Spots/language/en_us.lang.php:181:    'LBL_AN_QUOTES_ITEM_SALE_PRICE' => 'Item Sale Price',
modules/Spots/language/en_us.lang.php:182:    'LBL_AN_QUOTES_ITEM_COST_PRICE' => 'Item Cost Price',
modules/Spots/language/en_us.lang.php:183:    'LBL_AN_QUOTES_ITEM_DISCOUNT_PRICE' => 'Item Discount Price',
modules/Spots/language/en_us.lang.php:184:    'LBL_AN_QUOTES_ITEM_DISCOUNT_AMOUNT' => 'Discount Amount',
modules/Spots/language/en_us.lang.php:185:    'LBL_AN_QUOTES_ITEM_TOTAL' => 'Item Total',
modules/Spots/language/en_us.lang.php:186:    'LBL_AN_QUOTES_GRAND_TOTAL' => 'Grand Total',
modules/Spots/language/en_us.lang.php:187:    'LBL_AN_QUOTES_ASSIGNED_TO' => 'Assigned User',
modules/Spots/language/en_us.lang.php:188:    'LBL_AN_QUOTES_DATE_CREATED' => 'Date Created',
modules/Spots/language/en_us.lang.php:189:    'LBL_AN_QUOTES_DAY_CREATED' => 'Day Created',
modules/Spots/language/en_us.lang.php:190:    'LBL_AN_QUOTES_WEEK_CREATED' => 'Week Created',
modules/Spots/language/en_us.lang.php:191:    'LBL_AN_QUOTES_MONTH_CREATED' => 'Month Created',
modules/Spots/language/en_us.lang.php:192:    'LBL_AN_QUOTES_QUARTER_CREATED' => 'Quarter Created',
modules/Spots/language/en_us.lang.php:193:    'LBL_AN_QUOTES_YEAR_CREATED' => 'Year Created',
modules/Spots/language/en_us.lang.php:196:    'LBL_AN_DUPLICATE_LABEL_FOR_SUBAREA' => 'Error ascertaining the label for the pivot sub-area',

GROUP D - List of strings

modules/Import/language/en_us.lang.php:61:    'LBL_ERROR_INVALID_BOOL'=>'Invalid boolean value',
modules/Import/language/en_us.lang.php:87:    'LBL_ERROR_INVALID_ID' => 'ID given is too long to fit in the field (maximum length is 36 characters)',
modules/Import/language/en_us.lang.php:88:    'LBL_ERROR_INVALID_PHONE' => 'Invalid phone number',
modules/Import/language/en_us.lang.php:89:    'LBL_ERROR_INVALID_NAME' => 'String too long to fit in the field',
modules/Import/language/en_us.lang.php:90:    'LBL_ERROR_INVALID_VARCHAR' => 'String too long to fit in the field',
modules/Import/language/en_us.lang.php:91:    'LBL_ERROR_INVALID_DATE' => 'Invalid date',
modules/Import/language/en_us.lang.php:92:    'LBL_ERROR_INVALID_DATETIME' => 'Invalid datetime',
modules/Import/language/en_us.lang.php:93:    'LBL_ERROR_INVALID_DATETIMECOMBO' => 'Invalid datetime',
modules/Import/language/en_us.lang.php:94:    'LBL_ERROR_INVALID_TIME' => 'Invalid time',
modules/Import/language/en_us.lang.php:95:    'LBL_ERROR_INVALID_INT' => 'Invalid integer value',
modules/Import/language/en_us.lang.php:96:    'LBL_ERROR_INVALID_NUM' => 'Invalid numeric value',
modules/Import/language/en_us.lang.php:97:    'LBL_ERROR_INVALID_EMAIL'=>'Invalid Email address',
modules/Import/language/en_us.lang.php:98:    'LBL_ERROR_INVALID_USER'=>'Invalid user name or ID',
modules/Import/language/en_us.lang.php:99:    'LBL_ERROR_INVALID_TEAM' => 'Invalid team name or ID',
modules/Import/language/en_us.lang.php:100:    'LBL_ERROR_INVALID_ACCOUNT' => 'Invalid account name or ID',
modules/Import/language/en_us.lang.php:101:    'LBL_ERROR_INVALID_RELATE' => 'Invalid relational field',
modules/Import/language/en_us.lang.php:102:    'LBL_ERROR_INVALID_CURRENCY' => 'Invalid currency value',
modules/Import/language/en_us.lang.php:103:    'LBL_ERROR_INVALID_FLOAT' => 'Invalid floating point number',

modules/Import/language/en_us.lang.php:251:    'LBL_IMPORT_FIELDDEF_ID' => 'Unique ID number',
modules/Import/language/en_us.lang.php:252:    'LBL_IMPORT_FIELDDEF_RELATE' => 'Name or ID',
modules/Import/language/en_us.lang.php:253:    'LBL_IMPORT_FIELDDEF_PHONE' => 'Phone Number',
modules/Import/language/en_us.lang.php:254:    'LBL_IMPORT_FIELDDEF_TEAM_LIST' => 'Team Name or ID',
modules/Import/language/en_us.lang.php:255:    'LBL_IMPORT_FIELDDEF_NAME' => 'Any Text',
modules/Import/language/en_us.lang.php:256:    'LBL_IMPORT_FIELDDEF_VARCHAR' => 'Any Text',
modules/Import/language/en_us.lang.php:257:    'LBL_IMPORT_FIELDDEF_TEXT' => 'Any Text',
modules/Import/language/en_us.lang.php:258:    'LBL_IMPORT_FIELDDEF_TIME' => 'Time',
modules/Import/language/en_us.lang.php:259:    'LBL_IMPORT_FIELDDEF_DATE' => 'Date',
modules/Import/language/en_us.lang.php:260:    'LBL_IMPORT_FIELDDEF_ASSIGNED_USER_NAME' => 'User Name or ID',
modules/Import/language/en_us.lang.php:261:    'LBL_IMPORT_FIELDDEF_BOOL' => '\'0\' or \'1\'',
modules/Import/language/en_us.lang.php:262:    'LBL_IMPORT_FIELDDEF_ENUM' => 'List',
modules/Import/language/en_us.lang.php:263:    'LBL_IMPORT_FIELDDEF_EMAIL' => 'EMail Address',
modules/Import/language/en_us.lang.php:264:    'LBL_IMPORT_FIELDDEF_INT' => 'Numeric (No Decimal)',
modules/Import/language/en_us.lang.php:265:    'LBL_IMPORT_FIELDDEF_DOUBLE' => 'Numeric (No Decimal)',
modules/Import/language/en_us.lang.php:266:    'LBL_IMPORT_FIELDDEF_NUM' => 'Numeric (No Decimal)',
modules/Import/language/en_us.lang.php:267:    'LBL_IMPORT_FIELDDEF_CURRENCY' => 'Numeric (Decimal Allowed)',
modules/Import/language/en_us.lang.php:268:    'LBL_IMPORT_FIELDDEF_FLOAT' => 'Numeric (Decimal Allowed)',

GROUP E - List of strings

modules/jjwg_Maps/language/en_us.lang.php:94:$mod_strings['LBL_EXPORT_ADDRESS_URL'] = 'Export URLs';
modules/jjwg_Maps/language/en_us.lang.php:95:$mod_strings['LBL_EXPORT_INSTRUCTIONS'] = 'Use the links below to export full addresses in need of geocodeing information. Then use an online or offline batch geocoding tool to geocode the addresses. When you are finished geocoding, import the addresses into the Address Cache module to be used with your maps. Note, the Address Cache module is optional. All geocoding information is stored in the representative module.';


modules/Accounts/language/en_us.lang.php:177:    'LBL_EXPORT_ASSIGNED_USER_NAME' => 'Assigned User Name',

modules/Users/language/en_us.lang.php:166:    'LBL_EXPORT_CHARSET' => 'Import/Export Character Set',
modules/Users/language/en_us.lang.php:167:    'LBL_EXPORT_CHARSET_DESC' => 'Choose the character set used in your locale. This property will be used for data imports, .csv exports and for vCard generation.',
modules/Users/language/en_us.lang.php:168:    'LBL_EXPORT_DELIMITER' => 'Export Delimiter',
modules/Users/language/en_us.lang.php:169:    'LBL_EXPORT_DELIMITER_DESC' => 'Specify the character(s) used to delimit exported data.',

modules/Administration/language/en_us.lang.php:298:    'LBL_EXPORT_CUSTOM_FIELDS_TITLE' => 'Export Custom Fields Structure',
modules/Administration/language/en_us.lang.php:299:    'LBL_EXPORT_CUSTOM_FIELDS' => 'Export custom field definitions to a .sugar file',

include/language/en_us.lang.php:1622:    'LBL_EXPORT_ALL' => 'Export All',
include/language/en_us.lang.php:2237:    'LBL_EXPORT_ASSIGNED_USER_ID' => 'Assigned To',
include/language/en_us.lang.php:2238:    'LBL_EXPORT_ASSIGNED_USER_NAME' => 'Assigned User',

I think we should also see if those strings are actually in use and where.
I wonder if some of those are just code not in use!
Requesting help @likhobory @pribeiro42 @Mausino

@horus68 I just don't know how to see if they are in use.

Basically what this inspection of the code does is prove that some strings are _potentially_ referenced from the code, even if they were not discovered initially using a simple "find in files", when you (and the others) were working on the removal of unused strings.

But it's much more complicated (impossible, in practical terms) to judge whether they are _really_ used...

@horus68 since @pgorod tried and got to the conclusion that is near impossible to check for all the cases, my guess is that it's more simple to leave the strings as is and have a little overhead translate things that might not be used that to try and check everything just to spare a few strings...

We removed some 7600 strings in a total of 52000, that's excellent. We don't need to go back on all of this. We just need to go back on the strings listed here, maybe some 500.

Of these 500, maybe a few are really unused. Those are the ones I explained we have no practical way of knowing.

I am curious about this Issue here. I stopped working on it, listing the strings that had to be put back.

Nobody worked on it, actually putting any strings back.

So what intrigues me is: why is this not a major issue? Why is nobody getting bugs and complaining? I expected a huge impact on this, yet it's been weeks and I don't see this coming up in the forums... is it just because people don't use these features? _None_ of them?

@pgorod I'm guessing that its both a mix of these hard to find, rarely seen labels and that only version 7.9.x and 7.10 beta have these removed. I'll take another look at languages this week and see if I can make some new PR's.

GROUP F - List of strings

This is in modules/Schedulers/language/en_us.lang.php line 163

    'LBL_REFRESHJOBS' => 'Refresh Jobs',
    'LBL_POLLMONITOREDINBOXES' => 'Check Inbound Mail Accounts',
    'LBL_PERFORMFULLFTSINDEX' => 'Full-text Search Index System',
    'LBL_RUNMASSEMAILCAMPAIGN' => 'Run Nightly Mass Email Campaigns',
    'LBL_POLLMONITOREDINBOXESFORBOUNCEDCAMPAIGNEMAILS' => 'Run Nightly Process Bounced Campaign Emails',
    'LBL_PRUNEDATABASE' => 'Prune Database on 1st of Month',
    'LBL_TRIMTRACKER' => 'Prune Tracker Tables',
    'LBL_TRIMSUGARFEEDS' => 'Prune SuiteCRM Feed Tables',
    'LBL_SENDEMAILREMINDERS' => 'Run Email Reminders Sending',
    'LBL_CLEANJOBQUEUE' => 'Cleanup Job Queue',
    'LBL_REMOVEDOCUMENTSFROMFS' => 'Removal of documents from filesystem',
    'LBL_AODOPTIMISEINDEX' => 'Optimise Advanced OpenDiscovery Index',
    'LBL_AODINDEXUNINDEXED' => 'Index unindexed documents',
    'LBL_POLLMONITOREDINBOXESAOP' => 'AOP Poll Monitored Inboxes',
    'LBL_AORRUNSCHEDULEDREPORTS' => 'Run scheduled reports',
    'LBL_PROCESSAOW_WORKFLOW' => 'Process AOW Workflow',

Maybe instead of reinstating these, we could use these ones instead, which are still here in the latest version. No point in repeating then...

Here is a forum issue which I assume is the manifestation of this problem.

EDIT: this group is now fixed by #5171 and #9054

This should be solved on the main language, before solving it on the translations, I suppose... but if you're confident you can solve it there and not get confused once these things are changed here, go ahead.... your international users will thank you. :-)

@pgorod GROUP F - List of strings can be removed (simply delete your reply above) as it is now reinstated by 5171 . Then I will also remove this reply to keep this a clean issue.

As there are 2 F groups listed its the ones for Scheduler jobs in https://github.com/salesagility/SuiteCRM/issues/4291#issuecomment-349289904
(maybe renaming all groups?)

@pgorod @Dillon-Brown On the Group C language strings for Spots module there is a PR with several fixes to translation (2 years ago!) https://github.com/salesagility/SuiteCRM/issues/1764

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tech-ch1 picture tech-ch1  路  3Comments

connorshea picture connorshea  路  3Comments

project-banana picture project-banana  路  3Comments

sasha2002 picture sasha2002  路  3Comments

darouca picture darouca  路  3Comments