From 293a611f3e3b7dc27a946e4c6aac529ead6b2853 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 20 Aug 2006 19:31:30 +0000 Subject: [PATCH] New: Ajout outil de dump par mysqldump --- htdocs/admin/tools/dolibarr_export.php | 11 +++++++++-- htdocs/document.php | 3 ++- htdocs/langs/en_US/admin.lang | 1 + htdocs/langs/fr_FR/admin.lang | 1 + 4 files changed, 13 insertions(+), 3 deletions(-) diff --git a/htdocs/admin/tools/dolibarr_export.php b/htdocs/admin/tools/dolibarr_export.php index 34d0d5ceb44..44abd8ca834 100644 --- a/htdocs/admin/tools/dolibarr_export.php +++ b/htdocs/admin/tools/dolibarr_export.php @@ -32,6 +32,9 @@ $langs->load("admin"); if (! $user->admin) accessforbidden(); + +$html=new Form($db); + llxHeader(); @@ -42,6 +45,10 @@ print '
'; print $langs->trans("DatabaseName").' : '.$dolibarr_main_db_name.'
'; print '
'; +$result=$html->show_documents('systemtools','',DOL_DATA_ROOT.'/admin/temp',$_SERVER['PHP_SELF'],0,1); +if ($result) print '

'; + + ?> @@ -86,7 +93,7 @@ function show_checked_option() {
-Schéma et/ou contenu des bases de données +trans("NewBackup"); ?> @@ -533,7 +540,7 @@ if (function_exists('bz_open'))
-

+ " id="buttonGo" />

diff --git a/htdocs/document.php b/htdocs/document.php index f87c2422b0f..f446494dad3 100644 --- a/htdocs/document.php +++ b/htdocs/document.php @@ -40,8 +40,9 @@ $action = $_GET["action"]; $original_file = urldecode($_GET["file"]); $modulepart = urldecode($_GET["modulepart"]); $urlsource = urldecode($_GET["urlsource"]); -// Défini type et attachment +// Défini type (attachment=1 pour forcer popup 'enregistrer sous') $type = urldecode($_GET["type"]); $attachment = true; +if (eregi('\.sql',$original_file)) { $type='text/plain'; $attachment = true; } if (eregi('\.html',$original_file)) { $type='text/html'; $attachment = false; } if (eregi('\.csv',$original_file)) { $type='text/csv'; $attachment = true; } if (eregi('\.pdf',$original_file)) { $type='application/pdf'; $attachment = true; } diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index 857e3b10e91..3ad754e1f62 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -43,6 +43,7 @@ System=System SystemInfo=System informations SystemTools=System tools SystemToolsArea=System tools area +NewBackup=New backup Backup=Backup Restore=Restore RunCommandSummary=Backup will be done through the following command diff --git a/htdocs/langs/fr_FR/admin.lang b/htdocs/langs/fr_FR/admin.lang index d044adcb901..908c2aa23c7 100644 --- a/htdocs/langs/fr_FR/admin.lang +++ b/htdocs/langs/fr_FR/admin.lang @@ -43,6 +43,7 @@ System=Syst SystemInfo=Infos Système SystemTools=Outils Système SystemToolsArea=Espace outils systèmes +NewBackup=Nouvelle sauvegarde Backup=Sauvegarde Restore=Restauration RunCommandSummary=La sauvegarde sera exécutée par la commande suivante