<?php require_once("includes/requirecompere.inc.php"); $mb_id=current_mb_id(); $cg_id=TGET('cg_id'); $op=TGET('op'); $DBConn->connect(true); $dataset+=db_load_course_group($DBConn,$cg_id,$mb_id); $rules=db_load_course_group_limits($DBConn,$cg_id,$mb_id); $dataset['RULE']=$rules; $dataset['RULE-NONE']=$rules?array():array(0); $dataset['cg_id']=$cg_id; foreach ($dataset['RULE'] as &$rule) { $rule['WEEKLY0MINUTES']=$rule['cgl_view']=='weekly0_minutes'?array(0):array(); $rule['WEEKLY1MINUTES']=$rule['cgl_view']=='weekly1_minutes'?array(0):array(); } if ($op=='revise' && $_SESSION['reserv.inputcache.domain']=='coursegrouprule.manage') { $dataset+=$_SESSION['reserv.inputcache.errorareas']; } else if ($op=='set.ok') $dataset['SET-OK']=array(0); else if ($op=='delete.ok') $dataset['DELETE-OK']=array(0); ?>