liquid_feedback_frontend

view app/main/interest/_action/update_voting_requested.lua @ 16:559c6be0e1e9

"Vote later" feature; Refactored interest box
author bsw
date Tue Feb 02 00:10:17 2010 +0100 (2010-02-02)
parents
children
line source
1 local issue_id = assert(param.get("issue_id", atom.integer), "no issue id given")
3 local interest = Interest:by_pk(issue_id, app.session.member.id)
5 local issue = Issue:new_selector():add_where{ "id = ?", issue_id }:for_share():single_object_mode():exec()
7 if issue.closed then
8 slot.put_into("error", _"This issue is already closed.")
9 return false
10 elseif issue.half_frozen then
11 slot.put_into("error", _"This issue is already frozen.")
12 return false
13 end
15 interest.voting_requested = param.get("voting_requested", atom.boolean)
17 if interest.voting_requested == true then
18 error("not implemented yet")
19 end
21 interest:save()
23 slot.put_into("notice", _"Voting request updated")

Impressum / About Us