Unable to pull imported contacts, lists, and launch campaign

So I was having some issues with an old version of SuiteCRM and decided I would try to update to a new version. I now am able to at least login to the CRM system. Now I cant access contacts, marketing lists, and/or launch marketing campaigns. Any help to get this system back on track would be much appreciated!!

Version: SuiteCRM 7.11.20

Error Log Below:

[29-Jun-2021 20:19:21 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:21 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:21 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:19:24 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:24 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:24 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:19:24 UTC] PHP Notice: Undefined index: LBL_SELECT_TEMPLATE in /home/Websource/public_html/login/modules/Campaigns/WizardNewsletter.php on line 735

[29-Jun-2021 20:19:24 UTC] PHP Notice: Undefined index: LBL_NAVIGATION_MENU_SEND_EMAIL_AND_SUMMARY in /home/Websource/public_html/login/modules/Campaigns/WizardNewsletter.php on line 747

[29-Jun-2021 20:19:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:37 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LBL_NO_TEMPLATE_SELECTED in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 401

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LBL_SELECT_TEMPLATE in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 505

[29-Jun-2021 20:19:46 UTC] PHP Notice: Undefined index: LBL_NAVIGATION_MENU_SEND_EMAIL_AND_SUMMARY in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 514

[29-Jun-2021 20:19:47 UTC] PHP Notice: Undefined index: stackTrace in /home/Websource/public_html/login/include/MVC/Controller/SugarController.php on line 393

[29-Jun-2021 20:20:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:21:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:22:02 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:23:02 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:24:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:25:02 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 43

[29-Jun-2021 20:26:03 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:26:08 UTC] PHP Notice: Undefined index: LOGIN_LOGO_ERROR in /home/Websource/public_html/login/custom/modules/Users/Login.php on line 120

[29-Jun-2021 20:26:15 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:15 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:15 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:26:19 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:19 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:19 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:26:19 UTC] PHP Notice: Undefined index: LBL_SELECT_TEMPLATE in /home/Websource/public_html/login/modules/Campaigns/WizardNewsletter.php on line 735

[29-Jun-2021 20:26:19 UTC] PHP Notice: Undefined index: LBL_NAVIGATION_MENU_SEND_EMAIL_AND_SUMMARY in /home/Websource/public_html/login/modules/Campaigns/WizardNewsletter.php on line 747

[29-Jun-2021 20:26:28 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:28 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:28 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LBL_NO_TEMPLATE_SELECTED in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 401

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LBL_SELECT_TEMPLATE in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 505

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: LBL_NAVIGATION_MENU_SEND_EMAIL_AND_SUMMARY in /home/Websource/public_html/login/modules/Campaigns/WizardMarketing.php on line 514

[29-Jun-2021 20:26:36 UTC] PHP Notice: Undefined index: stackTrace in /home/Websource/public_html/login/include/MVC/Controller/SugarController.php on line 393

[29-Jun-2021 20:27:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:28:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:29:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:30:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:31:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:32:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:33:02 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:34:00 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:34:00 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:34:01 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:34:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:34:07 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:34:07 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:34:07 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:35:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:35:11 UTC] PHP Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; mobile_jsLanguage has a deprecated constructor in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 16

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: source in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 36

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: LBL_MARK_AS_FAVORITES in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 75

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: LBL_REMOVE_FROM_FAVORITES in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 75

[29-Jun-2021 20:35:11 UTC] PHP Notice: Undefined index: source in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 36

[29-Jun-2021 20:35:12 UTC] PHP Notice: Undefined index: source in /home/Websource/public_html/login/custom/modules/Administration/genJSfromSugar.php on line 36

[29-Jun-2021 20:35:22 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:22 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:22 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:35:48 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:48 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:35:48 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:36:02 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

[29-Jun-2021 20:36:05 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:36:05 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:36:05 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:36:22 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:36:22 UTC] PHP Notice: Undefined index: LNK_IMPORT_CAMPAIGNS in /home/Websource/public_html/login/modules/Campaigns/Menu.php on line 104

[29-Jun-2021 20:36:22 UTC] PHP Notice: Undefined index: email_warning_notifications in /home/Websource/public_html/login/modules/Administration/Administration.php on line 84

[29-Jun-2021 20:36:24 UTC] PHP Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; ContactsListViewSmarty has a deprecated constructor in /home/Websource/public_html/login/custom/modules/Contacts/ContactsListViewSmarty.php on line 6

[29-Jun-2021 20:36:24 UTC] PHP Fatal error: Uncaught Error: Call to undefined method ListViewSmarty::ListViewSmarty() in /home/Websource/public_html/login/custom/modules/Contacts/ContactsListViewSmarty.php:10

Stack trace:

#0 /home/Websource/public_html/login/custom/modules/Contacts/views/view.list.php(16): ContactsListViewSmarty->ContactsListViewSmarty()

#1 /home/Websource/public_html/login/include/MVC/View/SugarView.php(224): ContactsViewList->preDisplay()

#2 /home/Websource/public_html/login/include/MVC/Controller/SugarController.php(444): SugarView->process()

#3 /home/Websource/public_html/login/include/MVC/Controller/SugarController.php(375): SugarController->processView()

#4 /home/Websource/public_html/login/include/MVC/SugarApplication.php(113): SugarController->execute()

#5 /home/Websource/public_html/login/index.php(52): SugarApplication->execute()

#6 {main}

thrown in /home/Websource/public_html/login/custom/modules/Contacts/ContactsListViewSmarty.php on line 10

[29-Jun-2021 20:36:42 UTC] PHP Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; AccountsListViewSmarty has a deprecated constructor in /home/Websource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php on line 6

[29-Jun-2021 20:36:42 UTC] PHP Fatal error: Uncaught Error: Call to undefined method ListViewSmarty::ListViewSmarty() in /home/Websource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php:10

Stack trace:

#0 /home/Websource/public_html/login/custom/modules/Accounts/views/view.list.php(16): AccountsListViewSmarty->AccountsListViewSmarty()

#1 /home/Websource/public_html/login/include/MVC/View/SugarView.php(224): AccountsViewList->preDisplay()

#2 /home/Websource/public_html/login/include/MVC/Controller/SugarController.php(444): SugarView->process()

#3 /home/Websource/public_html/login/include/MVC/Controller/SugarController.php(375): SugarController->processView()

#4 /home/Websource/public_html/login/include/MVC/SugarApplication.php(113): SugarController->execute()

#5 /home/Websource/public_html/login/index.php(52): SugarApplication->execute()

#6 {main}

thrown in /home/Websource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php on line 10

[29-Jun-2021 20:37:01 UTC] PHP Fatal error: Cannot redeclare aodIndexUnindexed() (previously declared in /home/Websource/public_html/login/modules/Schedulers/_AddJobsHere.php:721) in /home/Websource/public_html/login/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php on line 37

I see from another thread that you have an unhealthy installation, with permissions errors. Maybe that is the cause of all your other problems.

From your errors here, just one question, what do you have under

custom/Extension/modules/Schedulers

?

Data Pulled From Schedulers: (Bolded lines 37-47) Thanks for your help!

**$job_strings[] = 'aodIndexUnindexed';**
**$job_strings[] = 'aodOptimiseIndex';**


**/****
** * Scheduled job function to index any unindexed beans.**
** * @return bool**
** */**
**function aodIndexUnindexed(){**
**    $total = 1;**
**    while($total > 0){**
**        $total = performLuceneIndexing();**
**    }**
**    return true;**
**}**

**function aodOptimiseIndex(){**
**    $index = BeanFactory::getBean("AOD_Index")->getIndex();**
**    $index->optimise();**
**    return true;**
**}**
function performLuceneIndexing(){
    global $db, $sugar_config;
    if(empty($sugar_config['aod']['enable_aod'])){
        return;
    }
    $index = BeanFactory::getBean("AOD_Index")->getIndex();

    $beanList = $index->getIndexableModules();
    $total = 0;
    foreach($beanList as $beanModule => $beanName){
        $bean = BeanFactory::getBean($beanModule);
        if(!$bean || !method_exists($bean,"getTableName") || !$bean->getTableName()){
            continue;
        }
        $query = "SELECT b.id FROM ".$bean->getTableName()." b LEFT JOIN aod_indexevent ie ON (ie.record_id = b.id AND ie.record_module = '".$beanModule."') WHERE b.deleted = 0 AND (ie.id IS NULL OR ie.date_modified < b.date_modified)";
        $res = $db->limitQuery($query,0,500);
        $c = 0;
        while($row = $db->fetchByAssoc($res)){
            $c++;
            $total++;
            $index->index($beanModule, $row['id']);
        }
        if($c){
            $index->commit();
            $index->optimise();
        }

    }
    $index->optimise();
    return $total;
}

 
$job_strings['aow']='processAOW_Workflow';

function processAOW_Workflow() {
    require_once('modules/AOW_WorkFlow/AOW_WorkFlow.php');
    $workflow = new AOW_WorkFlow();
    return $workflow->run_flows();
}




$job_strings[] = 'pollMonitoredInboxesAOP';

function pollMonitoredInboxesAOP() {
    require_once 'custom/modules/InboundEmail/AOPInboundEmail.php';
    $_bck_up = array('team_id' => $GLOBALS['current_user']->team_id, 'team_set_id' => $GLOBALS['current_user']->team_set_id);
    $GLOBALS['log']->info('----->Scheduler fired job of type pollMonitoredInboxesAOP()');
    global $dictionary;
    global $app_strings;
    global $sugar_config;

    require_once('modules/Configurator/Configurator.php');
    require_once('modules/Emails/EmailUI.php');

    $ie = new AOPInboundEmail();
    $emailUI = new EmailUI();
    $r = $ie->db->query('SELECT id, name FROM inbound_email WHERE is_personal = 0 AND deleted=0 AND status=\'Active\' AND mailbox_type != \'bounce\'');
    $GLOBALS['log']->debug('Just got Result from get all Inbounds of Inbound Emails');

    while($a = $ie->db->fetchByAssoc($r)) {
        $GLOBALS['log']->debug('In while loop of Inbound Emails');
        $ieX = new AOPInboundEmail();
        $ieX->retrieve($a['id']);
        $GLOBALS['current_user']->team_id = $ieX->team_id;
        $GLOBALS['current_user']->team_set_id = $ieX->team_set_id;
        $mailboxes = $ieX->mailboxarray;
        foreach($mailboxes as $mbox) {
            $ieX->mailbox = $mbox;
            $newMsgs = array();
            $msgNoToUIDL = array();
            $connectToMailServer = false;
            if ($ieX->isPop3Protocol()) {
                $msgNoToUIDL = $ieX->getPop3NewMessagesToDownloadForCron();
                // get all the keys which are msgnos;
                $newMsgs = array_keys($msgNoToUIDL);
            }
            if($ieX->connectMailserver() == 'true') {
                $connectToMailServer = true;
            } // if

            $GLOBALS['log']->debug('Trying to connect to mailserver for [ '.$a['name'].' ]');
            if($connectToMailServer) {
                $GLOBALS['log']->debug('Connected to mailserver');
                if (!$ieX->isPop3Protocol()) {
                    $newMsgs = $ieX->getNewMessageIds();
                }
                if(is_array($newMsgs)) {
                    $current = 1;
                    $total = count($newMsgs);
                    require_once("include/SugarFolders/SugarFolders.php");
                    $sugarFolder = new SugarFolder();
                    $groupFolderId = $ieX->groupfolder_id;
                    $isGroupFolderExists = false;
                    $users = array();
                    if ($groupFolderId != null && $groupFolderId != "") {
                        $sugarFolder->retrieve($groupFolderId);
                        $isGroupFolderExists = true;
                    } // if
                    $messagesToDelete = array();
                    if ($ieX->isMailBoxTypeCreateCase()) {
                        require_once 'modules/AOP_Case_Updates/AOPAssignManager.php';
                        $assignManager = new AOPAssignManager($ieX);
                    }
                    foreach($newMsgs as $k => $msgNo) {
                        $uid = $msgNo;
                        if ($ieX->isPop3Protocol()) {
                            $uid = $msgNoToUIDL[$msgNo];
                        } else {
                            $uid = imap_uid($ieX->conn, $msgNo);
                        } // else
                        if ($isGroupFolderExists) {
                            if ($ieX->importOneEmail($msgNo, $uid)) {
                                // add to folder
                                $sugarFolder->addBean($ieX->email);
                                if ($ieX->isPop3Protocol()) {
                                    $messagesToDelete[] = $msgNo;
                                } else {
                                    $messagesToDelete[] = $uid;
                                }
                                if ($ieX->isMailBoxTypeCreateCase()) {
                                    $userId = $assignManager->getNextAssignedUser();
                                    $GLOBALS['log']->debug('userId [ '.$userId.' ]');
                                    $ieX->handleCreateCase($ieX->email, $userId);
                                } // if
                            } // if
                        } else {
                            if($ieX->isAutoImport()) {
                                $ieX->importOneEmail($msgNo, $uid);
                            } else {
                                /*If the group folder doesn't exist then download only those messages
                                 which has caseid in message*/

                                $ieX->getMessagesInEmailCache($msgNo, $uid);
                                $email = new Email();
                                $header = imap_headerinfo($ieX->conn, $msgNo);
                                $email->name = $ieX->handleMimeHeaderDecode($header->subject);
                                $email->from_addr = $ieX->convertImapToSugarEmailAddress($header->from);
                                $email->reply_to_email  = $ieX->convertImapToSugarEmailAddress($header->reply_to);
                                if(!empty($email->reply_to_email)) {
                                    $contactAddr = $email->reply_to_email;
                                } else {
                                    $contactAddr = $email->from_addr;
                                }
                                $mailBoxType = $ieX->mailbox_type;
                                $ieX->handleAutoresponse($email, $contactAddr);
                            } // else
                        } // else
                        $GLOBALS['log']->debug('***** On message [ '.$current.' of '.$total.' ] *****');
                        $current++;
                    } // foreach
                    // update Inbound Account with last robin

                } // if
                if ($isGroupFolderExists)	 {
                    $leaveMessagesOnMailServer = $ieX->get_stored_options("leaveMessagesOnMailServer", 0);
                    if (!$leaveMessagesOnMailServer) {
                        if ($ieX->isPop3Protocol()) {
                            $ieX->deleteMessageOnMailServerForPop3(implode(",", $messagesToDelete));
                        } else {
                            $ieX->deleteMessageOnMailServer(implode($app_strings['LBL_EMAIL_DELIMITER'], $messagesToDelete));
                        }
                    }
                }
            } else {
                $GLOBALS['log']->fatal("SCHEDULERS: could not get an IMAP connection resource for ID [ {$a['id']} ]. Skipping mailbox [ {$a['name']} ].");
                // cn: bug 9171 - continue while
            } // else
        } // foreach
        imap_expunge($ieX->conn);
        imap_close($ieX->conn, CL_EXPUNGE);
    } // while
    $GLOBALS['current_user']->team_id = $_bck_up['team_id'];
    $GLOBALS['current_user']->team_set_id = $_bck_up['team_set_id'];
    return true;
}



$job_strings[] = 'aorRunScheduledReports';

function aorRunScheduledReports(){
    require_once 'include/SugarQueue/SugarJobQueue.php';
    $date = new DateTime();//Ensure we check all schedules at the same instant
    foreach(BeanFactory::getBean('AOR_Scheduled_Reports')->get_full_list() as $scheduledReport){

        if($scheduledReport->status == 'active' && $scheduledReport->shouldRun($date)){
            if(empty($scheduledReport->aor_report_id)){
                continue;
            }
            $job = new SchedulersJob();
            $job->name = "Scheduled report - {$scheduledReport->name} on {$date->format('c')}";
            $job->data = $scheduledReport->id;
            $job->target = "class::AORScheduledReportJob";
            $job->assigned_user_id = 1;
            $jq = new SugarJobQueue();
            $jq->submitJob($job);
        }
    }
}



class AORScheduledReportJob implements RunnableSchedulerJob
{
    public function setJob(SchedulersJob $job)
    {
        $this->job = $job;
    }
    public function run($data)
    {
        global $sugar_config, $timedate;

        $bean = BeanFactory::getBean('AOR_Scheduled_Reports',$data);
        $report = $bean->get_linked_beans('aor_report','AOR_Reports');
        if($report){
            $report = $report[0];
        }else{
            return false;
        }
        $html = "<h1>{$report->name}</h1>".$report->build_group_report();
        $html .= <<<EOF
        <style>
        h1{
            color: black;
        }
        .list
        {
            font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;font-size: 12px;
            background: #fff;margin: 45px;width: 480px;border-collapse: collapse;text-align: left;
        }
        .list th
        {
            
[details="Summary"]

[/details]
font-size: 14px;
            font-weight: normal;
            color: black;
            padding: 10px 8px;
            border-bottom: 2px solid black};
        }
        .list td
        {
            padding: 9px 8px 0px 8px;
        }
        </style>
EOF;
        $emailObj = new Email();
        $defaults = $emailObj->getSystemDefaultEmail();
        $mail = new SugarPHPMailer();

        /*$result = $report->db->query($report->build_report_query());
        $reportData = array();
        while($row = $report->db->fetchByAssoc($result, false))
        {
            $reportData[] = $row;
        }
        $fields = $report->getReportFields();
        foreach($report->get_linked_beans('aor_charts','AOR_Charts') as $chart){
            $image = $chart->buildChartImage($reportData,$fields,false);
            $mail->AddStringEmbeddedImage($image,$chart->id,$chart->name.".png",'base64','image/png');
            $html .= "<img src='cid:{$chart->id}'>";
        }*/

        $mail->setMailerForSystem();
        $mail->IsHTML(true);
        $mail->From = $defaults['email'];
        $mail->FromName = $defaults['name'];
        $mail->Subject=from_html($bean->name);
        $mail->Body=$html;
        $mail->prepForOutbound();
        $success = true;
        $emails = $bean->get_email_recipients();
        foreach($emails as $email_address) {
            $mail->ClearAddresses();
            $mail->AddAddress($email_address);
            $success = $mail->Send() && $success;
        }
        $bean->last_run = $timedate->getNow()->asDb(false);
        $bean->save();
        return true;
    }
}
?>

I edited your post to use a triple backtick to signal a code block.

```
…code…
```

I don’t understand what you posted. I asked about which files you found there, I need to know the exact file names and paths.

The content you posted looks like modules/Schedulers/_AddJobsHere.php, I certainly don’t expect it to be under custom/Extension/modules/Schedulers, did you really find it there?

Oh Okay. I misunderstood the request.

Under “custom/Extension/modules/Schedulers” there is nothing except for a folder called Ext.

Under “custom/Extension/modules/Schedulers/Ext” there are two folders, “Language” and “ScheduledTasks”

Under “custom/Extension/modules/Schedulers/Ext/Language” there are the following PHP files:
de_de.lang.ext.php
en_us.lang.ext.php
es_es.lang.ext.php
fr_FR.lang.ext.php
hu_hu.lang.ext.php
it_it.lang.ext.php
nl_NL.lang.ext.php
pt_br.lang.ext.php
ru_ru.lang.ext.php
ua_ua.lang.ext.php

Under “custom/Extension/modules/Schedulers/Ext/ScheduledTasks” there are the following PHP file:
scheduledtasks.ext.php

Ok, that’s more like it :slight_smile: , and what is the content of this file?

custom/Extension/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php

This should at least let us clear a few of the FATAL errors in your logs, and hopefully it might make a difference to the overall health of your system…

The content of scheduledtasks.ext.php is the script above that I pasted in the forum.

Starts with this:
$job_strings[] = ‘aodIndexUnindexed’;
$job_strings[] = ‘aodOptimiseIndex’;

I don’t think that should be there, who put it there?

Can you remove it (save the file somewhere else, then do a Quick Repair and Rebuild)?

Ok. I removed it and ran Quick Repair and Rebuild.

Custom/Extension/Modules/Schedulers/Ext/ScheduledTasks

Now has the following folder:
Language

And the following files:
AODScheduler.php
AOPScheduler.php
AORScheduler.php
aow_workflow.php

You didn’t mention those files before, did they appear only now?

I also don’t think those files should be there, they belong to very old versions of SuiteCRM and are supposed to be removed by the upgrader. I don’t know the history of your installation, but I am guessing you had a broken upgrade at some point.

If you don’t have any add-ons, and don’t have any custom schedulers built by you, I advise to clear that directory entirely. Keep a backup copy, just in case.

Then QR&R again.

Then check if your FATAL errors are gone from the logs.

Then check if the functionality you want is back.

After the quick repair / rebuild they showed up. I will clear it and perform a QR&R.

I really appreciate your help.

I believe we are making some progress. Now when I go to open my contact list, I still receive the error message “There was an error processing your request, please try again at a later time.”. With the below error_log message.

[02-Jul-2021 14:12:36 UTC] PHP Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; AccountsListViewSmarty has a deprecated constructor in /home/WebSource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php on line 6

[02-Jul-2021 14:12:36 UTC] PHP Fatal error: Uncaught Error: Call to undefined method ListViewSmarty::ListViewSmarty() in /home/WebSource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php:10

Stack trace:

#0 /home/WebSource/public_html/login/custom/modules/Accounts/views/view.list.php(16): AccountsListViewSmarty->AccountsListViewSmarty()

#1 /home/WebSource/public_html/login/include/MVC/View/SugarView.php(224): AccountsViewList->preDisplay()

#2 /home/WebSource/public_html/login/include/MVC/Controller/SugarController.php(444): SugarView->process()

#3 /home/WebSource/public_html/login/include/MVC/Controller/SugarController.php(375): SugarController->processView()

#4 /home/WebSource/public_html/login/include/MVC/SugarApplication.php(113): SugarController->execute()

#5 /home/WebSource/public_html/login/index.php(52): SugarApplication->execute()

#6 {main}

thrown in /home/WebSource/public_html/login/custom/modules/Accounts/AccountsListViewSmarty.php on line 10

This sounds really strange to me. The QR&R gets files from some folders and consolidates them into another. But that folder we’re looking at is a source folder in this process, not a destination folder.

So what I would expect to happen is that all files from

Custom/Extension/modules/Schedulers/Ext/ScheduledTasks

get consolidated into a single file in

custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php

Strange. Any ideas to make this system functional again? Or would it be better to pull all of the data out of it and start completely over?

You can try to find out which bit of code is creating the files there, for example, try this from the root of your SuiteCRM installation:

grep -irn AODScheduler .

(that’s a space followed by a dot at the end)

This might give you some clues…