';
+ echo '';
for ($e=0; $eDéfaut':'';
- $js=sprintf(
- '%s', $gDossier, $menu['pm_id'], $me_code);
?>
- -
+
";
- echo '';
- }
- else
- {
- $this->cn->prepare("menu", "
- SELECT pm_id,
- pm.me_code,
- me_code_dep,
- p_id,
- p_order,
- p_type_display,
- pm_default,
- pm_desc,
- me_menu,
- me_description
- FROM profile_menu as pm
- join profile_menu_type on (p_type_display=pm_type)
- join menu_ref as mr on (mr.me_code=pm.me_code)
- where
- p_id=$1 and me_code_dep=$2 and p_type_display in ('E','S')
- order by p_order asc
- ");
- echo '';
- // Menu by module
- $gDossier=Dossier::id();
- for ($i=0; $iDéfaut':'';
- $js=sprintf('%s', $gDossier, $array[$i]['pm_id'], $array[$i]['me_code']);
- echo "- ".$array[$i]['me_menu']." (".$js.")".$array[$i]['me_description']." ".$me_def;
-
- $ret=$this->cn->execute("menu", array($p_id, $array[$i]['me_code']));
- $this->sub_menu($ret, $p_id);
-
- echo "
";
- }// end loop i
- echo ' ';
- //*******************************************
- // show also menu without a module
- //*******************************************
- $ret=$this->cn->exec_sql("
+ //*******************************************
+ // show also menu without a module
+ //*******************************************
+ $ret=$this->cn->exec_sql("
SELECT pm_id,
pm.me_code,
me_code_dep,
@@ -199,16 +149,57 @@ class Profile_Menu extends Profile_Menu_sql
where
p_id=$1 and p_type_display not in ('M','P') and me_code_dep is null
order by p_order asc
- ", array($p_id));
- if (Database::num_row($ret))
- {
- echo "Menu sans module";
- $this->sub_menu($ret, $p_id);
- }
- }
+ ", array($this->p_id));
}
- function printing($p_id)
+ /**
+ * @brief Display the module, with a javascript inside to show the menu
+ * contained in the module
+ * Used for setting the configuration
+ * @param $ap_module $array of module received from display_profile_menu_detail
+ * @see Profile_menu::display_profile_menu_detail
+ */
+ function display_module($ap_module)
+ {
+ include NOALYSS_INCLUDE.'/template/profile_menu_display_module.php';
+ }
+
+ /**
+ * @brief Display all menu and submenu of a module.
+ * @see display_profile_module
+ *
+ */
+ function display_module_menu($p_module_id, $p_level)
+ {
+ // Get the submenu
+ $a_module=$this->cn->get_array('
+ SELECT pm_id,
+ me_code,
+ me_code_dep,
+ p_id,
+ p_order,
+ p_type_display,
+ pm_default,
+ me_menu,
+ me_file,
+ me_url,
+ me_javascript,
+ me_parameter,
+ me_description
+ FROM profile_menu
+ join menu_ref using (me_code)
+ where
+ p_id = $1 and
+ pm_id_dep = $2 order by p_order',
+ array($this->p_id, $p_module_id));
+ require NOALYSS_INCLUDE.'/template/profile_menu_display_submenu.php';
+ }
+
+ /**
+ * display all the accessible export of a profile $p_id
+ * @param type $p_id profile.p_id
+ */
+ function printing()
{
$ret=$this->cn->exec_sql("
SELECT pm_id,
@@ -227,17 +218,17 @@ class Profile_Menu extends Profile_Menu_sql
where
p_id=$1 and me_type='PR'
order by p_order asc
- ", array($p_id));
+ ", array($this->p_id));
// Menu by module
$gDossier=Dossier::id();
- $this->sub_menu($ret, $p_id);
+ $this->sub_menu($ret, $this->p_id);
}
/**
* Show the available profile for the profile $p_id, it concerns only the action of management (action-gestion)
* @param $p_id is the profile p_id
*/
- function available_profile($p_id)
+ function available_profile()
{
$array=$this->cn->get_array("
select p.p_id,p.p_name,s.p_granted,s.ua_id,s.ua_right
@@ -249,7 +240,7 @@ class Profile_Menu extends Profile_Menu_sql
from profile as p2
where
p2.p_id not in (select p_granted from user_sec_action_profile where p_id = $1) order by p_name;
- ", array($p_id));
+ ", array($this->p_id));
$aright_value=array(
array('value'=>'R', 'label'=>_('Lecture')),
array('value'=>'W', 'label'=>_('Ecriture')),
@@ -262,7 +253,7 @@ class Profile_Menu extends Profile_Menu_sql
* Show the available repository for the profile $p_id
* @param $p_id is the profile p_id
*/
- function available_repository($p_id)
+ function available_repository()
{
$array=$this->cn->get_array("
select p.r_id,p.r_name,s.ur_id,s.ur_right
@@ -274,7 +265,7 @@ class Profile_Menu extends Profile_Menu_sql
from stock_repository as p2
where
p2.r_id not in (select r_id from profile_sec_repository where p_id = $1) order by r_name;
- ", array($p_id));
+ ", array($this->p_id));
$aright_value=array(
array('value'=>'R', 'label'=>_('Lecture')),
array('value'=>'W', 'label'=>_('Ecriture')),
diff --git a/include/class_user.php b/include/class_user.php
index 8852440fb..a856114f9 100644
--- a/include/class_user.php
+++ b/include/class_user.php
@@ -1110,7 +1110,7 @@ class User
function get_profile()
{
$profile = $this->db->get_value("select p_id from profile_user where
- user_name=$1", array($this->login));
+ lower(user_name)=lower($1)", array($this->login));
return $profile;
}
/**
diff --git a/include/profile.inc.php b/include/profile.inc.php
index 4c2b4e44d..3ab96df23 100644
--- a/include/profile.inc.php
+++ b/include/profile.inc.php
@@ -18,7 +18,8 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
// Copyright Author Dany De Bontridder danydb@aevalys.eu
-if ( ! defined ('ALLOWED') ) die('Appel direct ne sont pas permis');
+if (!defined('ALLOWED'))
+ die('Appel direct ne sont pas permis');
require_once NOALYSS_INCLUDE.'/class_profile_sql.php';
global $cn;
@@ -27,70 +28,76 @@ global $cn;
//**********************************************
if (isset($_POST['change_profile']))
{
- extract($_POST);
- try
- {
- for ($e = 0; $e < count($right); $e++)
- {
- if ($right[$e] == 'X' && $ua_id[$e]=='')
- continue;
- if ($right[$e] == 'X' && $ua_id[$e]!='')
- {
- $cn->exec_sql("delete from user_sec_action_profile where p_id=$1 and p_granted=$2", array($p_id, $ap_id[$e]));
- continue;
- }
- if ($ua_id[$e] == "")
- {
- $cn->exec_sql("insert into user_sec_action_profile (p_id,p_granted,ua_right) values($1,$2,$3)", array($p_id, $ap_id[$e], $right[$e]));
- continue;
- }
- if ($ua_id[$e] != '')
- {
- $cn->exec_sql("update user_sec_action_profile set ua_right=$3 where p_id=$1 and p_granted=$2 ", array($p_id, $ap_id[$e], $right[$e]));
- continue;
- }
- }
- }
- catch (Exception $exc)
- {
- echo $exc->getTraceAsString();
- throw $exc;
- }
+ extract($_POST);
+ try
+ {
+ for ($e=0; $eexec_sql("delete from user_sec_action_profile where p_id=$1 and p_granted=$2",
+ array($p_id, $ap_id[$e]));
+ continue;
+ }
+ if ($ua_id[$e]=="")
+ {
+ $cn->exec_sql("insert into user_sec_action_profile (p_id,p_granted,ua_right) values($1,$2,$3)",
+ array($p_id, $ap_id[$e], $right[$e]));
+ continue;
+ }
+ if ($ua_id[$e]!='')
+ {
+ $cn->exec_sql("update user_sec_action_profile set ua_right=$3 where p_id=$1 and p_granted=$2 ",
+ array($p_id, $ap_id[$e], $right[$e]));
+ continue;
+ }
+ }
+ }
+ catch (Exception $exc)
+ {
+ echo $exc->getTraceAsString();
+ throw $exc;
+ }
}
//**********************************************
// Save avail. profiles
//**********************************************
if (isset($_POST['change_stock']))
{
- extract($_POST);
- try
- {
- for ($e = 0; $e < count($right); $e++)
- {
- if ($right[$e] == 'X' && $ur_id[$e]=='')
- continue;
- if ($right[$e] == 'X' && $ur_id[$e]!='')
- {
- $cn->exec_sql("delete from profile_sec_repository where p_id=$1 and r_id=$2", array($p_id, $ar_id[$e]));
- continue;
- }
- if ($ur_id[$e] == "")
- {
- $cn->exec_sql("insert into profile_sec_repository (p_id,r_id,ur_right) values($1,$2,$3)", array($p_id, $ar_id[$e], $right[$e]));
- continue;
- }
- if ($ur_id[$e] != '')
- {
- $cn->exec_sql("update profile_sec_repository set ur_right=$3 where p_id=$1 and r_id=$2 ", array($p_id, $ar_id[$e], $right[$e]));
- continue;
- }
- }
- }
- catch (Exception $exc)
- {
- echo $exc->getTraceAsString();
- throw $exc;
- }
+ extract($_POST);
+ try
+ {
+ for ($e=0; $eexec_sql("delete from profile_sec_repository where p_id=$1 and r_id=$2",
+ array($p_id, $ar_id[$e]));
+ continue;
+ }
+ if ($ur_id[$e]=="")
+ {
+ $cn->exec_sql("insert into profile_sec_repository (p_id,r_id,ur_right) values($1,$2,$3)",
+ array($p_id, $ar_id[$e], $right[$e]));
+ continue;
+ }
+ if ($ur_id[$e]!='')
+ {
+ $cn->exec_sql("update profile_sec_repository set ur_right=$3 where p_id=$1 and r_id=$2 ",
+ array($p_id, $ar_id[$e], $right[$e]));
+ continue;
+ }
+ }
+ }
+ catch (Exception $exc)
+ {
+ echo $exc->getTraceAsString();
+ throw $exc;
+ }
}
//**********************************************
// Save_name
@@ -99,250 +106,289 @@ if (isset($_POST['change_stock']))
if (isset($_POST['save_name']))
{
- extract($_POST);
- try
- {
- if (strlen(trim($p_name)) == 0)
- throw new Exception("Nom ne peut être vide");
- if (isNumber($p_id) == 0)
- throw new Exception("profile Invalide");
- $wc = (isset($with_calc)) ? 1 : 0;
- $wd = (isset($with_direct_form)) ? 1 : 0;
- $p_desc = (strlen(trim($p_desc)) == 0) ? null : trim($p_desc);
- if ($p_id != -1)
- {
- $cn->exec_sql("update profile set p_name=$1,p_desc=$2,
- with_calc=$3, with_direct_form=$4 where p_id=$5", array($p_name,
- $p_desc, $wc, $wd, $p_id));
- }
- else
- {
- $p_id = $cn->get_value("insert into profile (p_name,
+ extract($_POST);
+ try
+ {
+ if (strlen(trim($p_name))==0)
+ throw new Exception("Nom ne peut être vide");
+ if (isNumber($p_id)==0)
+ throw new Exception("profile Invalide");
+ $wc=(isset($with_calc))?1:0;
+ $wd=(isset($with_direct_form))?1:0;
+ $p_desc=(strlen(trim($p_desc))==0)?null:trim($p_desc);
+ if ($p_id!=-1)
+ {
+ $cn->exec_sql("update profile set p_name=$1,p_desc=$2,
+ with_calc=$3, with_direct_form=$4 where p_id=$5",
+ array($p_name,
+ $p_desc, $wc, $wd, $p_id));
+ }
+ else
+ {
+ $p_id=$cn->get_value("insert into profile (p_name,
p_desc,with_calc,with_direct_form) values
- ($1,$2,$3,$4) returning p_id", array(
- $p_name, $p_desc, $wc, $wd
- ));
- }
- }
- catch (Exception $e)
- {
- alert($e->getMessage());
- }
+ ($1,$2,$3,$4) returning p_id",
+ array(
+ $p_name, $p_desc, $wc, $wd
+ ));
+ }
+ }
+ catch (Exception $e)
+ {
+ alert($e->getMessage());
+ }
}
//************************************
// Clone
//************************************
if (isset($_POST['clone']))
{
- extract($_POST);
- try
- {
- $cn->start();
- $new_id = $cn->get_value("insert into profile(p_name,p_desc,with_calc,
+ extract($_POST);
+ try
+ {
+ $cn->start();
+ $new_id=$cn->get_value("insert into profile(p_name,p_desc,with_calc,
with_direct_form)
select 'copie de '||p_name,p_desc,with_calc,
with_direct_form from profile where p_id=$1 returning p_id", array($p_id));
- $cn->exec_sql("
+ $cn->exec_sql("
insert into profile_menu (p_id,me_code,me_code_dep,p_order,p_type_display,pm_default)
select $1,me_code,me_code_dep,p_order,p_type_display,pm_default from profile_menu
where p_id=$2
", array($new_id, $p_id));
- $cn->commit();
- $p_id = $new_id;
- }
- catch (Exception $exc)
- {
- echo alert($exc->getMessage());
- $cn->rollback();
- }
+ $cn->commit();
+ $p_id=$new_id;
+ }
+ catch (Exception $exc)
+ {
+ echo alert($exc->getMessage());
+ $cn->rollback();
+ }
}
//************************************
// Delete
//************************************
if (isset($_POST['delete_profil']))
{
- extract($_POST);
- try
- {
- $cn->start();
- if ($p_id == 1)
- {
- throw new Exception('On ne peut pas effacer le profil par défaut');
- }
- $new_id = $cn->get_value("delete from profile
+ extract($_POST);
+ try
+ {
+ $cn->start();
+ if ($p_id==1)
+ {
+ throw new Exception('On ne peut pas effacer le profil par défaut');
+ }
+ $new_id=$cn->get_value("delete from profile
where p_id=$1 ", array($p_id));
- $cn->commit();
-
- }
- catch (Exception $exc)
- {
- echo alert($exc->getMessage());
- $cn->rollback();
- }
+ $cn->commit();
+ }
+ catch (Exception $exc)
+ {
+ echo alert($exc->getMessage());
+ $cn->rollback();
+ }
}
//************************************
// Modify the menu or delete it
//************************************
if (isset($_POST['mod']))
{
- extract($_POST);
- if (isset($delete) || isset($del_dep))
- {
- try
- {
- $cn->start();
- if (isset($del_dep))
- {
- $cn->exec_sql("delete from profile_menu where pm_id in (select * from get_menu_dependency($1))", array($pm_id));
- }
- $cn->exec_sql("delete from profile_menu where pm_id=$1", array($pm_id));
- $cn->commit();
- }
- catch (Exception $exc)
- {
- echo $exc->getMessage();
- $cn->rollback();
- }
- }
- else
- try
- {
- /**
- * Printing cannot be a menu and do not depend of anything
- */
- $menu_type = $cn->get_value("select me_type from menu_ref
+ // pm_id of the menu to modify
+ $pm_id=HtmlInput::default_value_post("pm_id", 0);
+ // profile id
+ $p_id=HtmlInput::default_value_post("p_id", "");
+ // display order
+ $p_order=HtmlInput::default_value_post("p_order", 0);
+ // code to add
+ $me_code=HtmlInput::default_value_post("me_code", "");
+ // tab
+ $tab=HtmlInput::default_value_post("tab", "");
+ // set Default
+ $pm_default=HtmlInput::default_value_post('pm_default', 0);
+ try
+ {
+ if ($pm_id==""||
+ $p_id==""||
+ $p_order==""||
+ $me_code==""
+ )
+ throw new Exception('Argument');
+ /**
+ * Printing cannot be a menu and do not depend of anything
+ */
+ $menu_type=$cn->get_value("select me_type from menu_ref
where me_code=$1", array($me_code));
- if ($menu_type == 'PR')
- {
- $p_type = 'P';
- $me_code_dep = -1;
- }
- /**
- * Check if we don't add a menu depending on itself
- */
- if ( $me_code == $me_code_dep )
- throw new Exception("Un menu ne peut pas dépendre de lui-même");
- $cn->start();
- $me_code_dep = ($me_code_dep == -1) ? null : $me_code_dep;
- $pm_default = (isset($pm_default)) ? 1 : 0;
- $p_order = (strlen(trim($p_order)) == 0) ? "0" : $p_order;
- if ($pm_default == 1)
- {
- $cn->exec_sql("update profile_menu set pm_default=0
- where p_id=(select p_id from profile_menu
+ if ($menu_type=='PR')
+ {
+ $p_type='P';
+ $me_code_dep=-1;
+ }
+ $cn->start();
+ $p_order=(strlen(trim($p_order))==0)?"0":$p_order;
+ if ($pm_default==1)
+ {
+ // reset all default
+ $cn->exec_sql("update profile_menu set pm_default=0
+ where pm_id_dep=(select pm_id_dep from profile_menu
where
pm_id=$1)", array($pm_id));
- }
- $cn->exec_sql("update profile_menu set me_code=$1,me_code_dep=$2,p_order=$3,pm_default=$4
- where pm_id=$5", array($me_code, $me_code_dep, $p_order, $pm_default, $pm_id));
- $cn->commit();
- }
- catch (Exception $e)
- {
- $cn->rollback();
- alert($e->getMessage());
- }
+ }
+ $cn->exec_sql("update profile_menu set me_code=$1,p_order=$2,pm_default=$3
+ where pm_id=$4", array($me_code, $p_order, $pm_default, $pm_id));
+ $cn->commit();
+ }
+ catch (Exception $e)
+ {
+ $cn->rollback();
+ alert($e->getMessage());
+ }
}
//****************************************************
// Add a menu, module, submenu,plugin...
//****************************************************
-if (isset($_POST['add_menu']) || isset($_POST['add_impress']))
+if (isset($_POST['add_menu'])||isset($_POST['add_impress']))
{
- extract($_POST);
- try
- {
- $cn->start();
-
- /**
- * Printing cannot be a menu and do not depend of anything
- */
- $menu_type = $cn->get_value("select me_type from menu_ref
- where me_code=$1", array($me_code));
-
- if ($menu_type == 'PR')
- {
- $p_type = 'P';
- $me_code_dep = -1;
- }
-
- // Module never depends of anything
- if ($p_type == 'M')
- {
- $me_code_dep = -1;
- }
- /**
- * Check for infinite loop
- */
- $inf = $cn->get_value("select count(*) from profile_menu
- where p_id=$1 and me_code_dep=$2 and me_code=$3", array($p_id, $me_code, $me_code_dep));
- if ($inf > 0)
- throw new Exception("Boucle infinie");
- /**
- * Check if we don't add a menu depending on itself
- */
- if ( $me_code == $me_code_dep )
- throw new Exception("Un menu ne peut pas dépendre de lui-même");
+ // type of menu me or pr
+ $p_type=HtmlInput::default_value_post("type", "");
+ // level
+ $p_level=HtmlInput::default_value_post("p_level", "");
+ // pm_id of menu parent
+ $p_dep=HtmlInput::default_value_post("dep", "");
+ // profile id
+ $p_id=HtmlInput::default_value_post("p_id", "");
+ // display order
+ $p_order=HtmlInput::default_value_post("p_order", 0);
+ // code to add
+ $me_code=HtmlInput::default_value_post("me_code", "");
+ // tab
+ $tab=HtmlInput::default_value_post("tab", "");
+ try
+ {
+ $cn->start();
- /**
- * if me_code_dep == -1, it means it is null
- */
- $me_code_dep = ($me_code_dep == -1) ? null : $me_code_dep;
+ /**
+ * Printing cannot be a menu and do not depend of anything
+ */
+ $menu_type=$cn->get_value("select me_type from menu_ref
+ where me_code=$1", array($me_code));
- $pm_default = (isset($pm_default)) ? 1 : 0;
- $cn->exec_sql("
- insert into profile_menu (me_code,me_code_dep,p_id,p_order,pm_default,p_type_display)
- values ($1,$2,$3,$4,$5,$6)
- ", array($me_code, $me_code_dep, $p_id, $p_order, $pm_default, $p_type));
+ if ($menu_type=='PR')
+ {
+ $p_type='P';
+ $me_code_dep=null;
+ $pm_id_dep=null;
+ }
- $cn->commit();
- }
- catch (Exception $exc)
- {
- alert($exc->getMessage());
- }
+ // Module never depends of anything
+ if ($p_type=='me')
+ {
+ /*
+ * Check variable
+ */
+ if ($p_type==""||
+ $p_level==""||
+ $p_dep==""||
+ $p_id==""||
+ $me_code==""
+ )
+ throw new Exception('Argument');
+ if ($p_level==0)
+ {
+ $me_code_dep=null;
+ $pm_id_dep=null;
+ $p_type='M';
+ }
+ else
+ {
+ $me_code_dep=$cn->get_value('select me_code from profile_menu'
+ .' where pm_id = $1 and p_id=$2', array($p_dep, $p_id));
+ $pm_id_dep=$p_dep;
+ $p_type='E';
+ }
+ }
+ /**
+ * Check for infinite loop
+ */
+ $inf=$cn->get_value("select count(*) from profile_menu
+ where p_id=$1 and me_code_dep=$2 and me_code=$3",
+ array($p_id, $me_code, $me_code_dep));
+ if ($inf>0)
+ throw new Exception("Boucle infinie");
+ /**
+ * Check if we don't add a menu depending on itself
+ */
+ if ($me_code==$me_code_dep)
+ throw new Exception("Un menu ne peut pas dépendre de lui-même");
+
+
+ /**
+ * if me_code_dep == -1, it means it is null
+ */
+ $me_code_dep=($me_code_dep==-1)?null:$me_code_dep;
+
+ $pm_default=(isset($pm_default))?1:0;
+ $cn->exec_sql("
+ insert into profile_menu (me_code,me_code_dep,p_id,p_order,pm_default,p_type_display,pm_id_dep)
+ values ($1,$2,$3,$4,$5,$6,$7)
+ ",
+ array($me_code, $me_code_dep, $p_id, $p_order, $pm_default, $p_type,
+ $pm_id_dep));
+
+ $cn->commit();
+ }
+ catch (Exception $exc)
+ {
+ alert($exc->getMessage());
+ }
}
echo '';
-$table = new Sort_Table();
-$url = $_SERVER['REQUEST_URI'];
+$table=new Sort_Table();
+$url=$_SERVER['REQUEST_URI'];
-$table->add(_('Nom'), $url, "order by p_name asc", "order by p_name desc", "na", "nd");
-$table->add(_('Description'), $url, "order by p_desc asc", "order by p_desc desc", "da", "dd");
-$table->add(_('Calculatrice visible'), $url, "order by with_calc asc", "order by with_calc desc", "ca", "cd");
-$table->add(_('Accès Direct visible'), $url, "order by with_direct_form asc", "order by with_direct_form desc", "fa", "fd");
+$table->add(_('Nom'), $url, "order by p_name asc", "order by p_name desc", "na",
+ "nd");
+$table->add(_('Description'), $url, "order by p_desc asc",
+ "order by p_desc desc", "da", "dd");
+$table->add(_('Calculatrice visible'), $url, "order by with_calc asc",
+ "order by with_calc desc", "ca", "cd");
+$table->add(_('Accès Direct visible'), $url, "order by with_direct_form asc",
+ "order by with_direct_form desc", "fa", "fd");
-$ord = (isset($_REQUEST['ord'])) ? $_REQUEST['ord'] : 'na';
+$ord=(isset($_REQUEST['ord']))?$_REQUEST['ord']:'na';
-$order = $table->get_sql_order($ord);
+$order=$table->get_sql_order($ord);
-$menu = new Profile_sql($cn);
-$ret = $menu->seek("where p_id > 0 ".$order);
+$menu=new Profile_sql($cn);
+$ret=$menu->seek("where p_id > 0 ".$order);
echo ' ';
echo '';
-echo '| ' . $table->get_header(0) . ' | ';
-echo '' . $table->get_header(1) . ' | ';
-echo '' . $table->get_header(2) . ' | ';
-echo '' . $table->get_header(3) . ' | ';
+echo ''.$table->get_header(0).' | ';
+echo ''.$table->get_header(1).' | ';
+echo ''.$table->get_header(2).' | ';
+echo ''.$table->get_header(3).' | ';
echo ' ';
-$gDossier = Dossier::id();
-for ($i = 0; $i < Database::num_row($ret); $i++)
+$gDossier=Dossier::id();
+for ($i=0; $iget_object($ret, $i);
+ $row=$menu->get_object($ret, $i);
- $js = sprintf('', $gDossier, $row->p_id);
- echo '';
- echo "| " . $js . $row->p_name . '' . ' | ';
- echo td($row->p_desc);
- echo td($row->with_calc);
- echo td($row->with_direct_form);
- echo ' ';
+ $js=sprintf('',
+ $gDossier, $row->p_id);
+ echo '';
+ echo "| ".$js.$row->p_name.''.' | ';
+ echo td($row->p_desc);
+ echo td($row->with_calc);
+ echo td($row->with_direct_form);
+ echo ' ';
}
-$js = sprintf('', $gDossier, -1);
+$js=sprintf('',
+ $gDossier, -1);
echo '';
-echo "| " . $js . "Ajouter un profil | ";
+echo "".$js."Ajouter un profil | ";
echo ' ';
echo ' ';
echo ' ';
@@ -354,21 +400,23 @@ echo '';
echo '';
if (isset($_POST['p_id']))
{
- require_once NOALYSS_INCLUDE.'/ajax_get_profile.php';
- ?>
-
-
+ ';
-if ( isset($_POST['delete_profil'] ))
+if (isset($_POST['delete_profil']))
{
- echo create_script(" $('detail_profile').hide()");
-?>
-
-
+
diff --git a/include/template/menu.php b/include/template/menu.php
index 99e35367a..07e8dd37c 100644
--- a/include/template/menu.php
+++ b/include/template/menu.php
@@ -2,9 +2,9 @@
//This file is part of NOALYSS and is under GPL
//see licence.txt
?> |