[Dev-flock] argument evaluation
Daniel Ring
danring at MIT.EDU
Fri Dec 7 02:01:04 EST 2007
Hey,
Sorry about the confusion. Limits on ratings for the various objects
are specified in db/ratings.py - I changed the range to [-1,1] so now
argument evaluations will work (I also changed the code in
main.py....we'll see who wins the svk smerge contest.)
Also, you shouldn't need to reference UserExtended explicitly, use
'user.profile' instead.
Also, Arguments don't have a userID foreign key because anytime an
object is created in the database, an Action object is automagically
created storing the user, time, and created object. This allows us to
(eventually) do cool complex queries on user actions
(sorta-kinda-facebook-style feeds).
You can still retrieve the user and time via object.user and
object.time, but you can't set it that way (Action objects are immutable).
Dan
Mike Eggar wrote:
> Probably can't get evaluations working properly by friday, been trying
> something like this:
>
> user = Action.objects.get(item_type='18',
> item_id=request['argument_id']).user
> user = UserExtended(user)
> user.status = user.status + score
>
>
>
>
>> Date: Thu, 6 Dec 2007 20:43:34 -0500
>> From: lucy at thoughtandmemory.org
>> To: eggar at hotmail.com
>> Subject: Re: [Dev-flock] argument evaluation
>> CC: dev-flock at mit.edu
>>
>> Hmm. Ratings and evaluations are different. An evaluation is supposed
>> to effect a user's status points, which can range across negative and
>> positive numbers. I remember being unable to find evaluations in the
>> epydocs--- I bet Dan has the answer, though!
>>
>>
>> On Dec 6, 2007 8:21 PM, Mike Eggar <eggar at hotmail.com> wrote:
>> >
>> > so negative argument evaluation wont work by adding a new rating with
>> > score=-1 because it has to be between 0-10. Is evaluation supposed
> to add
>> > a new rating object or is there another way to do it?
>> >
>> > Mike
>> >
>> > ________________________________
>> > You keep typing, we keep giving. Download Messenger and join the i'm
>> > Initiative now. Join in!
>> > _______________________________________________
>> > Dev-flock mailing list
>> > Dev-flock at mit.edu
>> > http://mailman.mit.edu/mailman/listinfo/dev-flock
>> >
>> >
>
> ------------------------------------------------------------------------
> Get the power of Windows + Web with the new Windows Live. Power up!
> <http://www.windowslive.com?ocid=TXT_TAGLM_Wave2_powerofwindows_112007>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Dev-flock mailing list
> Dev-flock at mit.edu
> http://mailman.mit.edu/mailman/listinfo/dev-flock
More information about the Dev-flock
mailing list