當前位置: 首頁>>代碼示例>>PHP>>正文


PHP ModuleInstaller::handlePortalConfig方法代碼示例

本文整理匯總了PHP中ModuleInstaller::handlePortalConfig方法的典型用法代碼示例。如果您正苦於以下問題:PHP ModuleInstaller::handlePortalConfig方法的具體用法?PHP ModuleInstaller::handlePortalConfig怎麽用?PHP ModuleInstaller::handlePortalConfig使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在ModuleInstaller的用法示例。


在下文中一共展示了ModuleInstaller::handlePortalConfig方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: loadCleanConfig

    $config_check = $mod_strings['MSG_CONFIG_FILE_READY_FOR_REBUILD'];
    $disable_config_rebuild = '';
    $config_file_ready = true;
} else {
    $config_check = $mod_strings['MSG_MAKE_CONFIG_FILE_WRITABLE'];
}
// only do the rebuild if config file checks out and user has posted back
if (!empty($_POST['perform_rebuild']) && $config_file_ready) {
    // retrieve configuration from file so that contents of config_override.php
    // is not merged (bug #54403)
    $clean_config = loadCleanConfig();
    if (rebuildConfigFile($clean_config, $sugar_version)) {
        $config_check = $mod_strings['MSG_CONFIG_FILE_REBUILD_SUCCESS'];
        $disable_config_rebuild = 'disabled="disabled"';
    } else {
        $config_check = $mod_strings['MSG_CONFIG_FILE_REBUILD_FAILED'];
    }
    require_once 'ModuleInstall/ModuleInstaller.php';
    ModuleInstaller::handleBaseConfig();
    ModuleInstaller::handlePortalConfig();
}
/////////////////////////////////////////////////////////////////////
// TEMPLATE ASSIGNING
$xtpl = new XTemplate('modules/Administration/RebuildConfig.html');
$xtpl->assign('LBL_CONFIG_CHECK', $mod_strings['LBL_CONFIG_CHECK']);
$xtpl->assign('CONFIG_CHECK', $config_check);
$xtpl->assign('LBL_PERFORM_REBUILD', $lbl_rebuild_config);
$xtpl->assign('DISABLE_CONFIG_REBUILD', $disable_config_rebuild);
$xtpl->assign('BTN_PERFORM_REBUILD', $btn_rebuild_config);
$xtpl->parse('main');
$xtpl->out('main');
開發者ID:jglaine,項目名稱:sugar761-ent,代碼行數:31,代碼來源:RebuildConfig.php

示例2: savePortalSettings

 /**
  * Saves Portal settings in the database.
  *
  * @param array $portalConfig an array containing Portal settings to save.
  */
 private function savePortalSettings(array $portalConfig)
 {
     //TODO: Remove after we resolve issues with test associated to this
     $GLOBALS['log']->info('Updating portal config');
     foreach ($portalConfig as $fieldKey => $fieldValue) {
         // TODO: category should be `support`, platform should be `portal`
         $admin = $this->getAdministrationBean();
         if (!$admin->saveSetting('portal', $fieldKey, json_encode($fieldValue), 'support')) {
             $GLOBALS['log']->fatal("Error saving portal config var {$fieldKey}, orig: {$fieldValue} , json:" . json_encode($fieldValue));
         }
     }
     // Verify the existence of the javascript config file
     if (!file_exists('portal2/config.js')) {
         require_once 'ModuleInstall/ModuleInstaller.php';
         ModuleInstaller::handlePortalConfig();
     }
 }
開發者ID:jglaine,項目名稱:sugar761-ent,代碼行數:22,代碼來源:parser.portalconfig.php

示例3: repairPortalConfig

 /**
  * Rebuild the portal javascript config file.
  */
 public function repairPortalConfig()
 {
     require_once 'ModuleInstall/ModuleInstaller.php';
     ModuleInstaller::handlePortalConfig();
 }
開發者ID:jglaine,項目名稱:sugar761-ent,代碼行數:8,代碼來源:QuickRepairAndRebuild.php

示例4: handlePortalConfig

/**
 * handles portal config creation
 */
function handlePortalConfig()
{
    require_once 'ModuleInstall/ModuleInstaller.php';
    return ModuleInstaller::handlePortalConfig();
}
開發者ID:jglaine,項目名稱:sugar761-ent,代碼行數:8,代碼來源:install_utils.php


注:本文中的ModuleInstaller::handlePortalConfig方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。