From: dj3c1t Date: Sat, 21 Dec 2013 22:14:18 +0000 (+0100) Subject: correction bug source_groupes (data XML) X-Git-Tag: sourceml.1.1.4 X-Git-Url: http://git.dj3c1t.com/index.cgi?p=mw_sourceml;a=commitdiff_plain;h=2d7c814e3ce8981bb017e81d8218501b8a913d3f correction bug source_groupes (data XML) --- diff --git a/app/config.xml b/app/config.xml index 426156c..d0fe939 100644 --- a/app/config.xml +++ b/app/config.xml @@ -1,7 +1,7 @@ - 1.1.3 + 1.1.4 parent diff --git a/app/data/modules/xml/sml_data_source_groupes.php b/app/data/modules/xml/sml_data_source_groupes.php index f85b617..cc21ed9 100644 --- a/app/data/modules/xml/sml_data_source_groupes.php +++ b/app/data/modules/xml/sml_data_source_groupes.php @@ -106,11 +106,13 @@ while(($sources !== false) && $v_rst = $sgbd->fetch_data($rst)){ if(isset($v_rst) && isset($v_rst["id"])){ if(isset($_sources[$v_rst["id"]])){ - if(!isset($sources[$v_rst["id"]])){ - $sources[$v_rst["id"]] = $v_rst; - $sources[$v_rst["id"]]["authors"] = array(); + if(!isset($params["id_class"]) || (isset($v_rst["id_class"]) && ($v_rst["id_class"] == $params["id_class"]))){ + if(!isset($sources[$v_rst["id"]])){ + $sources[$v_rst["id"]] = $v_rst; + $sources[$v_rst["id"]]["authors"] = array(); + } + $sources[$v_rst["id"]]["authors"][] = $_sources[$v_rst["id"]]["id_author"]; } - $sources[$v_rst["id"]]["authors"][] = $_sources[$v_rst["id"]]["id_author"]; } } else $sources = false;