summaryrefslogtreecommitdiffstats
path: root/lib/class/user.class.php
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-07-12 05:45:48 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-07-12 05:45:48 +0000
commit1a5d32fbbe96ab2d936693020bb24bed4a1af78e (patch)
tree49c325ef550b145fa7fc04f85d65d158a7c7df65 /lib/class/user.class.php
parent7be9eb4ea1e868fa0725334697057e1b7b994460 (diff)
downloadampache-1a5d32fbbe96ab2d936693020bb24bed4a1af78e.tar.gz
ampache-1a5d32fbbe96ab2d936693020bb24bed4a1af78e.tar.bz2
ampache-1a5d32fbbe96ab2d936693020bb24bed4a1af78e.zip
fixed level updating for admin preferences
Diffstat (limited to 'lib/class/user.class.php')
-rw-r--r--lib/class/user.class.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/class/user.class.php b/lib/class/user.class.php
index d2afc339..d6c6ae69 100644
--- a/lib/class/user.class.php
+++ b/lib/class/user.class.php
@@ -138,7 +138,7 @@ class User {
}
- $sql = "SELECT preference.name, preference.description, preference.catagory, user_preference.value " .
+ $sql = "SELECT preference.name, preference.description, preference.catagory, preference.level, user_preference.value " .
"FROM preference INNER JOIN user_preference ON user_preference.preference=preference.id " .
"WHERE user_preference.user='$user_id' $user_limit";
$db_results = Dba::query($sql);
@@ -148,7 +148,7 @@ class User {
$type = $r['catagory'];
$admin = false;
if ($type == 'system') { $admin = true; }
- $type_array[$type][$r['name']] = array('name'=>$r['name'],'description'=>$r['description'],'value'=>$r['value']);
+ $type_array[$type][$r['name']] = array('name'=>$r['name'],'level'=>$r['level'],'description'=>$r['description'],'value'=>$r['value']);
ksort($type_array[$type]);
$results[$type] = array ('title'=>ucwords($type),'admin'=>$admin,'prefs'=>$type_array[$type]);
} // end while