Fix: Debug in journal features
This commit is contained in:
parent
714ce334b6
commit
9645372f3d
@ -3,6 +3,7 @@ English Dolibarr ChangeLog
|
|||||||
***** ChangeLog for 3.0 compared to 2.9 *****
|
***** ChangeLog for 3.0 compared to 2.9 *****
|
||||||
|
|
||||||
For users:
|
For users:
|
||||||
|
- New: Add Sales journal and Purchase journal report.
|
||||||
- New: Can create supplier invoice from supplier order.
|
- New: Can create supplier invoice from supplier order.
|
||||||
New: Support login by openid
|
New: Support login by openid
|
||||||
- New: Support "full day" event in calendar module.
|
- New: Support "full day" event in calendar module.
|
||||||
|
|||||||
0
htdocs/compta/journaux/index.php → htdocs/compta/journal/index.php
Normal file → Executable file
0
htdocs/compta/journaux/index.php → htdocs/compta/journal/index.php
Normal file → Executable file
53
htdocs/compta/journaux/journalachat.php → htdocs/compta/journal/purchasesjournal.php
Normal file → Executable file
53
htdocs/compta/journaux/journalachat.php → htdocs/compta/journal/purchasesjournal.php
Normal file → Executable file
@ -66,10 +66,10 @@ if (empty($date_start) || empty($date_end)) // We define date_start and date_end
|
|||||||
$date_start=dol_get_first_day($year_current,$pastmonth,false); $date_end=dol_get_last_day($year_current,$pastmonth,false);
|
$date_start=dol_get_first_day($year_current,$pastmonth,false); $date_end=dol_get_last_day($year_current,$pastmonth,false);
|
||||||
}
|
}
|
||||||
|
|
||||||
$nom=$langs->trans("JournalAchat");
|
$nom=$langs->trans("PurchasesJournal");
|
||||||
//$nomlink=;
|
//$nomlink=;
|
||||||
$builddate=time();
|
$builddate=time();
|
||||||
$description=$langs->trans("DescJournalAchat");
|
$description=$langs->trans("DescPurchasesJournal");
|
||||||
$period=$html->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$html->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
$period=$html->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$html->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
|
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
|
||||||
|
|
||||||
@ -92,9 +92,9 @@ if ($date_start && $date_end) $sql .= " AND f.datef >= '".$db->idate($date_start
|
|||||||
{
|
{
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
// les variables
|
// les variables
|
||||||
$cptfour = isset($conf->global->COMPTA_ACCOUNT_SUPPLIER)?$conf->global->COMPTA_ACCOUNT_SUPPLIER:$langs->trans("CodeNotDef");
|
$cptfour = (! empty($conf->global->COMPTA_ACCOUNT_SUPPLIER))?$conf->global->COMPTA_ACCOUNT_SUPPLIER:$langs->trans("CodeNotDef");
|
||||||
$cpttva = isset($conf->global->COMPTA_VAT_ACCOUNT)?$conf->global->COMPTA_VAT_ACCOUNT:$langs->trans("CodeNotDef");
|
$cpttva = (! empty($conf->global->COMPTA_VAT_ACCOUNT))?$conf->global->COMPTA_VAT_ACCOUNT:$langs->trans("CodeNotDef");
|
||||||
|
|
||||||
$tabfac = array();
|
$tabfac = array();
|
||||||
$tabht = array();
|
$tabht = array();
|
||||||
$tabtva = array();
|
$tabtva = array();
|
||||||
@ -105,14 +105,14 @@ if ($date_start && $date_end) $sql .= " AND f.datef >= '".$db->idate($date_start
|
|||||||
{
|
{
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
// contrôles
|
// contrôles
|
||||||
$compta_soc = isset($obj->code_compta_fournisseur)?$obj->code_compta_fournisseur:$cptfour;
|
$compta_soc = (! empty($obj->code_compta_fournisseur))?$obj->code_compta_fournisseur:$cptfour;
|
||||||
$compta_prod = $obj->accountancy_code_buy;
|
$compta_prod = $obj->accountancy_code_buy;
|
||||||
if (!isset($compta_prod) || empty($compta_prod))
|
if (empty($compta_prod))
|
||||||
{
|
{
|
||||||
if($obj->product_type == 0) $compta_prod = isset($conf->global->COMPTA_PRODUCT_BUY_ACCOUNT)?$conf->global->COMPTA_PRODUCT_BUY_ACCOUNT:$langs->trans("CodeNotDef") ;
|
if($obj->product_type == 0) $compta_prod = (! empty($conf->global->COMPTA_PRODUCT_BUY_ACCOUNT))?$conf->global->COMPTA_PRODUCT_BUY_ACCOUNT:$langs->trans("CodeNotDef") ;
|
||||||
else $compta_prod = isset($conf->global->COMPTA_SERVICE_BUY_ACCOUNT)?$conf->global->COMPTA_SERVICE_BUY_ACCOUNT:$langs->trans("CodeNotDef") ;
|
else $compta_prod = (! empty($conf->global->COMPTA_SERVICE_BUY_ACCOUNT))?$conf->global->COMPTA_SERVICE_BUY_ACCOUNT:$langs->trans("CodeNotDef") ;
|
||||||
}
|
}
|
||||||
$compta_tva = isset($obj->accountancy_code)?$obj->accountancy_code:$cpttva;
|
$compta_tva = (! empty($obj->accountancy_code))?$obj->accountancy_code:$cpttva;
|
||||||
|
|
||||||
$tabfac[$obj->rowid]["date"] = $obj->datef;
|
$tabfac[$obj->rowid]["date"] = $obj->datef;
|
||||||
$tabfac[$obj->rowid]["ref"] = $obj->facnumber;
|
$tabfac[$obj->rowid]["ref"] = $obj->facnumber;
|
||||||
@ -121,8 +121,8 @@ if ($date_start && $date_end) $sql .= " AND f.datef >= '".$db->idate($date_start
|
|||||||
$tabttc[$obj->rowid][$compta_soc] += $obj->total_ttc;
|
$tabttc[$obj->rowid][$compta_soc] += $obj->total_ttc;
|
||||||
$tabht[$obj->rowid][$compta_prod] += $obj->total_ht;
|
$tabht[$obj->rowid][$compta_prod] += $obj->total_ht;
|
||||||
$tabtva[$obj->rowid][$compta_tva] += $obj->total_tva;
|
$tabtva[$obj->rowid][$compta_tva] += $obj->total_tva;
|
||||||
|
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -135,9 +135,12 @@ if ($date_start && $date_end) $sql .= " AND f.datef >= '".$db->idate($date_start
|
|||||||
$i = 0;
|
$i = 0;
|
||||||
print "<table class=\"noborder\" width=\"100%\">";
|
print "<table class=\"noborder\" width=\"100%\">";
|
||||||
print "<tr class=\"liste_titre\">";
|
print "<tr class=\"liste_titre\">";
|
||||||
print "<td>".$langs->trans("JournalNum")."</td><td>".$langs->trans("Invoicedate")."</td><td>".$langs->trans("InvoiceRef")."</td>";
|
///print "<td>".$langs->trans("JournalNum")."</td>";
|
||||||
print "<td>".$langs->trans("Piece")."</td><td>".$langs->trans("Account")."</td>";
|
print "<td>".$langs->trans("Date")."</td>";
|
||||||
print "<t><td>".$langs->trans("InvoiceLib")."</td><td>".$langs->trans("AmountDbt")."</td><td>".$langs->trans("AmountCdt")."</td>";
|
print "<td>".$langs->trans("InvoiceRef")."</td>";
|
||||||
|
print "<td>".$langs->trans("Piece")."</td>";
|
||||||
|
print "<td>".$langs->trans("Account")."</td>";
|
||||||
|
print "<t><td>".$langs->trans("Label")."</td><td>".$langs->trans("Debit")."</td><td>".$langs->trans("Credit")."</td>";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
$var=true;
|
$var=true;
|
||||||
@ -147,7 +150,9 @@ foreach ($tabfac as $key => $val)
|
|||||||
{
|
{
|
||||||
print "<tr $bc[$var] >";
|
print "<tr $bc[$var] >";
|
||||||
//facture
|
//facture
|
||||||
print "<td>".$conf->global->COMPTA_JOURNAL_BUY."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
//print "<td>".$conf->global->COMPTA_JOURNAL_BUY."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
foreach ($tabttc[$key] as $k => $mt)
|
foreach ($tabttc[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td>".$mt."</td><td></td>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td>".$mt."</td><td></td>";
|
||||||
@ -156,28 +161,34 @@ foreach ($tabfac as $key => $val)
|
|||||||
// produit
|
// produit
|
||||||
foreach ($tabht[$key] as $k => $mt)
|
foreach ($tabht[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<tr><td>".$conf->global->COMPTA_JOURNAL_BUY."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
print "<tr>";
|
||||||
|
//print "<td>".$conf->global->COMPTA_JOURNAL_BUY."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
||||||
}
|
}
|
||||||
// tva
|
// tva
|
||||||
foreach ($tabtva[$key] as $k => $mt)
|
foreach ($tabtva[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<tr><td>".$conf->global->COMPTA_JOURNAL_BUY."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
print "<tr>";
|
||||||
|
//print "<td>".$conf->global->COMPTA_JOURNAL_BUY."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
||||||
}
|
}
|
||||||
|
|
||||||
$val = !$val;
|
$val = !$val;
|
||||||
}
|
}
|
||||||
|
|
||||||
print "</table>";
|
print "</table>";
|
||||||
|
|
||||||
/***************************************************
|
/***************************************************
|
||||||
* LINKED OBJECT BLOCK
|
* LINKED OBJECT BLOCK
|
||||||
*
|
*
|
||||||
* Put here code to view linked object
|
* Put here code to view linked object
|
||||||
****************************************************/
|
****************************************************/
|
||||||
/*
|
/*
|
||||||
|
|
||||||
$myobject->load_object_linked($myobject->id,$myobject->element);
|
$myobject->load_object_linked($myobject->id,$myobject->element);
|
||||||
|
|
||||||
foreach($myobject->linked_object as $linked_object => $linked_objectid)
|
foreach($myobject->linked_object as $linked_object => $linked_objectid)
|
||||||
61
htdocs/compta/journaux/journalvente.php → htdocs/compta/journal/sellsjournal.php
Normal file → Executable file
61
htdocs/compta/journaux/journalvente.php → htdocs/compta/journal/sellsjournal.php
Normal file → Executable file
@ -65,20 +65,20 @@ if (empty($date_start) || empty($date_end)) // We define date_start and date_end
|
|||||||
$date_start=dol_get_first_day($year_current,$pastmonth,false); $date_end=dol_get_last_day($year_current,$pastmonth,false);
|
$date_start=dol_get_first_day($year_current,$pastmonth,false); $date_end=dol_get_last_day($year_current,$pastmonth,false);
|
||||||
}
|
}
|
||||||
|
|
||||||
$nom=$langs->trans("JournalVente");
|
$nom=$langs->trans("SellsJournal");
|
||||||
//$nomlink=;
|
//$nomlink=;
|
||||||
$builddate=time();
|
$builddate=time();
|
||||||
$description=$langs->trans("DescJournalvente");
|
$description=$langs->trans("DescSellsJournal");
|
||||||
$period=$html->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$html->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
$period=$html->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$html->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
|
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink);
|
||||||
|
|
||||||
$p = explode(":", $conf->global->MAIN_INFO_SOCIETE_PAYS);
|
$p = explode(":", $conf->global->MAIN_INFO_SOCIETE_PAYS);
|
||||||
$idpays = $p[0];
|
$idpays = $p[0];
|
||||||
|
|
||||||
$sql = "SELECT f.rowid, f.facnumber, f.datef, f.ref_client , fd.product_type, fd.total_ht, fd.total_tva, fd.tva_tx ";
|
$sql = "SELECT f.rowid, f.facnumber, f.datef, f.ref_client , fd.product_type, fd.total_ht, fd.total_tva, fd.tva_tx ";
|
||||||
$sql .= " , fd.total_ttc,p.accountancy_code_sell, s.code_compta , ct.accountancy_code";
|
$sql .= " , fd.total_ttc,p.accountancy_code_sell, s.code_compta , ct.accountancy_code";
|
||||||
$sql .= " FROM ".MAIN_DB_PREFIX."facturedet fd ";
|
$sql .= " FROM ".MAIN_DB_PREFIX."facturedet fd ";
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product p ON p.rowid = fd.fk_product ";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product p ON p.rowid = fd.fk_product ";
|
||||||
$sql .= " JOIN ".MAIN_DB_PREFIX."facture f ON f.rowid = fd.fk_facture ";
|
$sql .= " JOIN ".MAIN_DB_PREFIX."facture f ON f.rowid = fd.fk_facture ";
|
||||||
$sql .= " JOIN ".MAIN_DB_PREFIX."societe s ON s.rowid = f.fk_soc";
|
$sql .= " JOIN ".MAIN_DB_PREFIX."societe s ON s.rowid = f.fk_soc";
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_tva ct ON fd.tva_tx = ct.taux AND ct.fk_pays = '".$idpays."'";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_tva ct ON fd.tva_tx = ct.taux AND ct.fk_pays = '".$idpays."'";
|
||||||
@ -93,7 +93,7 @@ if ($result)
|
|||||||
$tabht = array();
|
$tabht = array();
|
||||||
$tabtva = array();
|
$tabtva = array();
|
||||||
$tabttc = array();
|
$tabttc = array();
|
||||||
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i=0;
|
$i=0;
|
||||||
$resligne=array();
|
$resligne=array();
|
||||||
@ -101,17 +101,17 @@ if ($result)
|
|||||||
{
|
{
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
// les variables
|
// les variables
|
||||||
$cptcli = isset($conf->global->COMPTA_ACCOUNT_CUSTOMER)?$conf->global->COMPTA_ACCOUNT_CUSTOMER:$langs->trans("CodeNotDef");
|
$cptcli = (! empty($conf->global->COMPTA_ACCOUNT_CUSTOMER))?$conf->global->COMPTA_ACCOUNT_CUSTOMER:$langs->trans("CodeNotDef");
|
||||||
$compta_soc = isset($obj->code_compta)?$obj->code_compta:$cptcli;
|
$compta_soc = (! empty($obj->code_compta))?$obj->code_compta:$cptcli;
|
||||||
$compta_prod = $obj->accountancy_code_sell;
|
$compta_prod = $obj->accountancy_code_sell;
|
||||||
if (!isset($compta_prod))
|
if (empty($compta_prod))
|
||||||
{
|
{
|
||||||
if($obj->product_type == 0) $compta_prod = isset($conf->global->COMPTA_PRODUCT_SOLD_ACCOUNT)?$conf->global->COMPTA_PRODUCT_SOLD_ACCOUNT:$langs->trans("CodeNotDef") ;
|
if($obj->product_type == 0) $compta_prod = (! empty($conf->global->COMPTA_PRODUCT_SOLD_ACCOUNT))?$conf->global->COMPTA_PRODUCT_SOLD_ACCOUNT:$langs->trans("CodeNotDef") ;
|
||||||
else $compta_prod = isset($conf->global->COMPTA_SERVICE_SOLD_ACCOUNT)?$conf->global->COMPTA_SERVICE_SOLD_ACCOUNT:$langs->trans("CodeNotDef") ;
|
else $compta_prod = (! empty($conf->global->COMPTA_SERVICE_SOLD_ACCOUNT))?$conf->global->COMPTA_SERVICE_SOLD_ACCOUNT:$langs->trans("CodeNotDef") ;
|
||||||
}
|
}
|
||||||
$cpttva = isset($conf->global->COMPTA_VAT_ACCOUNT)?$conf->global->COMPTA_VAT_ACCOUNT:$langs->trans("CodeNotDef");
|
$cpttva = (! empty($conf->global->COMPTA_VAT_ACCOUNT))?$conf->global->COMPTA_VAT_ACCOUNT:$langs->trans("CodeNotDef");
|
||||||
$compta_tva = isset($obj->accountancy_code)?$obj->accountancy_code:$cpttva;
|
$compta_tva = (! empty($obj->accountancy_code))?$obj->accountancy_code:$cpttva;
|
||||||
|
|
||||||
//la ligne facture
|
//la ligne facture
|
||||||
$tabfac[$obj->rowid]["date"] = $obj->datef;
|
$tabfac[$obj->rowid]["date"] = $obj->datef;
|
||||||
$tabfac[$obj->rowid]["ref"] = $obj->facnumber;
|
$tabfac[$obj->rowid]["ref"] = $obj->facnumber;
|
||||||
@ -120,7 +120,7 @@ if ($result)
|
|||||||
$tabttc[$obj->rowid][$compta_soc] += $obj->total_ttc;
|
$tabttc[$obj->rowid][$compta_soc] += $obj->total_ttc;
|
||||||
$tabht[$obj->rowid][$compta_prod] += $obj->total_ht;
|
$tabht[$obj->rowid][$compta_prod] += $obj->total_ht;
|
||||||
$tabtva[$obj->rowid][$compta_tva] += $obj->total_tva;
|
$tabtva[$obj->rowid][$compta_tva] += $obj->total_tva;
|
||||||
|
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -128,18 +128,19 @@ else {
|
|||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Show result array
|
* Show result array
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
$i = 0;
|
$i = 0;
|
||||||
print "<table class=\"noborder\" width=\"100%\">";
|
print "<table class=\"noborder\" width=\"100%\">";
|
||||||
print "<tr class=\"liste_titre\">";
|
print "<tr class=\"liste_titre\">";
|
||||||
print "<td>".$langs->trans("JournalNum")."</td><td>".$langs->trans("Invoicedate")."</td><td>".$langs->trans("InvoiceRef")."</td>";
|
//print "<td>".$langs->trans("JournalNum")."</td>";
|
||||||
|
print "<td>".$langs->trans("Date")."</td><td>".$langs->trans("InvoiceRef")."</td>";
|
||||||
print "<td>".$langs->trans("Piece")."</td><td>".$langs->trans("Account")."</td>";
|
print "<td>".$langs->trans("Piece")."</td><td>".$langs->trans("Account")."</td>";
|
||||||
print "<t><td>".$langs->trans("InvoiceLib")."</td><td>".$langs->trans("AmountDbt")."</td><td>".$langs->trans("AmountCdt")."</td>";
|
print "<t><td>".$langs->trans("Label")."</td><td>".$langs->trans("Debit")."</td><td>".$langs->trans("Credit")."</td>";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
$var=true;
|
$var=true;
|
||||||
@ -149,7 +150,9 @@ foreach ($tabfac as $key => $val)
|
|||||||
{
|
{
|
||||||
print "<tr $bc[$var] >";
|
print "<tr $bc[$var] >";
|
||||||
//facture
|
//facture
|
||||||
print "<td>".$conf->global->COMPTA_JOURNAL_SELL."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
//print "<td>".$conf->global->COMPTA_JOURNAL_SELL."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
foreach ($tabttc[$key] as $k => $mt)
|
foreach ($tabttc[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td>".$mt."</td><td></td>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td>".$mt."</td><td></td>";
|
||||||
@ -158,16 +161,22 @@ foreach ($tabfac as $key => $val)
|
|||||||
// produit
|
// produit
|
||||||
foreach ($tabht[$key] as $k => $mt)
|
foreach ($tabht[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<tr><td>".$conf->global->COMPTA_JOURNAL_SELL."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
print "<tr>";
|
||||||
|
//print "<td>".$conf->global->COMPTA_JOURNAL_SELL."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
||||||
}
|
}
|
||||||
// tva
|
// tva
|
||||||
foreach ($tabtva[$key] as $k => $mt)
|
foreach ($tabtva[$key] as $k => $mt)
|
||||||
{
|
{
|
||||||
print "<tr><td>".$conf->global->COMPTA_JOURNAL_SELL."</td><td>".$val["date"]."</td><td>".$val["ref"]."</td><td>".$val["piece"]."</td>";
|
print "<tr>";
|
||||||
|
//print "<td>".$conf->global->COMPTA_JOURNAL_SELL."</td>";
|
||||||
|
print "<td>".$val["date"]."</td><td>".$val["ref"]."</td>";
|
||||||
|
print "<td>".$val["piece"]."</td>";
|
||||||
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
print "<td>".$k."</td><td>".$val["lib"]."</td><td></td><td>".$mt."</td></tr>";
|
||||||
}
|
}
|
||||||
|
|
||||||
$val = !$val;
|
$val = !$val;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -179,7 +188,7 @@ print "</table>";
|
|||||||
* Put here code to view linked object
|
* Put here code to view linked object
|
||||||
****************************************************/
|
****************************************************/
|
||||||
/*
|
/*
|
||||||
|
|
||||||
$myobject->load_object_linked($myobject->id,$myobject->element);
|
$myobject->load_object_linked($myobject->id,$myobject->element);
|
||||||
|
|
||||||
foreach($myobject->linked_object as $linked_object => $linked_objectid)
|
foreach($myobject->linked_object as $linked_object => $linked_objectid)
|
||||||
@ -987,32 +987,34 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after)
|
|||||||
// Rapports
|
// Rapports
|
||||||
if ($conf->compta->enabled || $conf->accounting->enabled)
|
if ($conf->compta->enabled || $conf->accounting->enabled)
|
||||||
{
|
{
|
||||||
|
$langs->load("compta");
|
||||||
|
|
||||||
// Bilan, resultats
|
// Bilan, resultats
|
||||||
$newmenu->add(DOL_URL_ROOT."/compta/resultat/index.php?leftmenu=ca&mainmenu=accountancy",$langs->trans("Reportings"),0,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
$newmenu->add(DOL_URL_ROOT."/compta/resultat/index.php?leftmenu=ca&mainmenu=accountancy",$langs->trans("Reportings"),0,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/index.php?leftmenu=ca",$langs->trans("ReportInOut"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/index.php?leftmenu=ca",$langs->trans("ReportInOut"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/clientfourn.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/clientfourn.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
/* On verra ca avec module compabilit<EFBFBD> expert
|
/* On verra ca avec module compabilite expert
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/compteres.php?leftmenu=ca","Compte de r<EFBFBD>sultat",2,$user->rights->compta->resultat->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/compteres.php?leftmenu=ca","Compte de resultat",2,$user->rights->compta->resultat->lire);
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/bilan.php?leftmenu=ca","Bilan",2,$user->rights->compta->resultat->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/resultat/bilan.php?leftmenu=ca","Bilan",2,$user->rights->compta->resultat->lire);
|
||||||
*/
|
*/
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/index.php?leftmenu=ca",$langs->trans("ReportTurnover"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/index.php?leftmenu=ca",$langs->trans("ReportTurnover"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/cumul.php?leftmenu=ca","Cumul<EFBFBD>",2,$user->rights->compta->resultat->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/cumul.php?leftmenu=ca","Cumule",2,$user->rights->compta->resultat->lire);
|
||||||
if ($conf->propal->enabled) {
|
if ($conf->propal->enabled) {
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/prev.php?leftmenu=ca","Pr<EFBFBD>visionnel",2,$user->rights->compta->resultat->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/prev.php?leftmenu=ca","Previsionnel",2,$user->rights->compta->resultat->lire);
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/comp.php?leftmenu=ca","Transform<EFBFBD>",2,$user->rights->compta->resultat->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/comp.php?leftmenu=ca","Transforme",2,$user->rights->compta->resultat->lire);
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/casoc.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/casoc.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/cabyuser.php?leftmenu=ca",$langs->trans("ByUsers"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/stats/cabyuser.php?leftmenu=ca",$langs->trans("ByUsers"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
|
||||||
// Journaux
|
// Journaux
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journaux/index.php?leftmenu=ca",$langs->trans("Journaux"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
//if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journaux/index.php?leftmenu=ca",$langs->trans("Journaux"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
//journaux
|
//journaux
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journaux/journalvente.php?leftmenu=ca",$langs->trans("JournalVente"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journal/sellsjournal.php?leftmenu=ca",$langs->trans("SellsJournal"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journaux/journalachat.php?leftmenu=ca",$langs->trans("JournalAchat"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if ($leftmenu=="ca") $newmenu->add(DOL_URL_ROOT."/compta/journal/purchasesjournal.php?leftmenu=ca",$langs->trans("PurchasesJournal"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -121,5 +121,6 @@ SellsJournal=Sales Journal
|
|||||||
PurchasesJournal=Purchases Journal
|
PurchasesJournal=Purchases Journal
|
||||||
DescSellsJournal=Sales Journal
|
DescSellsJournal=Sales Journal
|
||||||
DescPurchasesJournal=Purchases Journal
|
DescPurchasesJournal=Purchases Journal
|
||||||
|
InvoiceRef=Invoice ref.
|
||||||
CodeNotDef=Not defined
|
CodeNotDef=Not defined
|
||||||
|
|
||||||
|
|||||||
@ -121,7 +121,7 @@ ThirdPartyMustBeEditAsCustomer=Le tiers doit être défini comme client
|
|||||||
SellsJournal=Journal des ventes
|
SellsJournal=Journal des ventes
|
||||||
PurchasesJournal=Journal des achats
|
PurchasesJournal=Journal des achats
|
||||||
Journaux=Journaux
|
Journaux=Journaux
|
||||||
InvoiceRef=Référence Fourn.
|
InvoiceRef=Réf facture
|
||||||
Piece=Piece compta
|
Piece=Piece compta
|
||||||
DescSellsJournal=Journal des ventes
|
DescSellsJournal=Journal des ventes
|
||||||
DescPurchasesJournal=Journal des achats
|
DescPurchasesJournal=Journal des achats
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user