From 749bbcba18052ef88838cc4e197758b34c1b5a8e Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Mon, 11 Mar 2019 09:21:04 +0100 Subject: [PATCH 1/8] retrieve from dolibarr repo --- htdocs/custom/.gitignore | 4 ---- htdocs/custom/README.md | 22 ---------------------- htdocs/custom/index.html | 0 3 files changed, 26 deletions(-) delete mode 100644 htdocs/custom/.gitignore delete mode 100644 htdocs/custom/README.md delete mode 100644 htdocs/custom/index.html diff --git a/htdocs/custom/.gitignore b/htdocs/custom/.gitignore deleted file mode 100644 index 89ebd12182c..00000000000 --- a/htdocs/custom/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/* -!.gitignore -!README.md -!index.html \ No newline at end of file diff --git a/htdocs/custom/README.md b/htdocs/custom/README.md deleted file mode 100644 index 3a486e5a4a8..00000000000 --- a/htdocs/custom/README.md +++ /dev/null @@ -1,22 +0,0 @@ -# DOLIBARR ERP & CRM custom directory for external modules. - -This directory is dedicated to store external modules. -To use it, just copy here the directory of the module into this directory. - -Note: On linux or MAC systems, it is better to unzip/store the external module directory into -a different place than this directory and just adding a symbolic link here to the htdocs directory -of the module. - -For example on Linux OS: Get the module from the command -mkdir ~/git; cd ~/git -git clone https://git.framasoft.org/p/newmodule/newmodule.git -Then create the symbolic link -ln -fs ~/git/newmodule/htdocs /path_to_dolibarr/htdocs/custom/newmodule - -WARNING !!! -Check also that the /custom directory is active by adding into dolibarr conf/conf.php file the following -two lines, so dolibarr will also scan /custom directory to find external external modules: - -$dolibarr_main_url_root_alt='/custom'; -$dolibarr_main_document_root_alt='/path_to_dolibarr/htdocs/custom/'; - diff --git a/htdocs/custom/index.html b/htdocs/custom/index.html deleted file mode 100644 index e69de29bb2d..00000000000 From ff206a3e261ec75e52aed02420b1da08042ccfa9 Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Mon, 11 Mar 2019 10:32:01 +0100 Subject: [PATCH 2/8] custom content was deleted --- htdocs/custom/README.md | 22 ++++++++++++++++++++++ htdocs/custom/index.html | 0 2 files changed, 22 insertions(+) create mode 100644 htdocs/custom/README.md create mode 100644 htdocs/custom/index.html diff --git a/htdocs/custom/README.md b/htdocs/custom/README.md new file mode 100644 index 00000000000..3a486e5a4a8 --- /dev/null +++ b/htdocs/custom/README.md @@ -0,0 +1,22 @@ +# DOLIBARR ERP & CRM custom directory for external modules. + +This directory is dedicated to store external modules. +To use it, just copy here the directory of the module into this directory. + +Note: On linux or MAC systems, it is better to unzip/store the external module directory into +a different place than this directory and just adding a symbolic link here to the htdocs directory +of the module. + +For example on Linux OS: Get the module from the command +mkdir ~/git; cd ~/git +git clone https://git.framasoft.org/p/newmodule/newmodule.git +Then create the symbolic link +ln -fs ~/git/newmodule/htdocs /path_to_dolibarr/htdocs/custom/newmodule + +WARNING !!! +Check also that the /custom directory is active by adding into dolibarr conf/conf.php file the following +two lines, so dolibarr will also scan /custom directory to find external external modules: + +$dolibarr_main_url_root_alt='/custom'; +$dolibarr_main_document_root_alt='/path_to_dolibarr/htdocs/custom/'; + diff --git a/htdocs/custom/index.html b/htdocs/custom/index.html new file mode 100644 index 00000000000..e69de29bb2d From 519672cdc9a5cc4199f6d7a8c1f5a7234adea101 Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Mon, 11 Mar 2019 10:32:55 +0100 Subject: [PATCH 3/8] custom content was deleted --- htdocs/custom/.gitignore | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 htdocs/custom/.gitignore diff --git a/htdocs/custom/.gitignore b/htdocs/custom/.gitignore new file mode 100644 index 00000000000..9420e8c61eb --- /dev/null +++ b/htdocs/custom/.gitignore @@ -0,0 +1,4 @@ +/* +!.gitignore +!README.md +!index.html From be612a1f6e5a7c2aac4006d7f5af786f454f5c76 Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Mon, 11 Mar 2019 12:58:03 +0100 Subject: [PATCH 4/8] harmonize propal index pages --- htdocs/comm/index.php | 62 +++++++++++++++++++++++------------- htdocs/comm/propal/index.php | 32 ++++++++++++------- 2 files changed, 60 insertions(+), 34 deletions(-) diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index e6fc5e95010..2040338f543 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -159,12 +159,13 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) print '
'; print ''; print ''; - print ''; + print ''; if ($num > 0) { $i = 0; - while ($i < $num) + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -190,10 +191,13 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) $i++; $total += $obj->total_ht; } - if ($total>0) + if ($num > $nbofloop) { - - print '"; + print '"; + } + elseif ($total>0) + { + print '"; } } else @@ -245,7 +249,8 @@ if (! empty($conf->supplier_proposal->enabled) && $user->rights->supplier_propos if ($num > 0) { $i = 0; - while ($i < $num) + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -270,9 +275,13 @@ if (! empty($conf->supplier_proposal->enabled) && $user->rights->supplier_propos $i++; $total += $obj->total_ht; } - if ($total>0) + if ($num > $nbofloop) + { + print '"; + } + elseif ($total>0) { - print '"; + print '"; } } else @@ -322,9 +331,9 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) if ($num > 0) { $i = 0; - while ($i < $num) + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + while ($i < $nbofloop) { - $obj = $db->fetch_object($resql); print '"; + print '"; + } + elseif ($total>0) + { + print '"; } } else @@ -409,7 +421,8 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->commande if ($num > 0) { $i = 0; - while ($i < $num) + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -440,10 +453,13 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->commande $i++; $total += $obj->total_ttc; } - if ($total>0) + if ($num > $nbofloop) + { + print '"; + } + elseif ($total>0) { - - print '"; + print '"; } } else @@ -700,7 +716,7 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) print '
'.$langs->trans("ProposalsDraft").($num?' '.$num.'':'').'
'.$langs->trans("ProposalsDraft").' '.$num.'
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("Total").''.price($total)."
'; $orderstatic->id=$obj->rowid; @@ -353,10 +362,13 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) $i++; $total += $obj->total_ttc; } - if ($total>0) + if ($num > $nbofloop) { - - print '
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total").''.price($total)."
'.$langs->trans("Total").''.price($total)."
'; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result); @@ -757,11 +773,11 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) } if ($num > $nbofloop) { - print '"; + print '"; } elseif ($total>0) { - print '"; + print '"; } print "
'.$langs->trans("ProposalsOpened").' '.$num.'
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total")."".price($total)." 
'.$langs->trans("Total")."".price($total)." 
"; print "

"; @@ -804,7 +820,7 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) print ''; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result); @@ -861,11 +877,11 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) } if ($num > $nbofloop) { - print '"; + print '"; } elseif ($total>0) { - print '"; + print '"; } print "
'.$langs->trans("OrdersOpened").' '.$num.'
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total")."".price($total)." 
'.$langs->trans("Total")."".price($total)." 
"; print "
"; diff --git a/htdocs/comm/propal/index.php b/htdocs/comm/propal/index.php index 2bc710394bb..55145381951 100644 --- a/htdocs/comm/propal/index.php +++ b/htdocs/comm/propal/index.php @@ -172,16 +172,18 @@ if (! empty($conf->propal->enabled)) $resql=$db->query($sql); if ($resql) { - print '
'; - print ''; - print ''; - print ''; - $langs->load("propal"); $num = $db->num_rows($resql); if ($num) { + print '
'; + print '
'.$langs->trans("DraftPropals").'
'; + print ''; + $langs->load("propal"); + print ''; + $i = 0; - while ($i < $num) + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + while ($i < $nbofloop) { $obj = $db->fetch_object($resql); print ''; @@ -199,9 +201,17 @@ if (! empty($conf->propal->enabled)) print ''; $i++; } + if ($num > $nbofloop) + { + print '"; + } + elseif ($total>0) + { + print '"; + } + print "
'.$langs->trans("DraftPropals").' '.$num.'
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total").''.price($total)."
"; + print "

"; } - print ""; - print "
"; } } @@ -320,7 +330,7 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire) print ''; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result); @@ -365,11 +375,11 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire) } if ($num > $nbofloop) { - print '"; + print '"; } elseif ($total>0) { - print '"; + print '"; } print "
'.$langs->trans("ProposalsOpened").' '.$num.'
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("XMoreLines", ($num - $nbofloop))."
'.$langs->trans("Total")."".price($total)." 
'.$langs->trans("Total")."".price($total)." 
"; print "
"; From 2726cc335dd6f8e810f1cf5573f39775d0363ff7 Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Tue, 12 Mar 2019 10:24:11 +0100 Subject: [PATCH 5/8] replace align by css align --- htdocs/comm/index.php | 24 ++++++++++++------------ htdocs/comm/propal/index.php | 8 ++++---- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index 2040338f543..1dac0b902c7 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -193,11 +193,11 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total").''.price($total).""; + print ''.$langs->trans("Total").''.price($total).""; } } else @@ -277,11 +277,11 @@ if (! empty($conf->supplier_proposal->enabled) && $user->rights->supplier_propos } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total").''.price($total).""; + print ''.$langs->trans("Total").''.price($total).""; } } else @@ -364,11 +364,11 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total").''.price($total).""; + print ''.$langs->trans("Total").''.price($total).""; } } else @@ -455,11 +455,11 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->commande } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total").''.price($total).""; + print ''.$langs->trans("Total").''.price($total).""; } } else @@ -773,11 +773,11 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total")."".price($total)." "; + print ''.$langs->trans("Total")."".price($total)." "; } print ""; print "
"; @@ -877,11 +877,11 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total")."".price($total)." "; + print ''.$langs->trans("Total")."".price($total)." "; } print ""; print "
"; diff --git a/htdocs/comm/propal/index.php b/htdocs/comm/propal/index.php index 55145381951..122730aee8e 100644 --- a/htdocs/comm/propal/index.php +++ b/htdocs/comm/propal/index.php @@ -203,11 +203,11 @@ if (! empty($conf->propal->enabled)) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total").''.price($total).""; + print ''.$langs->trans("Total").''.price($total).""; } print ""; print "
"; @@ -375,11 +375,11 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire) } if ($num > $nbofloop) { - print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; + print ''.$langs->trans("XMoreLines", ($num - $nbofloop)).""; } elseif ($total>0) { - print ''.$langs->trans("Total")."".price($total)." "; + print ''.$langs->trans("Total")."".price($total)." "; } print ""; print "
"; From d8c1a50291f12f702592eca26d2b76ca60805486 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 18 Mar 2019 10:53:58 +0100 Subject: [PATCH 6/8] Update index.php --- htdocs/comm/index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index 1dac0b902c7..72fee769c09 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -164,7 +164,7 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) if ($num > 0) { $i = 0; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($resql); From 7adba419fc99abe0fb47ee9c0a7a83d8ccef82d1 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 18 Mar 2019 10:54:45 +0100 Subject: [PATCH 7/8] Update index.php --- htdocs/comm/index.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index 72fee769c09..651d2c54ec7 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -249,7 +249,7 @@ if (! empty($conf->supplier_proposal->enabled) && $user->rights->supplier_propos if ($num > 0) { $i = 0; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -331,7 +331,7 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) if ($num > 0) { $i = 0; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -421,7 +421,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->commande if ($num > 0) { $i = 0; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { @@ -716,7 +716,7 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire) print ''; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result); @@ -820,7 +820,7 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire) print '
'.$langs->trans("ProposalsOpened").' '.$num.'
'; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result); From 22d61cd44d6c079f38730e8353d7f9392d1901d3 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 18 Mar 2019 10:55:44 +0100 Subject: [PATCH 8/8] Update index.php --- htdocs/comm/propal/index.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/comm/propal/index.php b/htdocs/comm/propal/index.php index 122730aee8e..e69dbbc8b6c 100644 --- a/htdocs/comm/propal/index.php +++ b/htdocs/comm/propal/index.php @@ -182,7 +182,7 @@ if (! empty($conf->propal->enabled)) print ''; $i = 0; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($resql); @@ -330,7 +330,7 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire) print '
'.$langs->trans("OrdersOpened").' '.$num.'
'.$langs->trans("DraftPropals").' '.$num.'
'; print ''; - $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?5:$conf->global->MAIN_MAXLIST_OVERLOAD)); + $nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?500:$conf->global->MAIN_MAXLIST_OVERLOAD)); while ($i < $nbofloop) { $obj = $db->fetch_object($result);
'.$langs->trans("ProposalsOpened").' '.$num.'