diff --git a/htdocs/admin/delais.php b/htdocs/admin/delais.php
index 1ffdbbb4dd8..2390a8c3b76 100644
--- a/htdocs/admin/delais.php
+++ b/htdocs/admin/delais.php
@@ -65,8 +65,9 @@ $form = new Form($db);
$countrynotdefined=''.$langs->trans("ErrorSetACountryFirst").' ('.$langs->trans("SeeAbove").')';
-print_titre($langs->trans("Délais"));
+print_titre($langs->trans("DelaysOfToleranceBeforeWarning"));
+print "
".$langs->transnoentities("DelaysOfToleranceDesc",img_warning())."
\n";
print "
\n";
@@ -94,56 +95,72 @@ if ((isset($_GET["action"]) && $_GET["action"] == 'edit')
$var=true;
print '
';
- print '';
- print '| '.$langs->trans("DolibarrWorkBoard").' | '.$langs->trans("Value").' |
';
+ print '| '.$langs->trans("DolibarrWorkBoard").' | '.$langs->trans("Value").' |
';
$var=true;
$var=!$var;
- //Conversion des secondes en jours
- print '| '.$langs->trans("ActionsToDo").' | ' . $conf->global->MAIN_DELAY_ACTIONS_TODO . ' ' . $langs->trans("days") . ' |
';
- $var=!$var;
- print '| '.$langs->trans("OrdersToProcess").' | ' . $conf->global->MAIN_DELAY_ORDERS_TO_PROCESS . ' ' . $langs->trans("days") . ' |
';
-
- $var=!$var;
- print '| '.$langs->trans("PropalsToClose").' | ' . $conf->global->MAIN_DELAY_PROPALS_TO_CLOSE . ' ' . $langs->trans("days") . ' |
';
-
- $var=!$var;
- print '| '.$langs->trans("PropalsToBill").' | ' . $conf->global->MAIN_DELAY_PROPALS_TO_BILL . ' ' . $langs->trans("days") . ' |
';
-
- $var=!$var;
- print '| '.$langs->trans("BoardNotActivatedServices").' | ' . $conf->global->MAIN_DELAY_NOT_ACTIVATED_SERVICES . ' ' . $langs->trans("days") . ' |
';
+ if (1== 1)
+ {
+ print '| '.$langs->trans("DelaysOfToleranceActionsToDo").' | ' . $conf->global->MAIN_DELAY_ACTIONS_TODO . ' ' . $langs->trans("days") . ' |
';
+ }
- $var=!$var;
- print '| '.$langs->trans("BoardRunningServices").' | ' . $conf->global->MAIN_DELAY_RUNNING_SERVICES . ' ' . $langs->trans("days") . ' |
';
+ if ($conf->commande->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceOrdersToProcess").' | ' . $conf->global->MAIN_DELAY_ORDERS_TO_PROCESS . ' ' . $langs->trans("days") . ' |
';
+ }
+
+ if ($conf->propal->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfTolerancePropalsToClose").' | ' . $conf->global->MAIN_DELAY_PROPALS_TO_CLOSE . ' ' . $langs->trans("days") . ' |
';
+ }
- $var=!$var;
- print '| '.$langs->trans("SupplierBillsToPay").' | ' . $conf->global->MAIN_DELAY_SUPPLIER_BILLS_TO_PAY . ' ' . $langs->trans("days") . ' |
';
+ if ($conf->propal->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfTolerancePropalsToBill").' | ' . $conf->global->MAIN_DELAY_PROPALS_TO_BILL . ' ' . $langs->trans("days") . ' |
';
+ }
+
+ if ($conf->service->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceNotActivatedServices").' | ' . $conf->global->MAIN_DELAY_NOT_ACTIVATED_SERVICES . ' ' . $langs->trans("days") . ' |
';
+ }
- $var=!$var;
- print '| '.$langs->trans("CustomerBillsUnpayed").' | ' . $conf->global->MAIN_DELAY_CUSTOMER_BILLS_UNPAYED . ' ' . $langs->trans("days") . ' |
';
+ if ($conf->service->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceRunningServices").' | ' . $conf->global->MAIN_DELAY_RUNNING_SERVICES . ' ' . $langs->trans("days") . ' |
';
+ }
- $var=!$var;
- print '| '.$langs->trans("TransactionsToConciliate").' | ' . $conf->global->MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE . ' ' . $langs->trans("days") . ' |
';
+ if ($conf->fournisseur->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceSupplierBillsToPay").' | ' . $conf->global->MAIN_DELAY_SUPPLIER_BILLS_TO_PAY . ' ' . $langs->trans("days") . ' |
';
+ }
+
+ if ($conf->facture->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceCustomerBillsUnpayed").' | ' . $conf->global->MAIN_DELAY_CUSTOMER_BILLS_UNPAYED . ' ' . $langs->trans("days") . ' |
';
+ }
-$var=!$var;
- print '| '.$langs->trans("Members").' | ' . $conf->global->MAIN_DELAY_MEMBERS . ' ' . $langs->trans("days") . ' |
';
+ if ($conf->banque->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceTransactionsToConciliate").' | ' . $conf->global->MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE . ' ' . $langs->trans("days") . ' |
';
+ }
+
+ if ($conf->adherent->enabled)
+ {
+ $var=!$var;
+ print '| '.$langs->trans("DelaysOfToleranceMembers").' | ' . $conf->global->MAIN_DELAY_MEMBERS . ' ' . $langs->trans("days") . ' |
';
+ }
print '
';
- print '';
print '
'.$langs->trans("Edit").'';
diff --git a/htdocs/includes/menus/barre_left/eldy_backoffice.php b/htdocs/includes/menus/barre_left/eldy_backoffice.php
index d1da8053089..be4337521bc 100644
--- a/htdocs/includes/menus/barre_left/eldy_backoffice.php
+++ b/htdocs/includes/menus/barre_left/eldy_backoffice.php
@@ -117,6 +117,8 @@ class MenuLeft {
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/ihm.php", $langs->trans("GUISetup"));
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/modules.php", $langs->trans("Modules"));
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/boxes.php", $langs->trans("Boxes"));
+ if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/delais.php",$langs->trans("DelaysBeforeWarning"));
+
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/triggers.php", $langs->trans("Triggers"));
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/perms.php", $langs->trans("DefaultRights"));
if ($leftmenu=="setup") $newmenu->add_submenu(DOL_URL_ROOT."/admin/dict.php", $langs->trans("DictionnarySetup"));
diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang
index e93a2f4d74b..8187d33a798 100644
--- a/htdocs/langs/en_US/admin.lang
+++ b/htdocs/langs/en_US/admin.lang
@@ -278,6 +278,19 @@ ShowBugTrackLink=Show link "Report a bug"
ShowWorkBoard=Show "work board" on home page
Delays=Delays
DelayBeforeWarning=Delay before warning
+DelaysBeforeWarning=Delays before warning
+DelaysOfToleranceBeforeWarning=Tolerance delays before warning
+DelaysOfToleranceDesc=Cet écran permet de définir les délais de tolérance avant lesquels une alerte sera signalée à l'écran par le picto %s, sur chaque élément en retard.
+DelaysOfToleranceActionsToDo=Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées
+DelaysOfToleranceOrdersToProcess=Tolérance de retard avant alerte (en jours) sur commandes non traitées
+DelaysOfTolerancePropalsToClose=Tolérance de retard avant alerte (en jours) sur propales à cloturer
+DelaysOfTolerancePropalsToBill=Tolérance de retard avant alerte (en jours) sur propales non facturées
+DelaysOfToleranceNotActivatedServices=Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées
+DelaysOfToleranceRunningServices=Tolérance de retard avant alerte (en jours) sur factures client impayées
+DelaysOfToleranceSupplierBillsToPay=Tolérance de retard avant alerte (en jours) sur services à activer
+DelaysOfToleranceCustomerBillsUnpayed=Tolérance de retard avant alerte (en jours) sur services expirés
+DelaysOfToleranceTransactionsToConciliate=Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard
+DelaysOfToleranceMembers=Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire
##### Users setup #####
UserGroupSetup=Users and groups module setup
GeneratePassword=Générer mot de passe
diff --git a/htdocs/langs/fr_FR/admin.lang b/htdocs/langs/fr_FR/admin.lang
index 223d220e10c..af25339f368 100644
--- a/htdocs/langs/fr_FR/admin.lang
+++ b/htdocs/langs/fr_FR/admin.lang
@@ -278,6 +278,19 @@ ShowBugTrackLink=Afficher le lien "Signaler un bug"
ShowWorkBoard=Affiche le tableau de bord de travail sur page accueil
Delays=Délais
DelayBeforeWarning=Délai avant alerte
+DelaysBeforeWarning=Délais avant alerte
+DelaysOfToleranceBeforeWarning=Délais de tolérance avant alerte
+DelaysOfToleranceDesc=Cet écran permet de définir les délais de tolérance avant lesquels une alerte sera signalée à l'écran par le picto %s, sur chaque élément en retard.
+DelaysOfToleranceActionsToDo=Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées
+DelaysOfToleranceOrdersToProcess=Tolérance de retard avant alerte (en jours) sur commandes non traitées
+DelaysOfTolerancePropalsToClose=Tolérance de retard avant alerte (en jours) sur propales à cloturer
+DelaysOfTolerancePropalsToBill=Tolérance de retard avant alerte (en jours) sur propales non facturées
+DelaysOfToleranceNotActivatedServices=Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées
+DelaysOfToleranceRunningServices=Tolérance de retard avant alerte (en jours) sur factures client impayées
+DelaysOfToleranceSupplierBillsToPay=Tolérance de retard avant alerte (en jours) sur services à activer
+DelaysOfToleranceCustomerBillsUnpayed=Tolérance de retard avant alerte (en jours) sur services expirés
+DelaysOfToleranceTransactionsToConciliate=Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard
+DelaysOfToleranceMembers=Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire
##### Users setup #####
UserGroupSetup=Configuration module utilisateurs et groupes
GeneratePassword=Générer mot de passe
diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php
index 3f7fe8cd5fc..edcfa2751ad 100644
--- a/htdocs/master.inc.php
+++ b/htdocs/master.inc.php
@@ -397,18 +397,17 @@ if (defined("MAIN_MAIL_NEW_SUBJECT"))
*/
$conf->compta->tva=1;
-// Delai de tolerance des alertes
-$conf->actions->warning_delay=MAIN_DELAY_ACTIONS_TODO*24*60*60;
-$conf->commande->traitement->warning_delay=MAIN_DELAY_ORDERS_TO_PROCESS*24*60*60;
-$conf->propal->cloture->warning_delay=MAIN_DELAY_PROPALS_TO_CLOSE*24*60*60;
-$conf->propal->facturation->warning_delay=MAIN_DELAY_PROPALS_TO_BILL*24*60*60;
-$conf->facture->fournisseur->warning_delay=MAIN_DELAY_SUPPLIER_BILLS_TO_PAY*24*60*60;
-$conf->facture->client->warning_delay=MAIN_DELAY_CUSTOMER_BILLS_UNPAYED*24*60*60;
-$conf->contrat->services->inactifs->warning_delay=MAIN_DELAY_NOT_ACTIVATED_SERVICES*24*60*60;
-$conf->contrat->services->expires->warning_delay=MAIN_DELAY_RUNNING_SERVICES*24*60*60;
-$conf->adherent->cotisation->warning_delay=MAIN_DELAY_MEMBERS*24*60*60;
-$conf->bank->rappro->warning_delay=MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE*24*60*60;
-
+// Delais de tolerance des alertes
+$conf->actions->warning_delay=$conf->global->MAIN_DELAY_ACTIONS_TODO*24*60*60;
+$conf->commande->traitement->warning_delay=$conf->global->MAIN_DELAY_ORDERS_TO_PROCESS*24*60*60;
+$conf->propal->cloture->warning_delay=$conf->global->MAIN_DELAY_PROPALS_TO_CLOSE*24*60*60;
+$conf->propal->facturation->warning_delay=$conf->global->MAIN_DELAY_PROPALS_TO_BILL*24*60*60;
+$conf->facture->fournisseur->warning_delay=$conf->global->MAIN_DELAY_SUPPLIER_BILLS_TO_PAY*24*60*60;
+$conf->facture->client->warning_delay=$conf->global->MAIN_DELAY_CUSTOMER_BILLS_UNPAYED*24*60*60;
+$conf->contrat->services->inactifs->warning_delay=$conf->global->MAIN_DELAY_NOT_ACTIVATED_SERVICES*24*60*60;
+$conf->contrat->services->expires->warning_delay=$conf->global->MAIN_DELAY_RUNNING_SERVICES*24*60*60;
+$conf->adherent->cotisation->warning_delay=$conf->global->MAIN_DELAY_MEMBERS*24*60*60;
+$conf->bank->rappro->warning_delay=$conf->global->MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE*24*60*60;
/*
diff --git a/mysql/migration/1.1.0-2.0.0.sql b/mysql/migration/1.1.0-2.0.0.sql
index 885204ba315..70c76b13a31 100644
--- a/mysql/migration/1.1.0-2.0.0.sql
+++ b/mysql/migration/1.1.0-2.0.0.sql
@@ -700,16 +700,16 @@ create table llx_paiement_facture
insert into llx_const(name, value, type, note, visible) values ('MAIN_UPLOAD_DOC','1','chaine','Authorise l\'upload de document',0);
insert into llx_const(name, value, type, note, visible) values ('MAIN_SEARCHFORM_PRODUITSERVICE','1','yesno','Affichage formulaire de recherche des Produits et Services dans la barre de gauche',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_ACTIONS_TODO','7','chaine','Tolérance de retard en jours (avant alerte) sur actions planifiées non réalisées',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_ORDERS_TO_PROCESS','2','chaine','Tolérance de retard en jours (avant alerte) sur commandes non traitées',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_PROPALS_TO_CLOSE','31','chaine','Tolérance de retard en jours (avant alerte) sur propales à cloturer',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_PROPALS_TO_BILL','7','chaine','Tolérance de retard en jours (avant alerte) sur propales non facturées',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_SUPPLIER_BILLS_TO_PAY','2','chaine','Tolérance de retard en jours (avant alerte) sur factures fournisseur impayées',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_CUSTOMER_BILLS_UNPAYED','31','chaine','Tolérance de retard en jours (avant alerte) sur factures client impayées',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_NOT_ACTIVATED_SERVICES','0','chaine','Tolérance de retard en jours (avant alerte) sur services à activer',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_RUNNING_SERVICES','0','chaine','Tolérance de retard en jours (avant alerte) sur services expirés',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_MEMBERS','31','chaine','Tolérance de retard en jours (avant alerte) sur cotisations adhérent en retard',0);
-insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE','62','chaine','Tolérance de retard en jours (avant alerte) sur rapprochements bancaires à faire',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_ACTIONS_TODO','7','chaine','Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_ORDERS_TO_PROCESS','2','chaine','Tolérance de retard avant alerte (en jours) sur commandes non traitées',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_PROPALS_TO_CLOSE','31','chaine','Tolérance de retard avant alerte (en jours) sur propales à cloturer',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_PROPALS_TO_BILL','7','chaine','Tolérance de retard avant alerte (en jours) sur propales non facturées',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_SUPPLIER_BILLS_TO_PAY','2','chaine','Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_CUSTOMER_BILLS_UNPAYED','31','chaine','Tolérance de retard avant alerte (en jours) sur factures client impayées',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_NOT_ACTIVATED_SERVICES','0','chaine','Tolérance de retard avant alerte (en jours) sur services à activer',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_RUNNING_SERVICES','0','chaine','Tolérance de retard avant alerte (en jours) sur services expirés',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_MEMBERS','31','chaine','Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard',0);
+insert into llx_const (name, value, type, note, visible) values ('MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE','62','chaine','Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire',0);
delete from llx_const where name = 'COMPTA_BANK_FACTURES';
update llx_const set visible='0' where name='MAIN_UPLOAD_DOC';