diff --git a/trunk/gosa-core/include/class_gosaSupportDaemon.inc b/trunk/gosa-core/include/class_gosaSupportDaemon.inc
index af297df05da0b8655b465b1e022912d05f46f949..e887252354804d877b9db9c3db12564feb2f2715 100644 (file)
}
- public function FAI_get_packages($release,$attrs,$package,$from=-1,$to=-1)
+ public function FAI_get_packages($release,$attrs,$package,$from=-1,$to=-1, $exclude_sections=array())
{
$ret = array();
/* If no package is given, search for all */
if(!count($package)) $package = array("%");
+ /* If no section is given, search for all */
+ $section_filter = "";
+ if(count($exclude_sections)) {
+ $section_filter = '<clause><connector>AND</connector>';
+ foreach ($exclude_sections as $section => $value) {
+ $section_filter .= "<phrase><operator>ne</operator><section>"
+ .$section
+ ."</section></phrase>";
+ }
+ $section_filter .= "</clause>";
+ }
+
/* Create limit tag */
if($from == -1){
$limit ="";
<clause><connector>OR</connector>
".$pkgs."
</clause>
+ ".$section_filter."
</where>".
$limit.
"</xml>";