This commit is contained in:
Ricsi
2017-09-23 17:06:39 +02:00
parent 63bdbf9888
commit eb2e9b9e3f
63 changed files with 2211 additions and 57 deletions

View File

@@ -205,6 +205,10 @@ switch ($this->get_id()) {
# táborvezető létrehozása
$smarty->display('user_camp_leader_create.tpl');
break;
case 'user_group':
# táborvezető létrehozása
$smarty->display('user_group_create.tpl');
break;
default:
# code...
break;

View File

@@ -0,0 +1,12 @@
<?php
if ($this->is_id()) {
//$delete_query = "DELETE FROM user_kid WHERE uk_id = " . $this->get_id() . ";";
//$sql->execute_query($delete_query);
$sql->update_table('user_group', array('ug_deleted' => 1), array('ug_id' => $this->get_id()));
log::register('delete_user_group', $this->get_id());
header("Location: /admin/user_groups");
}
?>

View File

@@ -0,0 +1,34 @@
<?php
# HA NINCS ID, AKKOR CSOPORTLISTA
if ($this->is_id()) {
# CSOPORT SZERKESZTÉSE /TAGLISTA
$group = new user_group();
$group->set_ug_data_by_id($this->get_id());
$smarty->assign('user_group', $group);
$smarty->display('user_group_data_edit.tpl');
}
else {
# CSOPORT LISTA
$group_query = "SELECT * FROM user_group WHERE ug_deleted = 0 ORDER By ug_name ASC;";
$group_assoc_array = $sql->assoc_array($group_query);
$group_array = array();
foreach ($group_assoc_array as $group) {
$new_ug = new user_group();
$new_ug->set_ug_data_by_id($group['ug_id']);
$group_array[] = $new_ug;
}
$smarty->assign('user_group_array',$group_array);
$smarty->display('user_group_list.tpl');
}
?>