コード例 #1
0
 /**
  * class constructor
  * @param int	$id_user the id of the user
  */
 function UserPreferences($id_user, $db_conn = NULL)
 {
     $acl_man = new DoceboACLManager();
     $this->id_user = $id_user;
     if ($acl_man->getAnonymousId() == $id_user) {
         $this->is_anonymous = true;
     } else {
         $this->is_anonymous = false;
     }
     $this->_up_db = new UserPreferencesDb($db_conn);
     $this->base_name = 'user_preference';
     // Load startup
     $this->_preferences = $this->_up_db->getFilteredUserValue($id_user, false, true, false);
     $this->_admin_preference = new AdminPreference();
 }