From 5fe70e0bee9b0db765ac644b4293aba0c65bd3af Mon Sep 17 00:00:00 2001 From: simnandez Date: Mon, 13 May 2013 17:15:23 +0200 Subject: [PATCH 01/11] Fix: Some bugs on withdrawal rejects --- ChangeLog | 1 + .../class/rejetprelevement.class.php | 4 +- htdocs/compta/prelevement/ligne.php | 57 +++++++++++++------ htdocs/langs/ca_ES/errors.lang | 1 + htdocs/langs/en_US/errors.lang | 1 + htdocs/langs/es_ES/errors.lang | 1 + htdocs/langs/fr_FR/errors.lang | 1 + 7 files changed, 46 insertions(+), 20 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8a6f62aacbf..9ceddc61d1a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -12,6 +12,7 @@ English Dolibarr ChangeLog - Fix: Can't reset payment due date - Fix: Orderstoinvoice didn't act as expected when no order was checked - Fix: Bad link to all proposals into Third party card if customer is prospect +- Fix: Some bugs on withdrawal rejects - Fix: [ bug #774 ] Bug on creating event with box "all day" crossed - Fix: [ bug #787 ] Invoice supplier box incorrect tooltip when delay on payment - Fix: [ bug #789 ] VAT not being calculated in POS diff --git a/htdocs/compta/prelevement/class/rejetprelevement.class.php b/htdocs/compta/prelevement/class/rejetprelevement.class.php index a6b37df813d..543c0cdbab5 100644 --- a/htdocs/compta/prelevement/class/rejetprelevement.class.php +++ b/htdocs/compta/prelevement/class/rejetprelevement.class.php @@ -1,7 +1,7 @@ * Copyright (C) 2005-2009 Regis Houssin - * Copyright (C) 2010-2011 Juanjo Menent + * Copyright (C) 2010-2013 Juanjo Menent * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -50,7 +50,7 @@ class RejetPrelevement $this->motifs = array(); $this->facturer = array(); - $this->motifs[0] = $langs->trans("StatusMotif0"); + $this->motifs[0] = ""; //$langs->trans("StatusMotif0"); $this->motifs[1] = $langs->trans("StatusMotif1"); $this->motifs[2] = $langs->trans("StatusMotif2"); $this->motifs[3] = $langs->trans("StatusMotif3"); diff --git a/htdocs/compta/prelevement/ligne.php b/htdocs/compta/prelevement/ligne.php index d2c8c71e62a..06b147cb120 100644 --- a/htdocs/compta/prelevement/ligne.php +++ b/htdocs/compta/prelevement/ligne.php @@ -2,7 +2,7 @@ /* Copyright (C) 2005 Rodolphe Quiedeville * Copyright (C) 2005-2012 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin - * Copyright (C) 2010-2012 Juanjo Menent + * Copyright (C) 2010-2013 Juanjo Menent * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -50,29 +50,49 @@ if ($action == 'confirm_rejet') { if ( GETPOST("confirm") == 'yes') { - $daterej = mktime(2, 0, 0, GETPOST('remonth','int'), GETPOST('reday','int'), GETPOST('reyear','int')); - - $lipre = new LignePrelevement($db, $user); - - if ($lipre->fetch($id) == 0) + if (GETPOST('remonth','int')) { + $daterej = mktime(2, 0, 0, GETPOST('remonth','int'), GETPOST('reday','int'), GETPOST('reyear','int')); + } - if (GETPOST('motif','alpha') > 0 && $daterej < time()) + if (empty($daterej)) + { + $error++; + setEventMessage($langs->trans("ErrorFieldRequired",$langs->trans("Date")),'errors'); + } + + elseif ($daterej > dol_now()) + { + $error++; + $langs->load("error"); + setEventMessage($langs->transnoentities("ErrorDateMustBeBeforeToday"),'errors'); + } + + if (GETPOST('motif','alpha') == 0) + { + $error++; + setEventMessage($langs->trans("ErrorFieldRequired",$langs->transnoentities("RefusedReason")),'errors'); + } + + if ( ! $error ) + { + $lipre = new LignePrelevement($db, $user); + + if ($lipre->fetch($id) == 0) + { $rej = new RejetPrelevement($db, $user); - + $rej->create($user, $id, GETPOST('motif','alpha'), $daterej, $lipre->bon_rowid, GETPOST('facturer','int')); header("Location: ligne.php?id=".$id); exit; } - else - { - dol_syslog("Motif : ".GETPOST('motif','alpha')); - dol_syslog("$daterej $time "); - header("Location: ligne.php?id=".$id."&action=rejet"); - exit; - } + + } + else + { + $action="rejet"; } } else @@ -173,13 +193,13 @@ if ($id) print ''; //Date - print ''.$langs->trans("RefusedData").''; + print ''.$langs->trans("RefusedData").''; print ''; print $form->select_date('','','','','',"confirm_rejet"); print ''; //Reason - print ''.$langs->trans("RefusedReason").''; + print ''.$langs->trans("RefusedReason").''; print ''; print $form->selectarray("motif", $rej->motifs); print ''; @@ -303,8 +323,9 @@ if ($id) dol_print_error($db); } - $db->close(); } llxFooter(); + +$db->close(); ?> diff --git a/htdocs/langs/ca_ES/errors.lang b/htdocs/langs/ca_ES/errors.lang index 18bdab951c3..e41e6e18e6d 100644 --- a/htdocs/langs/ca_ES/errors.lang +++ b/htdocs/langs/ca_ES/errors.lang @@ -112,6 +112,7 @@ ErrorPhpCurlNotInstalled=L'extensió PHP CURL no es troba instal·lada, és indi ErrorFailedToAddToMailmanList=S'ha produït un error en intentar afegir un registre a la llista Mailman o base de dades SPIP ErrorNewVaueCantMatchOldValue=El Nou valor no pot ser igual al antic ErrorFailedToValidatePasswordReset=No s'ha pogut restablir la contrasenya. És possible que aquest enllaç ja s'hagi utilitzat (aquest enllaç només es pot utilitzar una vegada). Si no és el cas prova de reiniciar el procés de restabliment de contrasenya des del principi. +ErrorDateMustBeBeforeToday=La data no pot ser superior a avui # Warnings WarningSafeModeOnCheckExecDir=Atenció, està activada l'opció PHP safe_mode, la comanda ha d'estar dins d'un directori declarat dins del paràmetre php safe_mode_exec_dir. diff --git a/htdocs/langs/en_US/errors.lang b/htdocs/langs/en_US/errors.lang index f034287a880..31bcf96c605 100644 --- a/htdocs/langs/en_US/errors.lang +++ b/htdocs/langs/en_US/errors.lang @@ -116,6 +116,7 @@ ErrorPhpCurlNotInstalled=The PHP CURL is not installed, this is essential to tal ErrorFailedToAddToMailmanList=Failed to add record to Mailman list or SPIP base ErrorNewVaueCantMatchOldValue=New value can't be equal to old one ErrorFailedToValidatePasswordReset=Failed to reinit password. May be the reinit was already done (this link can be used only one time). If not, try to restart the reinit process. +ErrorDateMustBeBeforeToday=The date can not be greater than today # Warnings WarningMandatorySetupNotComplete=Mandatory setup parameters are not yet defined diff --git a/htdocs/langs/es_ES/errors.lang b/htdocs/langs/es_ES/errors.lang index afb31dd4269..e3f46039254 100644 --- a/htdocs/langs/es_ES/errors.lang +++ b/htdocs/langs/es_ES/errors.lang @@ -113,6 +113,7 @@ ErrorPhpCurlNotInstalled=La extensión PHP CURL no se encuentra instalada, es in ErrorFailedToAddToMailmanList=Ha ocurrido un error al intentar añadir un registro a la lista Mailman o base de datos SPIP ErrorNewVaueCantMatchOldValue=El nuevo valor no puede ser igual al antiguo ErrorFailedToValidatePasswordReset=No se ha podido restablecer la contraseña. Es posible que este enlace ya se haya utilizado (este enlace sólo puede usarse una vez). Si no es el caso, trate de reiniciar el proceso de restablecimiento de contraseña desde el principio. +ErrorDateMustBeBeforeToday=La fecha no puede ser superior a hoy # Warnings WarningMandatorySetupNotComplete=Los parámetros obligatorios de configuración no están todavía definidos diff --git a/htdocs/langs/fr_FR/errors.lang b/htdocs/langs/fr_FR/errors.lang index f683af9b736..642364fc36d 100644 --- a/htdocs/langs/fr_FR/errors.lang +++ b/htdocs/langs/fr_FR/errors.lang @@ -117,6 +117,7 @@ ErrorPhpCurlNotInstalled=L'extension PHP CURL n'est pas installée, ceci est ind ErrorFailedToAddToMailmanList=Echec de l'ajout à une liste Mailman ou base SPIP ErrorNewVaueCantMatchOldValue=La nouvelle valeur ne peut être égale à l'ancienne ErrorFailedToValidatePasswordReset=Echec de la réinitialisation du mot de passe. Il est possible que ce lien ait déjà été utilisé (l'utilisation de ce lien ne fonctionne qu'une fois). Si ce n'est pas le cas, essayer de recommencer le processus de réinit de mot de passe depuis le début. +ErrorDateMustBeBeforeToday=La date ne peut pas être supérieure à aujourd'hui # Warnings WarningMandatorySetupNotComplete=Les informations de configuration obligatoire doivent être renseignées From f9e0d03b0c1a12c5c6651f42543b3d9a16281ce0 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 14 May 2013 02:46:00 +0200 Subject: [PATCH 02/11] Fix: Do not show busy if event not assigned to a user. --- htdocs/comm/action/fiche.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/comm/action/fiche.php b/htdocs/comm/action/fiche.php index f230ba1a95b..8b93bf23590 100644 --- a/htdocs/comm/action/fiche.php +++ b/htdocs/comm/action/fiche.php @@ -932,7 +932,7 @@ if ($id > 0) // Busy print ''.$langs->trans("Busy").''; - print yn(($act->transparency > 0)?1:0); + if ($act->usertodo->id > 0) print yn(($act->transparency > 0)?1:0); // We show nothing if event is assigned to nobody print ''; // Done by From 551bcba826c9049667c2f2bd2f762ff0fe00f46e Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 14 May 2013 10:51:09 +0200 Subject: [PATCH 03/11] Fix: Try to avoid warning --- htdocs/core/lib/company.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/lib/company.lib.php b/htdocs/core/lib/company.lib.php index aa7339cb7ca..dddc5610609 100644 --- a/htdocs/core/lib/company.lib.php +++ b/htdocs/core/lib/company.lib.php @@ -46,7 +46,7 @@ function societe_prepare_head($object) if ($object->client==1 || $object->client==2 || $object->client==3) { $head[$h][0] = DOL_URL_ROOT.'/comm/fiche.php?socid='.$object->id; - $head[$h][1]=''; + $head[$h][1] = ''; if (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) && ($object->client==2 || $object->client==3)) $head[$h][1] .= $langs->trans("Prospect"); if (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) && empty($conf->global->SOCIETE_DISABLE_CUSTOMERS) && $object->client==3) $head[$h][1] .= '/'; if (empty($conf->global->SOCIETE_DISABLE_CUSTOMERS) && ($object->client==1 || $object->client==3)) $head[$h][1] .= $langs->trans("Customer"); From d2aacdb04bdfcd99870ca7c987f004fe98335c51 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 14 May 2013 15:58:20 +0200 Subject: [PATCH 04/11] Fix: avoid error when multiple files uploaded --- htdocs/core/tpl/ajax/fileupload_main.tpl.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/core/tpl/ajax/fileupload_main.tpl.php b/htdocs/core/tpl/ajax/fileupload_main.tpl.php index be6906faf04..b7437af4616 100644 --- a/htdocs/core/tpl/ajax/fileupload_main.tpl.php +++ b/htdocs/core/tpl/ajax/fileupload_main.tpl.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2011-2013 Regis Houssin * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -44,7 +44,7 @@ $(function () { // Events $('#fileupload').fileupload({ - completed: function (e, data) { + stop: function (e, data) { location.href=''; }, destroy: function (e, data) { From d92b46c9f91510f8089bc952965c4331dbca70a0 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 14 May 2013 23:39:17 +0200 Subject: [PATCH 05/11] Fix: Label missing Fix: Cancel not working --- htdocs/compta/tva/fiche.php | 36 +++++++++++++++++++++++------------- 1 file changed, 23 insertions(+), 13 deletions(-) diff --git a/htdocs/compta/tva/fiche.php b/htdocs/compta/tva/fiche.php index a95f7b85963..a31b4030b65 100644 --- a/htdocs/compta/tva/fiche.php +++ b/htdocs/compta/tva/fiche.php @@ -31,7 +31,8 @@ $langs->load("compta"); $langs->load("banks"); $langs->load("bills"); -$id=$_REQUEST["id"]; +$id=GETPOST("id"); +$action=GETPOST('action'); $mesg = ''; @@ -40,17 +41,25 @@ $socid = isset($_GET["socid"])?$_GET["socid"]:''; if ($user->societe_id) $socid=$user->societe_id; $result = restrictedArea($user, 'tax', '', '', 'charges'); +$tva = new Tva($db); + // Initialize technical object to manage hooks of thirdparties. Note that conf->hooks_modules contains array array $hookmanager->initHooks(array('taxvatcard')); -/** - * Action ajout paiement tva - */ -if ($_POST["action"] == 'add' && $_POST["cancel"] <> $langs->trans("Cancel")) -{ - $tva = new Tva($db); +/** + * Actions + */ + +if ($_POST["cancel"] == $langs->trans("Cancel")) +{ + header("Location: reglement.php"); + exit; +} + +if ($action == 'add' && $_POST["cancel"] <> $langs->trans("Cancel")) +{ $db->begin(); $datev=dol_mktime(12,0,0, $_POST["datevmonth"], $_POST["datevday"], $_POST["datevyear"]); @@ -74,13 +83,12 @@ if ($_POST["action"] == 'add' && $_POST["cancel"] <> $langs->trans("Cancel")) { $db->rollback(); $mesg='
'.$tva->error.'
'; - $_GET["action"]="create"; + $action="create"; } } -if ($_GET["action"] == 'delete') +if ($action == 'delete') { - $tva = new Tva($db); $result=$tva->fetch($_GET['id']); if ($tva->rappro == 0) @@ -143,7 +151,7 @@ if ($id) } // Formulaire saisie tva -if ($_GET["action"] == 'create') +if ($action == 'create') { print "
\n"; print ''; @@ -223,6 +231,9 @@ if ($id) print $vatpayment->ref; print ''; + // Label + print ''.$langs->trans("Label").''.$vatpayment->label.''; + print ""; print ''.$langs->trans("DatePayment").''; print dol_print_date($vatpayment->datep,'day'); @@ -273,5 +284,4 @@ if ($id) $db->close(); llxFooter(); - -?> +?> \ No newline at end of file From a8e260da847769cffb118657f1792b3611698032 Mon Sep 17 00:00:00 2001 From: Grand Philippe Date: Wed, 15 May 2013 15:28:53 +0200 Subject: [PATCH 06/11] fix some language issue --- .../email_unpaid_invoices_to_representatives.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/invoices/email_unpaid_invoices_to_representatives.php b/scripts/invoices/email_unpaid_invoices_to_representatives.php index 8999d41604c..21bcc98e0c9 100755 --- a/scripts/invoices/email_unpaid_invoices_to_representatives.php +++ b/scripts/invoices/email_unpaid_invoices_to_representatives.php @@ -47,7 +47,7 @@ if (! isset($argv[1]) || ! $argv[1] || ! in_array($argv[1],array('test','confirm $mode=$argv[1]; -require($path."../../htdocs/master.inc.php"); +require($path."../../httpdocs/master.inc.php"); require_once (DOL_DOCUMENT_ROOT."/core/class/CMailFile.class.php"); $langs->load('main'); @@ -137,10 +137,10 @@ if ($resql) { envoi_mail($mode,$oldemail,$message,$total,$oldlang,$oldsalerepresentative); } - else - { - if ($oldemail != 'none') print "- No email sent for ".$oldsalerepresentative.", total: ".$total."\n"; - } + else + { + if ($oldemail != 'none') print "- No email sent for ".$oldsalerepresentative.", total: ".$total."\n"; + } } } else @@ -175,7 +175,7 @@ function envoi_mail($mode,$oldemail,$message,$total,$userlang,$oldsalerepresenta $newlangs->load("main"); $newlangs->load("bills"); - $subject = "[".(empty($conf->global->MAIN_APPLICATION_TITLE)?'Dolibarr':$conf->global->MAIN_APPLICATION_TITLE)."] ".$newlangs->trans("ListOfYourUnpaidInvoices"); + $subject = "[".(empty($conf->global->MAIN_APPLICATION_TITLE)?'Dolibarr':$conf->global->MAIN_APPLICATION_TITLE)."] ".$newlangs->transnoentities("ListOfYourUnpaidInvoices"); $sendto = $oldemail; $from = $conf->global->MAIN_MAIL_EMAIL_FROM; $errorsto = $conf->global->MAIN_MAIL_ERRORS_TO; @@ -195,7 +195,7 @@ function envoi_mail($mode,$oldemail,$message,$total,$userlang,$oldsalerepresenta } else { - $allmessage.= "List of unpaid invoices".($usehtml?"
\n":"\n").($usehtml?"
\n":"\n"); + $allmessage.= $newlangs->transnoentities("ListOfYourUnpaidInvoices").($usehtml?"
\n":"\n").($usehtml?"
\n":"\n"); $allmessage.= "Note: This list contains only invoices for third parties you are linked to as a sale representative.".($usehtml?"
\n":"\n"); } $allmessage.= $message.($usehtml?"
\n":"\n"); From 2f53eacb4cefb673e8f678f404dd5b1279ae0b8c Mon Sep 17 00:00:00 2001 From: Grand Philippe Date: Wed, 15 May 2013 15:40:10 +0200 Subject: [PATCH 07/11] fix personal value error --- scripts/invoices/email_unpaid_invoices_to_representatives.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/invoices/email_unpaid_invoices_to_representatives.php b/scripts/invoices/email_unpaid_invoices_to_representatives.php index 21bcc98e0c9..8a0f7e8dbdf 100755 --- a/scripts/invoices/email_unpaid_invoices_to_representatives.php +++ b/scripts/invoices/email_unpaid_invoices_to_representatives.php @@ -47,7 +47,7 @@ if (! isset($argv[1]) || ! $argv[1] || ! in_array($argv[1],array('test','confirm $mode=$argv[1]; -require($path."../../httpdocs/master.inc.php"); +require($path."../../htdocs/master.inc.php"); require_once (DOL_DOCUMENT_ROOT."/core/class/CMailFile.class.php"); $langs->load('main'); From 626362780aea4f7eb8cb428ab5010a06e3adc69b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 15 May 2013 17:30:18 +0200 Subject: [PATCH 08/11] Fix: Remove not used constant --- htdocs/admin/stock.php | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/htdocs/admin/stock.php b/htdocs/admin/stock.php index 0390efcdda4..3733973bb2a 100644 --- a/htdocs/admin/stock.php +++ b/htdocs/admin/stock.php @@ -68,7 +68,6 @@ if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_BILL' $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_BILL", '','chaine',0,'',$conf->entity); $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", '','chaine',0,'',$conf->entity); $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", '','chaine',0,'',$conf->entity); - $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_DELETE_INVOICE", '','chaine',0,'',$conf->entity); if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_BILL') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_BILL", GETPOST('STOCK_CALCULATE_ON_SUPPLIER_BILL','alpha'),'chaine',0,'',$conf->entity); if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", GETPOST('STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER','alpha'),'chaine',0,'',$conf->entity); if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", GETPOST('STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER','alpha'),'chaine',0,'',$conf->entity); @@ -241,19 +240,6 @@ if (! empty($conf->fournisseur->enabled)) print ''; print "\n\n\n"; } -if (! empty($conf->facture->enabled)) -{ - $var=!$var; - print ""; - print ''.$langs->trans("ReStockOnDeleteInvoice").''; - print ''; - print "
"; - print ''; - print ""; - print $form->selectyesno("STOCK_CALCULATE_ON_DELETE_INVOICE",$conf->global->STOCK_CALCULATE_ON_DELETE_INVOICE,1); - print ''; - print "
\n\n\n"; -} print ''; From ff94849b0cf98e2dfba9df9a3dce28fc2cf766d9 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 15 May 2013 19:57:51 +0200 Subject: [PATCH 09/11] Fix: Security test --- htdocs/core/lib/company.lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/core/lib/company.lib.php b/htdocs/core/lib/company.lib.php index dddc5610609..de42a730b2b 100644 --- a/htdocs/core/lib/company.lib.php +++ b/htdocs/core/lib/company.lib.php @@ -60,7 +60,7 @@ function societe_prepare_head($object) $head[$h][2] = 'supplier'; $h++; } - if (! empty($conf->agenda->enabled)) + if (! empty($conf->agenda->enabled) && !empty($user->right->agenda->lire)) { $head[$h][0] = DOL_URL_ROOT.'/societe/agenda.php?socid='.$object->id; $head[$h][1] = $langs->trans("Agenda"); @@ -68,7 +68,7 @@ function societe_prepare_head($object) $h++; } //show categorie tab - if (! empty($conf->categorie->enabled)) + if (! empty($conf->categorie->enabled) && !empty($user->right->categorie->lire)) { $type = 2; if ($object->fournisseur) $type = 1; From 4fede61c16f6e97000511f9dda2aeaec2934ad91 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 15 May 2013 20:37:50 +0200 Subject: [PATCH 10/11] Update doc --- README-FR | 25 ++++++++++++------------- README.md | 30 ++++++++++++++++-------------- 2 files changed, 28 insertions(+), 27 deletions(-) diff --git a/README-FR b/README-FR index ac3a9ae2d8c..cc69cfa6e8a 100644 --- a/README-FR +++ b/README-FR @@ -78,30 +78,29 @@ IV - CE QUE DOLIBARR PEUT FAIRE ------------------------------- Modules principaux: +- Annuaires des prospects et/ou client et/ou fournisseurs - Gestion de catalogue de produits et services - Gestion de stock - Gestion des comptes bancaires -- Annuaires des prospects et/ou client et/ou fournisseurs -- Annuaires des contacts -- Gestion des actions/taches avec un agenda intégré (ou lien avec webcalendar) +- Agenda partagé - Gestion des commandes -- Gestion des propositions commerciales -- Gestion de contrats de services +- Gestion des devis, propositions commerciales - Gestion des factures clients et fournisseurs +- Gestion de contrats de services - Gestion des paiements - Gestion des virements bancaires - Gestion des expéditions +- GED (Gestion Electronique de Documents) +- EMailings de masse +- Réalisation de sondages +- Point de vente/Caisse enregistreuse Autres modules: -- Gestion de la TVA NPR (non perçue récupérable - pour les utilisateurs français des DOM-TOM) -- Gestion des adhérents d'association -- Gestion des dons - Gestion de marque-pages -- Agenda -- Point de vente/Caisse enregistreuse -- Fonctions d'EMailing de masses vers les clients, prospect ou utilisateurs Dolibarr +- Gestion des promesses de dons +- Gestion de la TVA NPR (non perçue récupérable - pour les utilisateurs français des DOM-TOM) - Rapports -- Fonctions d'exports +- Imports/Exports des données - Connectivité LDAP - Export PDF de tous les éléments (factures, propositions commerciales, commandes, bons expéditions, etc...) - De nombreuses autres fonctionnalités issues de modules officiels ou non (AWStats, Bittorrent, Gravatar, Google, Webcalendar...) @@ -122,7 +121,7 @@ V - CE QUE DOLIBARR NE PEUT PAS FAIRE (TACHES A FAIRE) Voici un liste de fonctionnalites pas encore gérées par Dolibarr: - Pas de compta analytique (uniquement gestion de trésorerie). - Dolibarr ne gère qu'une seule monnaie à la fois (mono-devise). -- Dolibarr ne gère en standard qu'une société/institution/association (mono-société). Pour en gérer plusieurs (comme vos filiales), il faut, soit faire plusieurs installations de Dolibarr, soit installer le module MultiCompany qui permet de gérer n société/institutions/associations dans une seule instance par une isolation logique des données. +- Dolibarr ne gère en standard qu'une société/institution/association mère (mono-société). Pour en gérer plusieurs (comme vos filiales), il faut, soit faire plusieurs installations de Dolibarr, soit installer le module MultiCompany qui permet de gérer n société/institutions/associations dans une seule instance par une isolation logique des données. - Ne gère pas la double tva (Fédérale / provinciale) du canada. - Dolibarr ne contient pas de module de Gestion de la paie. - Les taches du module de gestion de projets n'ont pas de dépendance entre elle. diff --git a/README.md b/README.md index e3d86854a70..257d19e60fb 100644 --- a/README.md +++ b/README.md @@ -75,33 +75,35 @@ See ChangeLog file found into package. ### Main modules/features: -- Products and services catalog - Customers, Prospects or Suppliers directory -- Address book +- Products and services catalog - Stock management - Bank accounts management - Orders management with PDF export -- Commercial proposals management with PDF export +- Commercial proposals management - Contracts management -- Invoices management with PDF export +- Invoices management - Payments management - Standing orders management - Shipping management -- ECM (Electronic Content Management) -- EMailings - Agenda with ical,vcal export for third tools integration -- Management of foundation members -- Donation management +- ECM (Electronic Content Management) +- Foundations members management +- Employee's holidays management +- Mass emailing +- Realize surveys +- Point of Sale ### Other modules: - Bookmarks management -- Can reports Dolibarr events inside Webcalendar or Phenix -- Data export tools +- Donations management +- Reporting +- Data export/import tools - LDAP connectivity - Third parties or products categories - ClickToDial phone numbers -- RSS +- RSS integration ### Miscellaneous: @@ -123,11 +125,11 @@ See ChangeLog file found into package. This is features that Dolibarr does not support completely yet: -- No accountancy (only bank management). +- No double party accountancy (only bank management). - Dolibarr manage one currency at once (mono-currency). -- Dolibarr manage one company/foundation (mono-company). If you want to manage several companies or foundations, you must install several time the software (on same server or not). Another solution is to extend Dolibarr with the addon Module MultiCompany that allows to manage several companies in one Dolibarr instance (one database but with a logical isolation of datas). +- Dolibarr manage one master company/foundation (mono-company). If you want to manage several companies or foundations, you must install several time the software (on same server or not). Another solution is to extend Dolibarr with the addon Module MultiCompany that allows to manage several companies in one Dolibarr instance (one database but with a logical isolation of datas). - Does not support double VAT (Federal / provincial) for Canada. - Dolibarr does not contains Payroll module. - Tasks on module project can't have dependencies between each other. - Dolibarr does not include any Webmail. -- Dolibarr can't do coffee (not yet). \ No newline at end of file +- Dolibarr can't do coffee (not yet). From b05548a633c515aa824cb8d3b33d08e48312bb4a Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 15 May 2013 22:32:28 +0200 Subject: [PATCH 11/11] Fix: Parameter delay not used when set to 0 --- scripts/invoices/email_unpaid_invoices_to_customers.php | 6 +++--- .../invoices/email_unpaid_invoices_to_representatives.php | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/invoices/email_unpaid_invoices_to_customers.php b/scripts/invoices/email_unpaid_invoices_to_customers.php index 972cbb7d429..f616ac837ef 100755 --- a/scripts/invoices/email_unpaid_invoices_to_customers.php +++ b/scripts/invoices/email_unpaid_invoices_to_customers.php @@ -58,17 +58,17 @@ $langs->load('main'); */ $now=dol_now('tzserver'); -$duration_value=$argv[2]; +$duration_value=isset($argv[2])?$argv[2]:-1; $error = 0; -print $script_file." launched with mode ".$mode.($duration_value?" delay=".$duration_value:"")."\n"; +print $script_file." launched with mode ".$mode.($duration_value>=0?" delay=".$duration_value:"")."\n"; $sql = "SELECT f.facnumber, f.total_ttc, f.date_lim_reglement as due_date, s.nom as name, s.email, s.default_lang"; $sql .= " FROM ".MAIN_DB_PREFIX."facture as f"; $sql .= " , ".MAIN_DB_PREFIX."societe as s"; $sql .= " WHERE f.fk_statut != 0 AND f.paye = 0"; $sql .= " AND f.fk_soc = s.rowid"; -if ($duration_value) $sql .= " AND f.date_lim_reglement < '".$db->idate(dol_time_plus_duree($now, $duration_value, "d"))."'"; +if ($duration_value>=0) $sql .= " AND f.date_lim_reglement < '".$db->idate(dol_time_plus_duree($now, $duration_value, "d"))."'"; $sql .= " ORDER BY s.email ASC, s.rowid ASC"; // Order by email to allow one message per email //print $sql; diff --git a/scripts/invoices/email_unpaid_invoices_to_representatives.php b/scripts/invoices/email_unpaid_invoices_to_representatives.php index 8a0f7e8dbdf..74ceed75729 100755 --- a/scripts/invoices/email_unpaid_invoices_to_representatives.php +++ b/scripts/invoices/email_unpaid_invoices_to_representatives.php @@ -58,10 +58,10 @@ $langs->load('main'); */ $now=dol_now('tzserver'); -$duration_value=$argv[2]; +$duration_value=isset($argv[2])?$argv[2]:-1; $error = 0; -print $script_file." launched with mode ".$mode.($duration_value?" delay=".$duration_value:"")."\n"; +print $script_file." launched with mode ".$mode.($duration_value>=0?" delay=".$duration_value:"")."\n"; $sql = "SELECT f.facnumber, f.total_ttc, f.date_lim_reglement as due_date, s.nom as name, u.rowid as uid, u.lastname, u.firstname, u.email, u.lang"; $sql .= " FROM ".MAIN_DB_PREFIX."facture as f"; @@ -70,7 +70,7 @@ $sql .= " , ".MAIN_DB_PREFIX."societe_commerciaux as sc"; $sql .= " , ".MAIN_DB_PREFIX."user as u"; $sql .= " WHERE f.fk_statut != 0 AND f.paye = 0"; $sql .= " AND f.fk_soc = s.rowid"; -if ($duration_value) $sql .= " AND f.date_lim_reglement < '".$db->idate(dol_time_plus_duree($now, $duration_value, "d"))."'"; +if ($duration_value>=0) $sql .= " AND f.date_lim_reglement < '".$db->idate(dol_time_plus_duree($now, $duration_value, "d"))."'"; $sql .= " AND sc.fk_soc = s.rowid"; $sql .= " AND sc.fk_user = u.rowid"; $sql .= " ORDER BY u.email ASC, s.rowid ASC"; // Order by email to allow one message per email