Skip to content
Snippets Groups Projects
Commit e6843a64 authored by aspangaro's avatar aspangaro
Browse files

FIX: Accountancy - 3.8 - Chart of accounts are limited on only one country

parent 53386e22
No related branches found
No related tags found
No related merge requests found
......@@ -208,10 +208,9 @@ print "<td>" . $langs->trans("Selectchartofaccounts") . "</td>";
print "<td>";
print '<select class="flat" name="chartofaccounts" id="chartofaccounts">';
$sql = "SELECT rowid, pcg_version, fk_pays, label, active";
$sql = "SELECT rowid, pcg_version, label, active";
$sql .= " FROM " . MAIN_DB_PREFIX . "accounting_system";
$sql .= " WHERE active = 1";
$sql .= " AND fk_pays = " . $mysoc->country_id;
dol_syslog('accountancy/admin/index.php:: $sql=' . $sql);
$resql = $db->query($sql);
......@@ -227,7 +226,7 @@ if ($resql) {
print '<option value="' . $row[0] . '"';
print $conf->global->CHARTOFACCOUNTS == $row[0] ? ' selected' : '';
print '>' . $row[1] . ' - ' . $row[3] . '</option>';
print '>' . $row[1] . ' - ' . $row[2] . '</option>';
$i ++;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment