diff --git a/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php b/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
index e3ca8814a70..e717b92bf14 100644
--- a/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
+++ b/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
@@ -218,7 +218,7 @@ class doc_generic_order_odt extends ModelePDFCommandes
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.(ods|odt)');
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
@@ -228,34 +228,24 @@ class doc_generic_order_odt extends ModelePDFCommandes
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '
';
-
+ $texte.= '
';
+
// Scan directories
if (count($listofdir)) $texte.=$langs->trans("NumberOfModelFilesFound").': '.count($listoffiles).'';
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';
diff --git a/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php b/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
index 4b1433ddd77..6029769afb0 100644
--- a/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
+++ b/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
@@ -208,7 +208,7 @@ class doc_generic_shipment_odt extends ModelePdfExpedition
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.(ods|odt)');
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
@@ -218,34 +218,24 @@ class doc_generic_shipment_odt extends ModelePdfExpedition
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '';
-
+ $texte.= '
';
+
// Scan directories
if (count($listofdir)) $texte.=$langs->trans("NumberOfModelFilesFound").': '.count($listoffiles).'';
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';
diff --git a/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php b/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
index d1642023c24..95484b232e4 100644
--- a/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
+++ b/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
@@ -219,7 +219,7 @@ class doc_generic_invoice_odt extends ModelePDFFactures
$texte.= '';
// List of directories area
- $texte.= '| ';
+ $texte.= ' |
';
$texttitle=$langs->trans("ListOfDirectories");
$listofdir=explode(',',preg_replace('/[\r\n]+/',',',trim($conf->global->FACTURE_ADDON_PDF_ODT_PATH)));
$listoffiles=array();
@@ -243,34 +243,24 @@ class doc_generic_invoice_odt extends ModelePDFFactures
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '';
+ $texte.= ' ';
// Scan directories
if (count($listofdir)) $texte.=$langs->trans("NumberOfModelFilesFound").': '.count($listoffiles).'';
$texte.= ' | ';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '
';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '
';
$texte.= '';
diff --git a/htdocs/core/modules/project/pdf/doc_generic_project_odt.modules.php b/htdocs/core/modules/project/pdf/doc_generic_project_odt.modules.php
index 68cf3de470c..0e7ec535ac6 100644
--- a/htdocs/core/modules/project/pdf/doc_generic_project_odt.modules.php
+++ b/htdocs/core/modules/project/pdf/doc_generic_project_odt.modules.php
@@ -322,7 +322,7 @@ class doc_generic_project_odt extends ModelePDFProjects
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.(ods|odt)');
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
@@ -332,34 +332,24 @@ class doc_generic_project_odt extends ModelePDFProjects
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '';
-
+ $texte.= '
';
+
// Scan directories
if (count($listofdir)) $texte.=$langs->trans("NumberOfModelFilesFound").': '.count($listoffiles).'';
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';
diff --git a/htdocs/core/modules/project/task/pdf/doc_generic_task_odt.modules.php b/htdocs/core/modules/project/task/pdf/doc_generic_task_odt.modules.php
index d9960269d3d..fd63ae5a404 100644
--- a/htdocs/core/modules/project/task/pdf/doc_generic_task_odt.modules.php
+++ b/htdocs/core/modules/project/task/pdf/doc_generic_task_odt.modules.php
@@ -323,7 +323,7 @@ class doc_generic_task_odt extends ModelePDFTask
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.(ods|odt)');
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
@@ -333,34 +333,24 @@ class doc_generic_task_odt extends ModelePDFTask
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '';
-
+ $texte.= '
';
+
// Scan directories
if (count($listofdir)) $texte.=$langs->trans("NumberOfModelFilesFound").': '.count($listoffiles).'';
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';
@@ -431,7 +421,7 @@ class doc_generic_task_odt extends ModelePDFTask
{
//print "srctemplatepath=".$srctemplatepath; // Src filename
$newfile=basename($srctemplatepath);
- $newfiletmp=preg_replace('/\.odt/i','',$newfile);
+ $newfiletmp=preg_replace('/\.(ods|odt)/i','',$newfile);
$newfiletmp=preg_replace('/template_/i','',$newfiletmp);
$newfiletmp=preg_replace('/modele_/i','',$newfiletmp);
$newfiletmp=$objectref.'_'.$newfiletmp;
diff --git a/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php b/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
index 23f0fc020d3..80fb073b964 100644
--- a/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
+++ b/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
@@ -129,7 +129,7 @@ class doc_generic_proposal_odt extends ModelePDFPropales
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
else
{
- $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt');
+ $tmpfiles=dol_dir_list($tmpdir,'files',0,'\.(ods|odt)');
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
}
}
@@ -139,17 +139,14 @@ class doc_generic_proposal_odt extends ModelePDFPropales
$texthelp.=$langs->transnoentitiesnoconv("FullListOnOnlineDocumentation"); // This contains an url, we don't modify it
$texte.= $form->textwithpicto($texttitle,$texthelp,1,'help','',1);
- $texte.= '';
-
+ $texte.= '
';
+
// Scan directories
if (count($listofdir))
{
@@ -181,22 +178,13 @@ class doc_generic_proposal_odt extends ModelePDFPropales
}
}
-
-
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '';
- $texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';
diff --git a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
index 77d1e76eea1..563444a51a3 100644
--- a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
+++ b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
@@ -135,17 +135,11 @@ class doc_generic_odt extends ModeleThirdPartyDoc
$texte.= '';
-
- $texte.= '';
+ $texte.= ' | ';
$texte.= $langs->trans("ExampleOfDirectoriesForModelGen");
$texte.= ' | ';
$texte.= '';
- /*$texte.= '| ';
- $texte.= '';
- $texte.= ' | ';
- $texte.= '
';*/
-
$texte.= '';
$texte.= '';