本文整理汇总了PHP中UnifiedSearchAdvanced类的典型用法代码示例。如果您正苦于以下问题:PHP UnifiedSearchAdvanced类的具体用法?PHP UnifiedSearchAdvanced怎么用?PHP UnifiedSearchAdvanced使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了UnifiedSearchAdvanced类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setUp
public function setUp()
{
global $beanList, $beanFiles;
include 'include/modules.php';
//Reload langauge strings
$GLOBALS['app_strings'] = return_application_language($GLOBALS['current_language']);
$GLOBALS['app_list_strings'] = return_app_list_strings_language($GLOBALS['current_language']);
$GLOBALS['mod_strings'] = return_module_language($GLOBALS['current_language'], 'Accounts');
//Create an anonymous user for login purposes/
$this->_user = new User();
$this->_user->retrieve('1');
$GLOBALS['current_user'] = $this->_user;
self::$helperObject = new APIv3Helper();
if (file_exists(sugar_cached('modules/unified_search_modules.php'))) {
$this->unified_search_modules_content = file_get_contents(sugar_cached('modules/unified_search_modules.php'));
unlink(sugar_cached('modules/unified_search_modules.php'));
}
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$unifiedSearchAdvanced = new UnifiedSearchAdvanced();
$_REQUEST['enabled_modules'] = 'Accounts,Contacts,Opportunities';
$unifiedSearchAdvanced->saveGlobalSearchSettings();
$GLOBALS['db']->query("DELETE FROM accounts WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM opportunities WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM contacts WHERE first_name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM calls WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM tasks WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM meetings WHERE name like 'UNIT TEST%' ");
//$this->useOutputBuffering = false;
}
示例2: display
/**
* @see SugarView::display()
*/
public function display()
{
global $mod_strings;
echo '<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td colspan="100"><h2>' . $this->getModuleTitle(false) . '</h2></td></tr><tr><td colspan="100">' . $mod_strings['LBL_GLOBAL_SEARCH_SETTINGS_TITLE'] . '</td></tr><tr><td><br></td></tr><tr><td colspan="100">';
//echo $this->getModuleTitle();
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$usa = new UnifiedSearchAdvanced();
echo $usa->modifyGlobalSearchSettings();
}
示例3: testFisrtUnifiedSearchWithoutUserPreferences
public function testFisrtUnifiedSearchWithoutUserPreferences()
{
//Enable the Tasks, Accounts and Contacts modules
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$_REQUEST = array();
$_REQUEST['enabled_modules'] = 'Tasks,Accounts,Contacts';
$unifiedSearchAdvanced = new UnifiedSearchAdvanced();
$unifiedSearchAdvanced->saveGlobalSearchSettings();
$_REQUEST = array();
$_REQUEST['advanced'] = 'false';
$unifiedSearchAdvanced->query_stirng = 'blah';
$unifiedSearchAdvanced->search();
global $current_user;
$users_modules = $current_user->getPreference('globalSearch', 'search');
$this->assertTrue(!empty($users_modules), 'Assert we have set the user preferences properly');
$this->assertTrue(isset($users_modules['Tasks']), 'Assert that we have added the Tasks module');
$this->assertEquals(count($users_modules), 3, 'Assert that we have 3 modules in user preferences for global search');
}
示例4: display
/**
* @see SugarView::display()
*/
public function display()
{
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$usa = new UnifiedSearchAdvanced();
global $mod_strings, $app_strings, $app_list_strings;
$sugar_smarty = new Sugar_Smarty();
$sugar_smarty->assign('APP', $app_strings);
$sugar_smarty->assign('MOD', $mod_strings);
$sugar_smarty->assign('moduleTitle', $this->getModuleTitle(false));
$modules = $usa->retrieveEnabledAndDisabledModules();
$sugar_smarty->assign('enabled_modules', json_encode($modules['enabled']));
$sugar_smarty->assign('disabled_modules', json_encode($modules['disabled']));
$tpl = 'modules/Administration/templates/GlobalSearchSettings.tpl';
if (file_exists('custom/' . $tpl)) {
$tpl = 'custom/' . $tpl;
}
echo $sugar_smarty->fetch($tpl);
}
示例5: testBuildCache
/**
* @brief generation of new cache file and search for force_unifiedsearch fields in it
* @group 42961
*/
public function testBuildCache()
{
$beanList = array();
$beanFiles = array();
require 'include/modules.php';
$GLOBALS['beanList'] = $beanList;
$GLOBALS['beanFiles'] = $beanFiles;
$unifiedSearchAdvanced = new UnifiedSearchAdvanced();
$unifiedSearchAdvanced->buildCache();
$this->assertFileExists($GLOBALS['sugar_config']['cache_dir'] . 'modules/unified_search_modules.php', 'Here should be cache file with data');
include $GLOBALS['sugar_config']['cache_dir'] . 'modules/unified_search_modules.php';
$force_unifiedsearch = 0;
foreach ($unified_search_modules as $moduleName => $moduleInformation) {
foreach ($moduleInformation['fields'] as $fieldName => $fieldInformation) {
if (key_exists('force_unifiedsearch', $fieldInformation)) {
$force_unifiedsearch++;
}
}
}
$this->assertGreaterThan(0, $force_unifiedsearch, 'Here should be fields with force_unifiedsearch key');
}
示例6: display
/**
* @see SugarView::display()
*/
public function display()
{
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$usa = new UnifiedSearchAdvanced();
global $mod_strings, $app_strings, $app_list_strings, $current_user;
$sugar_smarty = new Sugar_Smarty();
$sugar_smarty->assign('APP', $app_strings);
$sugar_smarty->assign('MOD', $mod_strings);
$sugar_smarty->assign('moduleTitle', $this->getModuleTitle(false));
$modules = $usa->retrieveEnabledAndDisabledModules();
$sugar_smarty->assign('enabled_modules', json_encode($modules['enabled']));
$sugar_smarty->assign('disabled_modules', json_encode($modules['disabled']));
$defaultEngine = SugarSearchEngineFactory::getFTSEngineNameFromConfig();
$config = $GLOBALS['sugar_config']['full_text_engine'][$defaultEngine];
$justRequestedAScheduledIndex = !empty($_REQUEST['sched']) ? true : false;
$hide_fts_config = isset($GLOBALS['sugar_config']['hide_full_text_engine_config']) ? $GLOBALS['sugar_config']['hide_full_text_engine_config'] : false;
$showSchedButton = $defaultEngine != '' && $this->isFTSConnectionValid() ? true : false;
$sugar_smarty->assign("showSchedButton", $showSchedButton);
$sugar_smarty->assign("hide_fts_config", $hide_fts_config);
$sugar_smarty->assign("fts_type", get_select_options_with_id($app_list_strings['fts_type'], $defaultEngine));
$sugar_smarty->assign("fts_host", $config['host']);
$sugar_smarty->assign("fts_port", $config['port']);
$sugar_smarty->assign("fts_scheduled", !empty($schedulerID) && !$schedulerCompleted);
$sugar_smarty->assign('justRequestedAScheduledIndex', $justRequestedAScheduledIndex);
//End FTS
if (is_admin($current_user)) {
if (!empty($GLOBALS['sugar_config']['fts_disable_notification'])) {
displayAdminError(translate('LBL_FTS_DISABLED', 'Administration'));
}
// if fts indexing is done, show the notification to admin
$admin = Administration::getSettings();
if (!empty($admin->settings['info_fts_index_done'])) {
displayAdminError(translate('LBL_FTS_INDEXING_DONE', 'Administration'));
// reset flag
$admin->saveSetting('info', 'fts_index_done', 0);
}
}
echo $sugar_smarty->fetch(SugarAutoLoader::existingCustomOne('modules/Administration/templates/GlobalSearchSettings.tpl'));
}
示例7: setUp
public function setUp()
{
//Create an anonymous user for login purposes/
$this->_user = SugarTestUserUtilities::createAnonymousUser();
$GLOBALS['current_user'] = $this->_user;
self::$helperObject = new APIv3Helper();
if (file_exists(sugar_cached('modules/unified_search_modules.php'))) {
$this->unified_search_modules_content = file_get_contents(sugar_cached('modules/unified_search_modules.php'));
unlink(sugar_cached('modules/unified_search_modules.php'));
}
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$unifiedSearchAdvanced = new UnifiedSearchAdvanced();
$_REQUEST['enabled_modules'] = 'Accounts,Contacts,Opportunities';
$unifiedSearchAdvanced->saveGlobalSearchSettings();
$GLOBALS['db']->query("DELETE FROM accounts WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM opportunities WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM contacts WHERE first_name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM calls WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM tasks WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->query("DELETE FROM meetings WHERE name like 'UNIT TEST%' ");
$GLOBALS['db']->commit();
//$this->useOutputBuffering = false;
}
示例8: test_create_unified_search_modules_display
public function test_create_unified_search_modules_display()
{
if (file_exists('custom/modules/unified_search_modules_display.php')) {
unlink('custom/modules/unified_search_modules_display.php');
}
require_once 'modules/UpgradeWizard/uw_utils.php';
$usa = new UnifiedSearchAdvanced();
$_REQUEST['enabled_modules'] = 'Accounts,Bug36845Test';
$usa->saveGlobalSearchSettings();
$this->assertTrue(file_exists('custom/modules/unified_search_modules_display.php'), 'Assert that unified_search_modules_display.php file was created');
}
示例9: action_DeployPackage
function action_DeployPackage()
{
if (defined('TEMPLATE_URL')) {
sugar_cache_reset();
SugarTemplateUtilities::disableCache();
}
$mb = new ModuleBuilder();
$load = $_REQUEST['package'];
$message = $GLOBALS['mod_strings']['LBL_MODULE_DEPLOYED'];
if (!empty($load)) {
$zip = $mb->getPackage($load);
require_once 'ModuleInstall/PackageManager/PackageManager.php';
$pm = new PackageManager();
$info = $mb->packages[$load]->build(false);
mkdir_recursive($GLOBALS['sugar_config']['cache_dir'] . '/upload/upgrades/module/');
rename($info['zip'], $GLOBALS['sugar_config']['cache_dir'] . '/' . 'upload/upgrades/module/' . $info['name'] . '.zip');
copy($info['manifest'], $GLOBALS['sugar_config']['cache_dir'] . '/' . 'upload/upgrades/module/' . $info['name'] . '-manifest.php');
$_REQUEST['install_file'] = $GLOBALS['sugar_config']['cache_dir'] . '/' . 'upload/upgrades/module/' . $info['name'] . '.zip';
$GLOBALS['mi_remove_tables'] = false;
$pm->performUninstall($load);
//#23177 , js cache clear
clearAllJsAndJsLangFilesWithoutOutput();
//#30747, clear the cache in memory
$cache_key = 'app_list_strings.' . $GLOBALS['current_language'];
sugar_cache_clear($cache_key);
sugar_cache_reset();
//clear end
$pm->performInstall($_REQUEST['install_file'], true);
//clear the unified_search_module.php file
require_once 'modules/Home/UnifiedSearchAdvanced.php';
UnifiedSearchAdvanced::unlinkUnifiedSearchModulesFile();
}
echo 'complete';
}
示例10: testUserPreferencesSearch
public function testUserPreferencesSearch()
{
global $mod_strings, $modListHeader, $app_strings, $beanList, $beanFiles, $current_user;
require 'config.php';
require 'include/modules.php';
$usa = new UnifiedSearchAdvanced();
$_REQUEST['enabled_modules'] = 'Accounts,Contacts';
$usa->saveGlobalSearchSettings();
$current_user->setPreference('globalSearch', array('Accounts', 'Contacts'), 0, 'search');
$current_user->savePreferencesToDB();
$_REQUEST = array();
$_REQUEST['query_string'] = $this->_contact->first_name . ' ' . $this->_contact->last_name;
$_REQUEST['module'] = 'Home';
$usa->search();
$modules = $current_user->getPreference('globalSearch', 'search');
$this->assertEquals(count($modules), 2, 'Assert that there are two modules in the user preferences as defined from the global search');
$this->assertEquals('Accounts', $modules[0], 'Assert that the Accounts module has been added');
$this->assertEquals('Contacts', $modules[1], 'Assert that the Contacts module has been added');
}
示例11: getSearchModules
/**
* Determine which modules should be searched against.
*
* @return array
*/
protected function getSearchModules()
{
$usa = new UnifiedSearchAdvanced();
$unified_search_modules_display = $usa->getUnifiedSearchModulesDisplay();
// load the list of unified search enabled modules
$modules = array();
//check to see if the user has customized the list of modules available to search
$users_modules = $GLOBALS['current_user']->getPreference('globalSearch', 'search');
if (!empty($users_modules)) {
// use user's previous selections
foreach ($users_modules as $key => $value) {
if (isset($unified_search_modules_display[$key]) && !empty($unified_search_modules_display[$key]['visible'])) {
$modules[$key] = $key;
}
}
} else {
foreach ($unified_search_modules_display as $key => $data) {
if (!empty($data['visible'])) {
$modules[$key] = $key;
}
}
}
// make sure the current module appears first in the list
if (isset($modules[$this->module])) {
unset($modules[$this->module]);
$modules = array_merge(array($this->module => $this->module), $modules);
}
return $modules;
}
示例12: action_saveglobalsearchsettings
/**
* action_saveglobalsearchsettings
*
* This method handles saving the selected modules to display in the Global Search Settings.
* It instantiates an instance of UnifiedSearchAdvanced and then calls the saveGlobalSearchSettings
* method.
*
*/
public function action_saveglobalsearchsettings()
{
global $current_user, $app_strings;
if (!is_admin($current_user)) {
sugar_die($GLOBALS['app_strings']['ERR_NOT_ADMIN']);
}
try {
require_once 'modules/Home/UnifiedSearchAdvanced.php';
$unifiedSearchAdvanced = new UnifiedSearchAdvanced();
$unifiedSearchAdvanced->saveGlobalSearchSettings();
//Save FTS Settings
$type = !empty($_REQUEST['type']) ? $_REQUEST['type'] : '';
$host = !empty($_REQUEST['host']) ? $_REQUEST['host'] : '';
$port = !empty($_REQUEST['port']) ? $_REQUEST['port'] : '';
$ftsConfig = $this->mergeFtsConfig($type, array('port' => $port, 'host' => $host));
$this->cfg = new Configurator();
$this->cfg->config['full_text_engine'] = '';
$this->cfg->saveConfig();
$ftsConnectionValid = TRUE;
if (!empty($type)) {
//Check if the connection is valid on save:
require_once 'include/SugarSearchEngine/SugarSearchEngineFactory.php';
$searchEngine = SugarSearchEngineFactory::getInstance($type, $ftsConfig);
$result = $searchEngine->getServerStatus();
if (!$result['valid']) {
$ftsConnectionValid = FALSE;
}
// bug 54274 -- only bother with an override if we have data to place there, empty string breaks Sugar On-Demand!
$ftsConfig['valid'] = $ftsConnectionValid;
$this->cfg->config['full_text_engine'] = array($type => $ftsConfig);
$this->cfg->handleOverride();
}
// Refresh the server info & module list sections of the metadata
MetaDataManager::refreshSectionCache(array(MetaDataManager::MM_SERVERINFO, MetaDataManager::MM_MODULES));
if (!$ftsConnectionValid) {
echo $GLOBALS['mod_strings']['LBL_FTS_CONNECTION_INVALID'];
} else {
echo "true";
}
} catch (Exception $ex) {
echo "false";
}
}
示例13: search_by_module
/**
* Given a list of modules to search and a search string, return the id, module_name, along with the fields
* We will support Accounts, Bug Tracker, Cases, Contacts, Leads, Opportunities, Project, ProjectTask, Quotes
*
* @param string $session - Session ID returned by a previous call to login.
* @param string $search_string - string to search
* @param string[] $modules - array of modules to query
* @param int $offset - a specified offset in the query
* @param int $max_results - max number of records to return
* @return Array 'entry_list' -- Array('Accounts' => array(array('name' => 'first_name', 'value' => 'John', 'name' => 'last_name', 'value' => 'Do')))
* @exception 'SoapFault' -- The SOAP error, if any
*/
function search_by_module($session, $search_string, $modules, $offset, $max_results)
{
$GLOBALS['log']->info('Begin: SugarWebServiceImpl->search_by_module');
global $beanList, $beanFiles;
global $sugar_config, $current_language;
$error = new SoapError();
$output_list = array();
if (!self::$helperObject->checkSessionAndModuleAccess($session, 'invalid_session', '', '', '', $error)) {
$error->set_error('invalid_login');
$GLOBALS['log']->info('End: SugarWebServiceImpl->search_by_module');
return;
}
global $current_user;
if ($max_results > 0) {
$sugar_config['list_max_entries_per_page'] = $max_results;
}
require_once 'modules/Home/UnifiedSearchAdvanced.php';
require_once 'include/utils.php';
$usa = new UnifiedSearchAdvanced();
if (!file_exists($cachedfile = sugar_cached('modules/unified_search_modules.php'))) {
$usa->buildCache();
}
include $cachedfile;
$modules_to_search = array();
$unified_search_modules['Users'] = array('fields' => array());
$unified_search_modules['ProjectTask'] = array('fields' => array());
foreach ($unified_search_modules as $module => $data) {
if (in_array($module, $modules)) {
$modules_to_search[$module] = $beanList[$module];
}
// if
}
// foreach
$GLOBALS['log']->info('SugarWebServiceImpl->search_by_module - search string = ' . $search_string);
if (!empty($search_string) && isset($search_string)) {
$search_string = trim($GLOBALS['db']->quote(securexss(from_html(clean_string($search_string, 'UNIFIED_SEARCH')))));
foreach ($modules_to_search as $name => $beanName) {
$where_clauses_array = array();
$unifiedSearchFields = array();
foreach ($unified_search_modules[$name]['fields'] as $field => $def) {
$unifiedSearchFields[$name][$field] = $def;
$unifiedSearchFields[$name][$field]['value'] = $search_string;
}
$seed = BeanFactory::getBean($name);
require_once 'include/SearchForm/SearchForm2.php';
if ($beanName == "User" || $beanName == "ProjectTask") {
if (!self::$helperObject->check_modules_access($current_user, $seed->module_dir, 'read')) {
continue;
}
// if
if (!$seed->ACLAccess('ListView')) {
continue;
}
// if
}
if ($beanName != "User" && $beanName != "ProjectTask") {
$searchForm = new SearchForm($seed, $name);
$searchForm->setup(array($name => array()), $unifiedSearchFields, '', 'saved_views');
$where_clauses = $searchForm->generateSearchWhere();
require_once 'include/SearchForm/SearchForm2.php';
$searchForm = new SearchForm($seed, $name);
$searchForm->setup(array($name => array()), $unifiedSearchFields, '', 'saved_views');
$where_clauses = $searchForm->generateSearchWhere();
$emailQuery = false;
$where = '';
if (count($where_clauses) > 0) {
$where = '(' . implode(' ) OR ( ', $where_clauses) . ')';
}
$mod_strings = return_module_language($current_language, $seed->module_dir);
require_once SugarAutoLoader::loadWithMetafiles($seed->module_dir, 'listviewdefs');
$filterFields = array();
foreach ($listViewDefs[$seed->module_dir] as $colName => $param) {
if (!empty($param['default']) && $param['default'] == true) {
$filterFields[] = strtolower($colName);
}
// if
}
// foreach
if (!in_array('id', $filterFields)) {
$filterFields[] = 'id';
}
// if
$ret_array = $seed->create_new_list_query('', $where, $filterFields, array(), 0, '', true, $seed, true);
if (empty($params) or !is_array($params)) {
$params = array();
}
if (!isset($params['custom_select'])) {
$params['custom_select'] = '';
//.........这里部分代码省略.........
示例14: UnifiedSearchAdvanced
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU Affero General Public License version 3.
*
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
********************************************************************************/
/*********************************************************************************
* Description: TODO: To be written.
* Portions created by SugarCRM are Copyright (C) SugarCRM, Inc.
* All Rights Reserved.
* Contributor(s): ______________________________________..
********************************************************************************/
require_once 'modules/Home/UnifiedSearchAdvanced.php';
if (!empty($_REQUEST['usa_form'])) {
$usa = new UnifiedSearchAdvanced();
echo $usa->getDropDownDiv();
} else {
global $mod_strings, $modListHeader, $app_strings, $beanList, $beanFiles;
echo get_module_title("Search", $mod_strings['LBL_SEARCH_RESULTS'], true);
$usa = new UnifiedSearchAdvanced();
$usa->search();
}
示例15: uninstall
function uninstall($base_dir)
{
if (defined('TEMPLATE_URL')) {
SugarTemplateUtilities::disableCache();
}
global $app_strings;
$total_steps = 5;
//min steps with no tasks
$current_step = 0;
$this->base_dir = $base_dir;
$tasks = array('pre_uninstall', 'uninstall_relationships', 'uninstall_copy', 'uninstall_dcactions', 'uninstall_dashlets', 'uninstall_connectors', 'uninstall_layoutfields', 'uninstall_extensions', 'uninstall_global_search', 'disable_manifest_logichooks', 'post_uninstall');
$total_steps += count($tasks);
//now the real number of steps
if (file_exists($this->base_dir . '/manifest.php')) {
if (!$this->silent) {
$current_step++;
display_progress_bar('install', $current_step, $total_steps);
echo '<div id ="displayLoglink" ><a href="#" onclick="toggleDisplay(\'displayLog\')">' . $app_strings['LBL_DISPLAY_LOG'] . '</a> </div><div id="displayLog" style="display:none">';
}
global $moduleList;
include $this->base_dir . '/manifest.php';
$this->installdefs = $installdefs;
$this->id_name = $this->installdefs['id'];
$installed_modules = array();
if (isset($this->installdefs['beans'])) {
foreach ($this->installdefs['beans'] as $bean) {
$installed_modules[] = $bean['module'];
$this->uninstall_user_prefs($bean['module']);
}
$this->modulesInPackage = $installed_modules;
$this->uninstall_beans($installed_modules);
$this->uninstall_customizations($installed_modules);
if (!$this->silent) {
$current_step++;
update_progress_bar('install', $total_steps, $total_steps);
}
}
if (!$this->silent) {
$current_step++;
update_progress_bar('install', $current_step, $total_steps);
}
foreach ($tasks as $task) {
$this->{$task}();
if (!$this->silent) {
$current_step++;
update_progress_bar('install', $current_step, $total_steps);
}
}
if (isset($installdefs['custom_fields']) && (isset($GLOBALS['mi_remove_tables']) && $GLOBALS['mi_remove_tables'])) {
$this->log(translate('LBL_MI_UN_CUSTOMFIELD'));
$this->uninstall_custom_fields($installdefs['custom_fields']);
}
if (!$this->silent) {
$current_step++;
update_progress_bar('install', $current_step, $total_steps);
echo '</div>';
}
//since we are passing $silent = true to rebuildAll() in that method it will set $this->silent = true, so
//we need to save the setting to set it back after rebuildAll() completes.
$silentBak = $this->silent;
$this->rebuild_all(true);
$this->silent = $silentBak;
//#27877, If the request from MB redeploy a custom module , we will not remove the ACL actions for this package.
if (!isset($_REQUEST['action']) || $_REQUEST['action'] != 'DeployPackage') {
$this->remove_acl_actions();
}
//end
if (!$this->silent) {
$current_step++;
update_progress_bar('install', $current_step, $total_steps);
echo '</div>';
}
UpdateSystemTabs('Restore', $installed_modules);
//clear the unified_search_module.php file
require_once 'modules/Home/UnifiedSearchAdvanced.php';
UnifiedSearchAdvanced::unlinkUnifiedSearchModulesFile();
$this->log('<br><b>' . translate('LBL_MI_COMPLETE') . '</b>');
if (!$this->silent) {
update_progress_bar('install', $total_steps, $total_steps);
}
} else {
die("No manifest.php Defined In {$this->base_dir}/manifest.php");
}
}