Example #1
0
function changeTheme($pDB, $smarty, $module_name, $local_templates_dir, $formCampos, $oForm)
{
    $oThemes = new PaloSantoThemes($pDB);
    $tema_actual = $oThemes->getThemeActual();
    $arrTmp['themes'] = $tema_actual;
    $smarty->assign("icon", "modules/{$module_name}/images/system_preferences_themes.png");
    $contenidoModulo = $oForm->fetchForm("{$local_templates_dir}/new.tpl", _tr("Change Theme"), $arrTmp);
    return $contenidoModulo;
}
Example #2
0
function formThemes($smarty, $module_name, $local_templates_dir, $pDB, $arrConf, $uid)
{
    global $arrPermission;
    if (!empty($pDB->errMsg)) {
        $smarty->assign("mb_message", _tr("Error when connecting to database") . "<br/>" . $pDB->errMsg);
    }
    // DefiniciĆ³n del formulario de nueva campaƱa
    $smarty->assign("REQUIRED_FIELD", _tr("Required field"));
    $smarty->assign("CHANGE", _tr("Save"));
    $smarty->assign("icon", "web/apps/{$module_name}/images/system_preferences_themes.png");
    $oThemes = new PaloSantoThemes($pDB);
    $arr_themes = $oThemes->getThemes("/var/www/html/admin/web/themes/");
    $formThemes = createFieldForm($arr_themes);
    $oForm = new paloForm($smarty, $formThemes);
    if (in_array('edit', $arrPermission)) {
        $smarty->assign('EDIT_THEME', true);
    }
    $tema_actual = $oThemes->getThemeActual($uid);
    $arrTmp['themes'] = $tema_actual;
    $contenidoModulo = $oForm->fetchForm("{$local_templates_dir}/new.tpl", _tr("Change Theme"), $arrTmp);
    return $contenidoModulo;
}