Fix left join on expensereport lines
This commit is contained in:
parent
36402c22ee
commit
9b46ae50f0
@ -2428,7 +2428,7 @@ class ExpenseReportLine
|
||||
$sql.= ' ctf.code as type_fees_code, ctf.label as type_fees_libelle,';
|
||||
$sql.= ' pjt.rowid as projet_id, pjt.title as projet_title, pjt.ref as projet_ref';
|
||||
$sql.= ' FROM '.MAIN_DB_PREFIX.'expensereport_det as fde';
|
||||
$sql.= ' INNER JOIN '.MAIN_DB_PREFIX.'c_type_fees as ctf ON fde.fk_c_type_fees=ctf.id';
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_type_fees as ctf ON fde.fk_c_type_fees=ctf.id'; // Sometimes type of expense report has been removed, so we use a left join here.
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'projet as pjt ON fde.fk_projet=pjt.rowid';
|
||||
$sql.= ' WHERE fde.rowid = '.$rowid;
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user