Ejemplo n.º 1
0
 static function setRelatedModules($status)
 {
     global $mod_strings;
     include_once 'vtlib/Vtiger/Module.php';
     $mod_arr = array('Invoice', 'SalesOrder', 'PurchaseOrder', 'Accounts', 'Contacts', 'Vendors', 'Project', 'Potentials');
     if ($status == 'true') {
         foreach ($mod_arr as $module) {
             $status = Accounting::_checkModuleActive($module);
             if ($status == true) {
                 $module = Vtiger_Module::getInstance($module);
                 $module->setRelatedList(Vtiger_Module::getInstance('Accounting'), $mod_strings['LBL_PAYMENTS_INFO'], array('ADD'), 'get_dependents_list');
             }
         }
     } else {
         Accounting::_unsetRelatedList(Vtiger_Module::getInstance('Accounting'));
     }
 }