From: Reini U. <ru...@us...> - 2008-01-24 19:33:46
|
Update of /cvsroot/phpwiki/phpwiki/lib/wikilens In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2269/lib/wikilens Modified Files: RatingsUser.php Log Message: Support RATING_STORAGE=WIKIPAGE Index: RatingsUser.php =================================================================== RCS file: /cvsroot/phpwiki/phpwiki/lib/wikilens/RatingsUser.php,v retrieving revision 1.5 retrieving revision 1.6 diff -u -2 -b -p -d -r1.5 -r1.6 --- RatingsUser.php 15 Nov 2004 16:00:02 -0000 1.5 +++ RatingsUser.php 24 Jan 2008 19:33:50 -0000 1.6 @@ -3,5 +3,5 @@ rcs_id('$Id$'); /* Copyright (C) 2004 Dan Frankowski * - * This file is (not yet) part of PhpWiki. + * This file is part of PhpWiki. * * PhpWiki is free software; you can redistribute it and/or modify @@ -167,5 +167,10 @@ class RatingsUser { { // XXX: does this really want to do a full ratings load? (scalability?) + if (RATING_STORAGE == 'SQL') $this->_load_ratings(); + else { + $rdbi = $this->_get_rating_dbi(); + return $rdbi->metadata_get_rating($this->getId(), $pagename, $dimension); + } if ($this->has_rated($pagename, $dimension)) @@ -353,4 +358,5 @@ class RatingsUser { //$rating_iter = $dbi->sql_get_rating(null, $this->_userid, null); + //($dimension=null, $rater=null, $ratee=null, $orderby = null, $pageinfo = "ratee") $rating_iter = $dbi->get_rating_page(null, $this->_userid); @@ -423,4 +429,7 @@ class _UserRating // $Log$ +// Revision 1.6 2008/01/24 19:33:50 rurban +// Support RATING_STORAGE=WIKIPAGE +// // Revision 1.5 2004/11/15 16:00:02 rurban // enable RateIt imgPrefix: '' or 'Star' or 'BStar', |