diff --git a/htdocs/compta/facture/list.php b/htdocs/compta/facture/list.php
index 3d983e3216a..d5d320e6d32 100644
--- a/htdocs/compta/facture/list.php
+++ b/htdocs/compta/facture/list.php
@@ -79,7 +79,7 @@ $search_montant_vat=GETPOST('search_montant_vat','alpha');
$search_montant_localtax1=GETPOST('search_montant_localtax1','alpha');
$search_montant_localtax2=GETPOST('search_montant_localtax2','alpha');
$search_montant_ttc=GETPOST('search_montant_ttc','alpha');
-$search_status=GETPOST('search_status','int');
+$search_status=GETPOST('search_status','intcomma');
$search_paymentmode=GETPOST('search_paymentmode','int');
$search_town=GETPOST('search_town','alpha');
$search_zip=GETPOST('search_zip','alpha');
@@ -108,7 +108,7 @@ $sortorder = GETPOST("sortorder",'alpha');
$page = GETPOST("page",'int');
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
$offset = $limit * $page;
-if (! $sortorder && ! empty($conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER) && $search_status == 1) $sortorder=$conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER;
+if (! $sortorder && ! empty($conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER) && $search_status == '1') $sortorder=$conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER;
if (! $sortorder) $sortorder='DESC';
if (! $sortfield) $sortfield='f.datef';
$pageprev = $page - 1;
@@ -442,12 +442,19 @@ if ($search_montant_localtax2 != '') $sql.= natural_search('f.localtax2', $searc
if ($search_montant_ttc != '') $sql.= natural_search('f.total_ttc', $search_montant_ttc, 1);
if ($search_categ_cus > 0) $sql.= " AND cc.fk_categorie = ".$db->escape($search_categ_cus);
if ($search_categ_cus == -2) $sql.= " AND cc.fk_categorie IS NULL";
-if ($search_status != '' && $search_status >= 0)
+if ($search_status != '')
{
- if ($search_status == '0') $sql.=" AND f.fk_statut = 0"; // draft
- if ($search_status == '1') $sql.=" AND f.fk_statut = 1"; // unpayed
- if ($search_status == '2') $sql.=" AND f.fk_statut = 2"; // payed Not that some corrupted data may contains f.fk_statut = 1 AND f.paye = 1 (it means payed too but should not happend. If yes, reopen and reclassify billed)
- if ($search_status == '3') $sql.=" AND f.fk_statut = 3"; // abandonned
+ if (is_numeric($search_status) && $search_status >= 0)
+ {
+ if ($search_status == '0') $sql.=" AND f.fk_statut = 0"; // draft
+ if ($search_status == '1') $sql.=" AND f.fk_statut = 1"; // unpayed
+ if ($search_status == '2') $sql.=" AND f.fk_statut = 2"; // payed Not that some corrupted data may contains f.fk_statut = 1 AND f.paye = 1 (it means payed too but should not happend. If yes, reopen and reclassify billed)
+ if ($search_status == '3') $sql.=" AND f.fk_statut = 3"; // abandonned
+ }
+ else
+ {
+ $sql.= " AND f.fk_statut IN (".$search_status.")"; // When search_status is '1,2' for example
+ }
}
if ($search_paymentmode > 0) $sql .= " AND f.fk_mode_reglement = ".$db->escape($search_paymentmode);
if ($search_month > 0)
@@ -854,7 +861,7 @@ if ($resql)
if (! empty($arrayfields['f.fk_statut']['checked']))
{
print '
';
- $liststatus=array('0'=>$langs->trans("BillShortStatusDraft"), '1'=>$langs->trans("BillShortStatusNotPaid"), '2'=>$langs->trans("BillShortStatusPaid"), '3'=>$langs->trans("BillShortStatusCanceled"));
+ $liststatus=array('0'=>$langs->trans("BillShortStatusDraft"), '1'=>$langs->trans("BillShortStatusNotPaid"), '2'=>$langs->trans("BillShortStatusPaid"), '1,2'=>$langs->trans("BillShortStatusNotPaid").'+'.$langs->trans("BillShortStatusPaid"), '3'=>$langs->trans("BillShortStatusCanceled"));
print $form->selectarray('search_status', $liststatus, $search_status, 1);
print ' | ';
}
diff --git a/htdocs/compta/stats/byratecountry.php b/htdocs/compta/stats/byratecountry.php
index 78a9187be57..2c43db42d13 100644
--- a/htdocs/compta/stats/byratecountry.php
+++ b/htdocs/compta/stats/byratecountry.php
@@ -190,13 +190,15 @@ $namesup=$namecust;
+// TODO Report from bookkeeping not yet available, so we switch on report on business events
+if ($modecompta=="BOOKKEEPING") $modecompta="CREANCES-DETTES";
+if ($modecompta=="BOOKKEEPINGCOLLECTED") $modecompta="RECETTES-DEPENSES";
// Show report header
-$name=$langs->trans("SalesTurnover").', '.$langs->trans("ByVatRate");
-
if ($modecompta=="CREANCES-DETTES") {
+ $name=$langs->trans("Turnover").', '.$langs->trans("ByVatRate");
$calcmode=$langs->trans("CalcModeDebt");
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
@@ -206,14 +208,27 @@ if ($modecompta=="CREANCES-DETTES") {
}
$builddate=dol_now();
-} else {
+}
+else if ($modecompta=="RECETTES-DEPENSES")
+{
+ $name=$langs->trans("TurnoverCollected").', '.$langs->trans("ByVatRate");
$calcmode=$langs->trans("CalcModeEngagement");
- $calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
$description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
+}
+else if ($modecompta=="BOOKKEEPING")
+{
+
+
+}
+else if ($modecompta=="BOOKKEEPINGCOLLECTED")
+{
+
+
}
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
if ($date_end == dol_time_plus_duree($date_start, 1, 'y') - 1) $periodlink=''.img_previous().' '.img_next().'';
diff --git a/htdocs/compta/stats/cabyprodserv.php b/htdocs/compta/stats/cabyprodserv.php
index 5c2a50325a7..5d28ab3e077 100644
--- a/htdocs/compta/stats/cabyprodserv.php
+++ b/htdocs/compta/stats/cabyprodserv.php
@@ -158,12 +158,15 @@ llxHeader();
$form=new Form($db);
$formother = new FormOther($db);
-// Show report header
-$name=$langs->trans("SalesTurnover").', '.$langs->trans("ByProductsAndServices");
+// TODO Report from bookkeeping not yet available, so we switch on report on business events
+if ($modecompta=="BOOKKEEPING") $modecompta="CREANCES-DETTES";
+if ($modecompta=="BOOKKEEPINGCOLLECTED") $modecompta="RECETTES-DEPENSES";
+// Show report header
if ($modecompta=="CREANCES-DETTES") {
+ $name=$langs->trans("Turnover").', '.$langs->trans("ByProductsAndServices");
$calcmode=$langs->trans("CalcModeDebt");
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
@@ -173,15 +176,29 @@ if ($modecompta=="CREANCES-DETTES") {
}
$builddate=dol_now();
-} else {
+}
+else if ($modecompta=="RECETTES-DEPENSES")
+{
+ $name=$langs->trans("TurnoverCollected").', '.$langs->trans("ByProductsAndServices");
$calcmode=$langs->trans("CalcModeEngagement");
- $calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
$description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
}
+else if ($modecompta=="BOOKKEEPING")
+{
+
+
+}
+else if ($modecompta=="BOOKKEEPINGCOLLECTED")
+{
+
+
+}
+
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
if ($date_end == dol_time_plus_duree($date_start, 1, 'y') - 1) $periodlink=''.img_previous().' '.img_next().'';
else $periodlink = '';
diff --git a/htdocs/compta/stats/cabyuser.php b/htdocs/compta/stats/cabyuser.php
index dbd5d46e61a..ccb286c1420 100644
--- a/htdocs/compta/stats/cabyuser.php
+++ b/htdocs/compta/stats/cabyuser.php
@@ -142,24 +142,40 @@ llxHeader();
$form=new Form($db);
+// TODO Report from bookkeeping not yet available, so we switch on report on business events
+if ($modecompta=="BOOKKEEPING") $modecompta="CREANCES-DETTES";
+if ($modecompta=="BOOKKEEPINGCOLLECTED") $modecompta="RECETTES-DEPENSES";
+
// Show report header
if ($modecompta=="CREANCES-DETTES") {
- $name=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
+ $name=$langs->trans("Turnover").', '.$langs->trans("ByUserAuthorOfInvoice");
$calcmode=$langs->trans("CalcModeDebt");
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
else $description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
//$exportlink=$langs->trans("NotYetAvailable");
-} else {
- $name=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
+}
+else if ($modecompta=="RECETTES-DEPENSES")
+{
+ $name=$langs->trans("TurnoverCollected").', '.$langs->trans("ByUserAuthorOfInvoice");
$calcmode=$langs->trans("CalcModeEngagement");
- $calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
$description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
//$exportlink=$langs->trans("NotYetAvailable");
+}
+else if ($modecompta=="BOOKKEEPING")
+{
+
+
+}
+else if ($modecompta=="BOOKKEEPINGCOLLECTED")
+{
+
+
}
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
if ($date_end == dol_time_plus_duree($date_start, 1, 'y') - 1) $periodlink=''.img_previous().' '.img_next().'';
@@ -327,7 +343,7 @@ print_liste_field_titre(
"",
'align="center" width="20%"'
);
-print "\n";
+print "\n";
if (count($amount)) {
$arrayforsort=$name;
diff --git a/htdocs/compta/stats/casoc.php b/htdocs/compta/stats/casoc.php
index 1555b3c79ac..8e00dfe5fbe 100644
--- a/htdocs/compta/stats/casoc.php
+++ b/htdocs/compta/stats/casoc.php
@@ -167,25 +167,41 @@ $form=new Form($db);
$thirdparty_static=new Societe($db);
$formother = new FormOther($db);
+// TODO Report from bookkeeping not yet available, so we switch on report on business events
+if ($modecompta=="BOOKKEEPING") $modecompta="CREANCES-DETTES";
+if ($modecompta=="BOOKKEEPINGCOLLECTED") $modecompta="RECETTES-DEPENSES";
+
// Show report header
if ($modecompta=="CREANCES-DETTES")
{
- $name=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
+ $name=$langs->trans("Turnover").', '.$langs->trans("ByThirdParties");
$calcmode=$langs->trans("CalcModeDebt");
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$description=$langs->trans("RulesCADue");
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $description.= $langs->trans("DepositsAreNotIncluded");
else $description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
//$exportlink=$langs->trans("NotYetAvailable");
-} else {
- $name=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
+}
+else if ($modecompta=="RECETTES-DEPENSES")
+{
+ $name=$langs->trans("TurnoverCollected").', '.$langs->trans("ByThirdParties");
$calcmode=$langs->trans("CalcModeEngagement");
- $calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
$description=$langs->trans("RulesCAIn");
$description.= $langs->trans("DepositsAreIncluded");
$builddate=dol_now();
//$exportlink=$langs->trans("NotYetAvailable");
+}
+else if ($modecompta=="BOOKKEEPING")
+{
+
+
+}
+else if ($modecompta=="BOOKKEEPINGCOLLECTED")
+{
+
+
}
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
if ($date_end == dol_time_plus_duree($date_start, 1, 'y') - 1) $periodlink=''.img_previous().' '.img_next().'';
@@ -230,8 +246,8 @@ if ($modecompta == 'CREANCES-DETTES') {
$sql.=" AND cs.fk_soc is null";
}
else if ($selected_cat) { // Into a specific category
- $sql.= " AND (c.rowid = ".$selected_cat;
- if ($subcat) $sql.=" OR c.fk_parent = " . $selected_cat;
+ $sql.= " AND (c.rowid = ".$db->escape($selected_cat);
+ if ($subcat) $sql.=" OR c.fk_parent = " . $db->escape($selected_cat);
$sql.= ")";
$sql.= " AND cs.fk_categorie = c.rowid AND cs.fk_soc = s.rowid";
}
@@ -270,10 +286,10 @@ if ($modecompta == 'CREANCES-DETTES') {
$sql.= " AND cs.fk_categorie = c.rowid AND cs.fk_soc = s.rowid";
}
}
-if(!empty($search_societe)) $sql.= ' AND s.nom LIKE "%'.$search_societe.'%"';
-if(!empty($search_zip)) $sql.= ' AND s.zip LIKE "%'.$search_zip.'%"';
-if(!empty($search_town)) $sql.= ' AND s.town LIKE "%'.$search_town.'%"';
-if($search_country > 0) $sql.= ' AND s.fk_pays = '.$search_country.'';
+if (!empty($search_societe)) $sql.= natural_search('s.nom', $search_societe);
+if (!empty($search_zip)) $sql.= natural_search('s.zip', $search_zip);
+if (!empty($search_town)) $sql.= natural_search('s.town', $search_town);
+if ($search_country > 0) $sql.= ' AND s.fk_pays = '.$search_country.'';
$sql.= " AND f.entity = ".$conf->entity;
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
$sql.= " GROUP BY s.rowid, s.nom, s.zip, s.town, s.fk_pays";
diff --git a/htdocs/compta/stats/index.php b/htdocs/compta/stats/index.php
index dd24a6cd507..c255d236664 100644
--- a/htdocs/compta/stats/index.php
+++ b/htdocs/compta/stats/index.php
@@ -115,9 +115,9 @@ $form=new Form($db);
// Affiche en-tete du rapport
if ($modecompta=="CREANCES-DETTES")
{
- $name=$langs->trans("SalesTurnover");
+ $name=$langs->trans("Turnover");
$calcmode=$langs->trans("CalcModeDebt");
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$calcmode.='
('.$langs->trans("SeeReportInBookkeepingMode",'','').')';
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
$periodlink=($year_start?"".img_previous()." ".img_next()."":"");
@@ -129,10 +129,10 @@ if ($modecompta=="CREANCES-DETTES")
}
else if ($modecompta=="RECETTES-DEPENSES")
{
- $name=$langs->trans("SalesTurnover");
+ $name=$langs->trans("TurnoverCollected");
$calcmode=$langs->trans("CalcModeEngagement");
- $calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
- $calcmode.='
('.$langs->trans("SeeReportInBookkeepingMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInBookkeepingMode",'','').')';
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
$periodlink=($year_start?"".img_previous()." ".img_next()."":"");
$description=$langs->trans("RulesCAIn");
@@ -142,10 +142,10 @@ else if ($modecompta=="RECETTES-DEPENSES")
}
else if ($modecompta=="BOOKKEEPING")
{
- $name=$langs->trans("SalesTurnover");
+ $name=$langs->trans("Turnover");
$calcmode=$langs->trans("CalcModeBookkeeping");
$calcmode.='
('.$langs->trans("SeeReportInDueDebtMode",'','').')';
- $calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
+ //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')';
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
$periodlink=($year_start?"".img_previous()." ".img_next()."":"");
$description=$langs->trans("RulesCATotalSaleJournal");
diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php
index 5cb7547d0f4..a6f19a68086 100644
--- a/htdocs/core/menus/standard/eldy.lib.php
+++ b/htdocs/core/menus/standard/eldy.lib.php
@@ -1099,11 +1099,28 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu
if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/resultat/index.php?leftmenu=accountancy_report",$langs->trans("MenuReportInOut"),2,$user->rights->accounting->comptarapport->lire);
if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/resultat/clientfourn.php?leftmenu=accountancy_report",$langs->trans("ByPredefinedAccountGroups"),3,$user->rights->accounting->comptarapport->lire);
if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/resultat/result.php?leftmenu=accountancy_report",$langs->trans("ByPersonalizedAccountGroups"),3,$user->rights->accounting->comptarapport->lire);
- if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/index.php?leftmenu=accountancy_report",$langs->trans("ReportTurnover"),2,$user->rights->accounting->comptarapport->lire);
- if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/casoc.php?leftmenu=accountancy_report",$langs->trans("ByCompanies"),3,$user->rights->accounting->comptarapport->lire);
- if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyuser.php?leftmenu=accountancy_report",$langs->trans("ByUsers"),3,$user->rights->accounting->comptarapport->lire);
- if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyprodserv.php?leftmenu=accountancy_report", $langs->trans("ByProductsAndServices"),3,$user->rights->accounting->comptarapport->lire);
- if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/byratecountry.php?leftmenu=accountancy_report", $langs->trans("ByVatRate"),3,$user->rights->accounting->comptarapport->lire);
+
+ $modecompta='CREANCES-DETTES';
+ if(! empty($conf->accounting->enabled) && ! empty($user->rights->accounting->comptarapport->lire) && $mainmenu == 'accountancy') $modecompta='BOOKKEEPING'; // Not yet implemented. Should be BOOKKEEPINGCOLLECTED
+ if ($modecompta)
+ {
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/index.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ReportTurnover"),2,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/casoc.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ByCompanies"),3,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyuser.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ByUsers"),3,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyprodserv.php?leftmenu=accountancy_report&modecompta=".$modecompta, $langs->trans("ByProductsAndServices"),3,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/byratecountry.php?leftmenu=accountancy_report&modecompta=".$modecompta, $langs->trans("ByVatRate"),3,$user->rights->accounting->comptarapport->lire);
+ }
+
+ $modecompta='RECETTES-DEPENSES';
+ //if (! empty($conf->accounting->enabled) && ! empty($user->rights->accounting->comptarapport->lire) && $mainmenu == 'accountancy') $modecompta=''; // Not yet implemented. Should be BOOKKEEPINGCOLLECTED
+ if ($modecompta)
+ {
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/index.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ReportTurnoverCollected"),2,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/casoc.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ByCompanies"),3,$user->rights->accounting->comptarapport->lire);
+ if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyuser.php?leftmenu=accountancy_report&modecompta=".$modecompta,$langs->trans("ByUsers"),3,$user->rights->accounting->comptarapport->lire);
+ //if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/cabyprodserv.php?leftmenu=accountancy_report&modecompta=".$modecompta, $langs->trans("ByProductsAndServices"),3,$user->rights->accounting->comptarapport->lire);
+ //if ($usemenuhider || empty($leftmenu) || preg_match('/accountancy_report/',$leftmenu)) $newmenu->add("/compta/stats/byratecountry.php?leftmenu=accountancy_report&modecompta=".$modecompta, $langs->trans("ByVatRate"),3,$user->rights->accounting->comptarapport->lire);
+ }
}
// Accountancy (simple)
diff --git a/htdocs/langs/en_US/compta.lang b/htdocs/langs/en_US/compta.lang
index ce70a9748a0..196ab114d6f 100644
--- a/htdocs/langs/en_US/compta.lang
+++ b/htdocs/langs/en_US/compta.lang
@@ -19,7 +19,8 @@ Income=Income
Outcome=Expense
MenuReportInOut=Income / Expense
ReportInOut=Balance of income and expenses
-ReportTurnover=Turnover
+ReportTurnover=Turnover invoiced
+ReportTurnoverCollected=Turnover collected
PaymentsNotLinkedToInvoice=Payments not linked to any invoice, so not linked to any third party
PaymentsNotLinkedToUser=Payments not linked to any user
Profit=Profit
@@ -117,8 +118,9 @@ CustomerAccountancyCodeShort=Cust. account. code
SupplierAccountancyCodeShort=Sup. account. code
AccountNumber=Account number
NewAccountingAccount=New account
-SalesTurnover=Sales turnover
-SalesTurnoverMinimum=Minimum sales turnover
+Turnover=Turnover invoiced
+TurnoverCollected=Turnover collected
+SalesTurnoverMinimum=Minimum turnover
ByExpenseIncome=By expenses & incomes
ByThirdParties=By third parties
ByUserAuthorOfInvoice=By invoice author
@@ -138,8 +140,8 @@ ConfirmDeleteSocialContribution=Are you sure you want to delete this social/fisc
ExportDataset_tax_1=Social and fiscal taxes and payments
CalcModeVATDebt=Mode %sVAT on commitment accounting%s.
CalcModeVATEngagement=Mode %sVAT on incomes-expenses%s.
-CalcModeDebt=Mode %sClaims-Debts%s said Commitment accounting.
-CalcModeEngagement=Mode %sIncomes-Expenses%s said cash accounting
+CalcModeDebt=Analysis of known recorded invoices even if they are not yet accounted in ledger.
+CalcModeEngagement=Analysis of known recorded payments, even if they are not yet accounted in Ledger.
CalcModeBookkeeping=Analysis of data journalized in Bookkeeping Ledger table
CalcModeLT1= Mode %sRE on customer invoices - suppliers invoices%s
CalcModeLT1Debt=Mode %sRE on customer invoices%s
@@ -152,9 +154,9 @@ AnnualSummaryInputOutputMode=Balance of income and expenses, annual summary
AnnualByCompanies=Balance of income and expenses, by predefined groups of account
AnnualByCompaniesDueDebtMode=Balance of income and expenses, detail by predefined groups, mode %sClaims-Debts%s said Commitment accounting.
AnnualByCompaniesInputOutputMode=Balance of income and expenses, detail by predefined groups, mode %sIncomes-Expenses%s said cash accounting.
-SeeReportInInputOutputMode=See report %sIncomes-Expenses%s said cash accounting for a calculation on actual payments made
-SeeReportInDueDebtMode=See report %sClaims-Debts%s said commitment accounting for a calculation on issued invoices
-SeeReportInBookkeepingMode=See report %sBookeeping%s for a calculation on bookkeeping table analysis
+SeeReportInInputOutputMode=See %sanalysis of payments%s for a calculation on actual payments made, if they are not yet accounted in Ledger.
+SeeReportInDueDebtMode=See %sanalysis of invoices%s for a calculation based on known recorded invoices even, if they are not yet accounted in Ledger.
+SeeReportInBookkeepingMode=See %sBookeeping report%s for a calculation on Bookkeeping Ledger table
RulesAmountWithTaxIncluded=- Amounts shown are with all taxes included
RulesResultDue=- It includes outstanding invoices, expenses, VAT, donations whether they are paid or not. Is also includes paid salaries.
- It is based on the validation date of invoices and VAT and on the due date for expenses. For salaries defined with Salary module, the value date of payment is used.
RulesResultInOut=- It includes the real payments made on invoices, expenses, VAT and salaries.
- It is based on the payment dates of the invoices, expenses, VAT and salaries. The donation date for donation.
@@ -219,8 +221,8 @@ Mode1=Method 1
Mode2=Method 2
CalculationRuleDesc=To calculate total VAT, there is two methods:
Method 1 is rounding vat on each line, then summing them.
Method 2 is summing all vat on each line, then rounding result.
Final result may differs from few cents. Default mode is mode %s.
CalculationRuleDescSupplier=According to supplier, choose appropriate method to apply same calculation rule and get same result expected by your supplier.
-TurnoverPerProductInCommitmentAccountingNotRelevant=The Turnover report per product, when using a cash accounting mode is not relevant. This report is only available when using commitment accounting mode (see setup of accountancy module).
-TurnoverPerSaleTaxRateInCommitmentAccountingNotRelevant=The Turnover report per sale tax rate, when using a cash accounting mode is not relevant. This report is only available when using commitment accounting mode (see setup of accountancy module).
+TurnoverPerProductInCommitmentAccountingNotRelevant=The report of Turnover collected per product is not available. This report is only available for turnover invoiced.
+TurnoverPerSaleTaxRateInCommitmentAccountingNotRelevant=The report of Turnover collected per sale tax rate is not available. This report is only available for turnover invoiced.
CalculationMode=Calculation mode
AccountancyJournal=Accounting code journal
ACCOUNTING_VAT_SOLD_ACCOUNT=Accounting account by default for VAT on sales (used if not defined on VAT dictionary setup)
@@ -252,5 +254,6 @@ VATDue=Sale tax claimed
ClaimedForThisPeriod=Claimed for the period
PaidDuringThisPeriod=Paid during this period
ByVatRate=By sale tax rate
-TurnoverbyVatrate=Turnover by sale tax rate
+TurnoverbyVatrate=Turnover invoiced by sale tax rate
+TurnoverCollectedbyVatrate=Turnover collected by sale tax rate
PurchasebyVatrate=Purchase by sale tax rate
\ No newline at end of file
diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php
index 49536d340b0..79aed1eaf68 100644
--- a/htdocs/theme/eldy/style.css.php
+++ b/htdocs/theme/eldy/style.css.php
@@ -1445,8 +1445,8 @@ div.statusrefbis {
}
img.photoref, div.photoref {
border: 1px solid #DDD;
- -webkit-box-shadow: 1px 1px 4px #DDD;
- box-shadow: 1px 1px 4px #DDD;
+ -webkit-box-shadow: 0px 0px 6px #DDD;
+ box-shadow: 0px 0px 6px #DDD;
padding: 4px;
height: 80px;
width: 80px;