$attributes3=$DB->get_records_sql_menu('SELECT u.id, CONCAT(firstname," ", lastname) as name FROM {user} as u inner join {groups_members} gm on u.id= gm.userid
$attributes3=$DB->get_records_sql_menu("SELECT u.id, CONCAT(firstname,' ', lastname) as name FROM {user} as u inner join {groups_members} gm on u.id= gm.userid
where u.firstname != "Guest User" AND gm.groupid=?',array($g_id),$limitfrom=0,$limitnum=0);
where u.firstname != 'Guest User' AND gm.groupid=?",array($g_id),$limitfrom=0,$limitnum=0);
}else{
}else{
$attributes3=$DB->get_records_sql_menu('SELECT id, CONCAT(firstname," ", lastname) as name FROM {user} where firstname != "Guest User"',null,$limitfrom=0,$limitnum=0);
$attributes3=$DB->get_records_sql_menu("SELECT id, CONCAT(firstname,' ', lastname) as name FROM {user} where firstname != 'Guest User'",null,$limitfrom=0,$limitnum=0);
}
}
$attributes4=$DB->get_records_sql_menu('SELECT u_id as id, (SELECT concat(firstname," ", lastname) FROM {user} WHERE id = u_id) as name FROM {learning_user_learningplan}
$attributes4=$DB->get_records_sql_menu("SELECT u_id as id, (SELECT concat(firstname,' ', lastname) FROM {user} WHERE id = u_id) as name FROM {learning_user_learningplan}
where lp_id = ?',array($lp_id),$limitfrom=0,$limitnum=0);
where lp_id = ?",array($lp_id),$limitfrom=0,$limitnum=0);
$attributes=$DB->get_records_sql_menu('SELECT u.u_id as id, (SELECT CONCAT(firstname," ", lastname)FROM {user} where username!="guest" AND id = u. u_id) as name FROM
$attributes=$DB->get_records_sql_menu("SELECT u.u_id as id, (SELECT CONCAT(firstname,' ', lastname)FROM {user} where username!='guest' AND id = u. u_id) as name FROM
{learning_user_learningplan} as u where lp_id= ?',array($lp_id),$limitfrom=0,$limitnum=0);
{learning_user_learningplan} as u where lp_id= ?",array($lp_id),$limitfrom=0,$limitnum=0);
$attributes=$DB->get_records_sql_menu('SELECT id, CONCAT(firstname," ", lastname)FROM {user} where username!="guest" AND id=?',array($u_id),$limitfrom=0,$limitnum=0);
$attributes=$DB->get_records_sql_menu("SELECT id, CONCAT(firstname,' ', lastname)FROM {user} where username!='guest' AND id=?",array($u_id),$limitfrom=0,$limitnum=0);
}else{
}else{
$attributes=$DB->get_records_sql_menu('SELECT id, CONCAT(firstname," ", lastname)FROM {user} where username!="guest"',array($params=null),$limitfrom=0,$limitnum=0);
$attributes=$DB->get_records_sql_menu("SELECT id, CONCAT(firstname,' ', lastname)FROM {user} where username!='guest'",array($params=null),$limitfrom=0,$limitnum=0);
@@ -133,12 +133,12 @@ function display_list($lp_id, $u_id) {
...
@@ -133,12 +133,12 @@ function display_list($lp_id, $u_id) {
$table->attributes=array('class'=>'display');
$table->attributes=array('class'=>'display');
$table->data=array();
$table->data=array();
$sql='select t_id, (select type_id from {learning_training} where id =t_id) as type_id, lp_id, lut.status, lut.remarks, `u_id` as id,(select training_name from {learning_training} where id =t_id)
$sql="select t_id, (select type_id from {learning_training} where id =t_id) as type_id, lp_id, lut.status, lut.remarks, `u_id` as id,(select training_name from {learning_training} where id =t_id)
as training, (select url from {learning_training} where id =t_id) as url, (select learning_plan from {learning_learningplan} where id =lp_id) as learning_plan, (SELECT
as training, (select url from {learning_training} where id =t_id) as url, (select learning_plan from {learning_learningplan} where id =lp_id) as learning_plan, (SELECT
CONCAT(firstname," ", lastname)FROM {user} where username!="guest" AND id = u_id) as name,(select
CONCAT(firstname,' ', lastname)FROM {user} where username!='guest' AND id = u_id) as name,(select
start_date from {learning_training} where id =t_id)as date1,(select end_date from {learning_training}
start_date from {learning_training} where id =t_id)as date1,(select end_date from {learning_training}
where id =t_id)as date2 from {learning_plan_training} lpt inner join {learning_user_trainingplan} lut
where id =t_id)as date2 from {learning_plan_training} lpt inner join {learning_user_trainingplan} lut
on lut.lpt_id=lpt.id where lpt.lp_id=? AND lut.u_id=?';//ORDER BY $orderby';
on lut.lpt_id=lpt.id where lpt.lp_id=? AND lut.u_id=?";//ORDER BY $orderby';