liquid_feedback_frontend

diff model/direct_voter.lua @ 5:afd9f769c7ae

Version beta1

Final voting with Schulze-Method is now possible

Many bug fixes and code cleanup

Registration with invite codes

More sort and filter options

Seperated display of "supporters" and "potential supporters"

Optical changes

Flood limit / initiative contigent is now checked by frontend

Neccessary changes to access core beta11
author bsw/jbe
date Fri Dec 25 12:00:00 2009 +0100 (2009-12-25)
parents 3bfb2fcf7ab9
children ea3d3757ddc3
line diff
     1.1 --- a/model/direct_voter.lua	Thu Dec 10 12:00:00 2009 +0100
     1.2 +++ b/model/direct_voter.lua	Fri Dec 25 12:00:00 2009 +0100
     1.3 @@ -1,5 +1,6 @@
     1.4  DirectVoter = mondelefant.new_class()
     1.5 -DirectVoter.table = 'member'
     1.6 +DirectVoter.table = 'direct_voter'
     1.7 +DirectVoter.primary_key = { "issue_id", "member_id" }
     1.8  
     1.9  DirectVoter:add_reference{
    1.10    mode          = 'm1',
    1.11 @@ -16,3 +17,10 @@
    1.12    that_key      = 'id',
    1.13    ref           = 'member',
    1.14  }
    1.15 +
    1.16 +function DirectVoter:by_pk(issue_id, member_id)
    1.17 +  return self:new_selector()
    1.18 +    :add_where{ "issue_id = ? AND member_id = ?", issue_id, member_id }
    1.19 +    :optional_object_mode()
    1.20 +    :exec()
    1.21 +end
    1.22 \ No newline at end of file

Impressum / About Us