liquid_feedback_frontend
annotate app/main/index/_not_voted_issues.lua @ 156:74f1d4abf19e
fix that bailout can not be seen after the vote
linkify title
linkify title
author | Daniel Poelzleithner <poelzi@poelzi.org> |
---|---|
date | Fri Oct 08 20:06:23 2010 +0200 (2010-10-08) |
parents | 4f39f0a0d5b5 |
children | 87c33552f406 |
rev | line source |
---|---|
bsw@57 | 1 local areas = param.get("areas", "table") |
bsw@57 | 2 |
bsw@57 | 3 if #areas > 0 then |
bsw@57 | 4 ui.container{ |
bsw@57 | 5 attr = { style = "font-weight: bold;" }, |
bsw@57 | 6 content = _"Current votings in areas you are member of and issues you are interested in:" |
bsw@57 | 7 } |
bsw@57 | 8 |
bsw@57 | 9 ui.list{ |
bsw@57 | 10 records = areas, |
bsw@57 | 11 columns = { |
bsw@57 | 12 { |
bsw@57 | 13 name = "name" |
bsw@57 | 14 }, |
bsw@57 | 15 { |
bsw@57 | 16 content = function(record) |
bsw@57 | 17 if record.is_member and record.issues_to_vote_count > 0 then |
bsw@57 | 18 ui.link{ |
bsw@57 | 19 content = function() |
bsw@57 | 20 if record.issues_to_vote_count > 1 then |
bsw@57 | 21 slot.put(_("#{issues_to_vote_count} issue(s)", { issues_to_vote_count = record.issues_to_vote_count })) |
bsw@57 | 22 else |
bsw@57 | 23 slot.put(_("One issue")) |
bsw@57 | 24 end |
bsw@57 | 25 end, |
bsw@57 | 26 module = "area", |
bsw@57 | 27 view = "show", |
bsw@57 | 28 id = record.id, |
bsw@57 | 29 params = { |
bsw@57 | 30 filter = "frozen", |
bsw@57 | 31 filter_voting = "not_voted" |
bsw@57 | 32 } |
bsw@57 | 33 } |
bsw@57 | 34 else |
bsw@57 | 35 slot.put(_"Not a member") |
bsw@57 | 36 end |
bsw@57 | 37 end |
bsw@57 | 38 }, |
bsw@57 | 39 { |
bsw@57 | 40 content = function(record) |
bsw@57 | 41 if record.interested_issues_to_vote_count > 0 then |
bsw@57 | 42 ui.link{ |
bsw@57 | 43 content = function() |
bsw@57 | 44 if record.interested_issues_to_vote_count > 1 then |
bsw@57 | 45 slot.put(_("#{interested_issues_to_vote_count} issue(s) you are interested in", { interested_issues_to_vote_count = record.interested_issues_to_vote_count })) |
bsw@57 | 46 else |
bsw@57 | 47 slot.put(_"One issue you are interested in") |
bsw@57 | 48 end |
bsw@57 | 49 end, |
bsw@57 | 50 module = "area", |
bsw@57 | 51 view = "show", |
bsw@57 | 52 id = record.id, |
bsw@57 | 53 params = { |
bsw@57 | 54 filter = "frozen", |
bsw@57 | 55 filter_interest = "my", |
bsw@57 | 56 filter_voting = "not_voted" |
bsw@57 | 57 } |
bsw@57 | 58 } |
bsw@57 | 59 end |
bsw@57 | 60 end |
bsw@57 | 61 }, |
bsw@57 | 62 } |
bsw@57 | 63 } |
bsw@57 | 64 end |