new config file structuring

This commit is contained in:
Roland Gruber 2012-10-28 15:03:36 +00:00
parent 86e0ad60de
commit 79f9243e1e
3 changed files with 24 additions and 26 deletions

View File

@ -174,8 +174,10 @@ function recursiveCopy($src, $dst, $profiles, $fileFilter = null, $overwrite = t
recursiveCopy($src . '/' . $file, $dst . '/' . $file, $profiles, $fileFilter, $overwrite);
}
elseif ((isset($fileFilter) && (strpos($file, $fileFilter) === 0 || $file == '.htaccess'))
|| (!isset($fileFilter)))
{
|| (!isset($fileFilter))) {
if (!is_file($src . '/' . $file)) {
continue;
}
if ($overwrite || !file_exists($dst . '/' . $file)) {
$tmpState = @copy($src . '/' . $file, $dst . '/' . $file);
if ($tmpState === false) {

View File

@ -197,19 +197,17 @@ include '../main_header.php';
$deleteLink->setOnClick("profileShowDeleteDialog('" . _('Delete') . "', '" . _('Ok') . "', '" . _('Cancel') . "', '" . $templateClasses[$i]['scope'] . "', '" . 'template_' . $templateClasses[$i]['scope'] . "');");
$existingContainer->addElement($deleteLink);
if (count($configProfiles) > 1) {
$importLink = new htmlLink(null, '#', '../../graphics/import.png');
$importLink->setTitle(_('Import PDF structures'));
$importLink->setOnClick("showDistributionDialog('" . _("Import PDF structures") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $templateClasses[$i]['scope'] . "', 'import');");
$existingContainer->addElement($importLink);
$importLink = new htmlLink(null, '#', '../../graphics/import.png');
$importLink->setTitle(_('Import PDF structures'));
$importLink->setOnClick("showDistributionDialog('" . _("Import PDF structures") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $templateClasses[$i]['scope'] . "', 'import');");
$existingContainer->addElement($importLink);
$exportLink = new htmlLink(null, '#', '../../graphics/export.png');
$exportLink->setTitle(_('Export PDF structure'));
$exportLink->setOnClick("showDistributionDialog('" . _("Export PDF structure") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $templateClasses[$i]['scope'] . "', 'export', '" . 'template_' . $templateClasses[$i]['scope'] . "', '" . $_SESSION['config']->getName() . "');");
$existingContainer->addElement($exportLink);
}
$exportLink = new htmlLink(null, '#', '../../graphics/export.png');
$exportLink->setTitle(_('Export PDF structure'));
$exportLink->setOnClick("showDistributionDialog('" . _("Export PDF structure") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $templateClasses[$i]['scope'] . "', 'export', '" . 'template_' . $templateClasses[$i]['scope'] . "', '" . $_SESSION['config']->getName() . "');");
$existingContainer->addElement($exportLink);
$existingContainer->addNewLine();
}
$container->addElement($existingContainer, true);

View File

@ -195,19 +195,17 @@ for ($i = 0; $i < sizeof($profileClasses); $i++) {
$deleteLink->setTitle(_('Delete'));
$deleteLink->setOnClick("profileShowDeleteDialog('" . _('Delete') . "', '" . _('Ok') . "', '" . _('Cancel') . "', '" . $profileClasses[$i]['scope'] . "', '" . 'profile_' . $profileClasses[$i]['scope'] . "');");
$existingContainer->addElement($deleteLink);
if (count($configProfiles) > 1) {
$importLink = new htmlLink(null, '#', '../../graphics/import.png');
$importLink->setTitle(_('Import profiles'));
$importLink->setOnClick("showDistributionDialog('" . _("Import profiles") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $profileClasses[$i]['scope'] . "', 'import');");
$existingContainer->addElement($importLink);
$importLink = new htmlLink(null, '#', '../../graphics/import.png');
$importLink->setTitle(_('Import profiles'));
$importLink->setOnClick("showDistributionDialog('" . _("Import profiles") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $profileClasses[$i]['scope'] . "', 'import');");
$existingContainer->addElement($importLink);
$exportLink = new htmlLink(null, '#', '../../graphics/export.png');
$exportLink->setTitle(_('Export profile'));
$exportLink->setOnClick("showDistributionDialog('" . _("Export profile") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $profileClasses[$i]['scope'] . "', 'export', '" . 'profile_' . $profileClasses[$i]['scope'] . "', '" . $_SESSION['config']->getName() . "');");
$existingContainer->addElement($exportLink);
}
$exportLink = new htmlLink(null, '#', '../../graphics/export.png');
$exportLink->setTitle(_('Export profile'));
$exportLink->setOnClick("showDistributionDialog('" . _("Export profile") . "', '" .
_('Ok') . "', '" . _('Cancel') . "', '" . $profileClasses[$i]['scope'] . "', 'export', '" . 'profile_' . $profileClasses[$i]['scope'] . "', '" . $_SESSION['config']->getName() . "');");
$existingContainer->addElement($exportLink);
$existingContainer->addNewLine();
}
$container->addElement($existingContainer);