From 00c250522bc6162c75738afb040389eafa0c5988 Mon Sep 17 00:00:00 2001 From: Janusz Dobrowolski Date: Fri, 22 May 2009 09:00:25 +0000 Subject: [PATCH] Fixed buggy reference instead of id in report deminesion selectors. --- CHANGELOG.txt | 4 ++++ reporting/includes/reports_classes.inc | 12 ++++++------ 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index adf0c391..bcf157a5 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,10 @@ Legend: ! -> Note $ -> Affected files +22-May-2009 Janusz Dobrowolski +# Fixed buggy reference instead of id in report dimension selectors. +$ /reporting/includes/reports_classes.inc + 21-May-2009 Joe Hunt/Tom Moulton # Recursion fix in manufacturing_db.inc by Tom Moulton $ /includes/db/manufacturing_db.inc diff --git a/reporting/includes/reports_classes.inc b/reporting/includes/reports_classes.inc index 3d869980..d5e6afbe 100644 --- a/reporting/includes/reports_classes.inc +++ b/reporting/includes/reports_classes.inc @@ -215,27 +215,27 @@ class Report $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy); break; case 'DIMENSION': - $sql = "SELECT reference, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy); break; case 'DIMENSIONS': - $sql = "SELECT reference, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy, true, _("No Dimension Filter"), true); break; case 'DIMENSION1': - $sql = "SELECT reference, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions WHERE type_=1 ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions WHERE type_=1 ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index". "_$index", $dummy); break; case 'DIMENSIONS1': - $sql = "SELECT reference, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions WHERE type_=1 ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions WHERE type_=1 ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy, true, _("No Dimension Filter"), true); break; case 'DIMENSION2': - $sql = "SELECT reference, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions WHERE type_=2 ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) AS DimName FROM ".TB_PREF."dimensions WHERE type_=2 ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy); break; case 'DIMENSIONS2': - $sql = "SELECT reference, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions WHERE type_=2 ORDER BY reference"; + $sql = "SELECT id, concat(reference, ' - ', name) as DimName FROM ".TB_PREF."dimensions WHERE type_=2 ORDER BY reference"; $st .= dup_simple_codeandname_list($sql, "PARAM_$index", $dummy, true, _("No Dimension Filter"), true); break; case 'CUSTOMERS_NO_FILTER': -- 2.30.2