diff --git a/html/comptanalytic.php b/html/comptanalytic.php index 1485889e5..733c92238 100644 --- a/html/comptanalytic.php +++ b/html/comptanalytic.php @@ -75,6 +75,9 @@ if ( isset ($_REQUEST['p_action'])) $User->AccessRequest($cn,CA_IMPRESSION); $def=2; break; + case 'ca_groupe': + $def=3; + break; } } echo ShowItem(array( @@ -117,7 +120,7 @@ if ($_REQUEST['p_action'] == 'ca_od' ) // Impression if ($_REQUEST['p_action'] == 'ca_groupe' ) { - require_once('ca_groupe.inc.php'); + require_once('ca_group.inc.php'); exit(); } diff --git a/include/ca_group.inc.php b/include/ca_group.inc.php new file mode 100644 index 000000000..86b3891ba --- /dev/null +++ b/include/ca_group.inc.php @@ -0,0 +1,78 @@ +ga_id=$m; + $obj->remove(); + } + } + } + +//---------------------------------------------------------------------- +// INSERT +if ( isset($_POST['add'])) { + $obj=new Anc_Group($cn); + $obj->fill_from_array($_POST); + $obj->insert(); + } +$array=$r->myList(); + +echo '
'; +echo '
'; +echo dossier::hidden(); +echo ''; +echo ''; +foreach ($array as $idx=>$m) { + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; +} +$w=new widget("text"); +echo ""; +echo "";; + +echo '
Code Description
'.$m->ga_id.''.$m->ga_description.' Effacer '.'
".$w->IOValue("ga_id")."".$w->IOValue("ga_description"). +widget::submit_button('add','Ajouter'). +"
'; + +echo "
"; +echo widget::submit_button('remove','Effacer'); + +echo '
'; diff --git a/include/class_anc_group.php b/include/class_anc_group.php index d3ae91641..cc6d8a626 100644 --- a/include/class_anc_group.php +++ b/include/class_anc_group.php @@ -63,7 +63,7 @@ class Anc_Group { $this->ga_id=str_replace(' ','',$this->ga_id); $this->ga_id=strtoupper($this->ga_id); $sql=" delete from groupe_analytique where ga_id='".pg_escape_string($this->ga_id)."'"; - print_r($sql); + ExecSql($this->db,$sql); }