liquid_feedback_frontend

view app/main/issue/_show_head.lua @ 72:dc04df019933

Initial translation to Esperanto from the German help files.
author Thomas Wuerfel
date Wed May 26 12:15:21 2010 +0200 (2010-05-26)
parents 7bc629bc1c20
children bf885faf3452
line source
1 local issue = param.get("issue", "table")
3 local direct_voter
5 if app.session.member_id then
6 direct_voter = DirectVoter:by_pk(issue.id, app.session.member.id)
7 end
9 if config.feature_rss_enabled then
10 util.html_rss_head{ title = _"Initiatives in this issue (last created first)", module = "initiative", view = "list_rss", params = { issue_id = issue.id } }
11 util.html_rss_head{ title = _"Initiatives in this issue (last updated first)", module = "initiative", view = "list_rss", params = { issue_id = issue.id, order = "last_updated" } }
12 end
14 slot.select("path", function()
15 end)
17 slot.select("title", function()
18 ui.link{
19 content = issue.area.name,
20 module = "area",
21 view = "show",
22 id = issue.area.id
23 }
24 slot.put(" · ")
25 ui.link{
26 content = _("Issue ##{id}", { id = issue.id }),
27 module = "issue",
28 view = "show",
29 id = issue.id
30 }
31 slot.put(" · ")
32 ui.tag{
33 tag = "span",
34 content = issue.state_name,
35 }
36 end)
39 slot.select("actions", function()
41 if app.session.member_id then
43 if issue.state == 'voting' then
44 local text
45 if not direct_voter then
46 text = _"Vote now"
47 else
48 text = _"Change vote"
49 end
50 ui.link{
51 content = function()
52 ui.image{ static = "icons/16/email_open.png" }
53 slot.put(text)
54 end,
55 module = "vote",
56 view = "list",
57 params = { issue_id = issue.id }
58 }
59 end
61 execute.view{
62 module = "interest",
63 view = "_show_box",
64 params = { issue = issue }
65 }
67 if not issue.closed then
68 execute.view{
69 module = "delegation",
70 view = "_show_box",
71 params = { issue_id = issue.id }
72 }
73 end
75 execute.view{
76 module = "issue",
77 view = "_show_vote_later_box",
78 params = { issue = issue }
79 }
81 end
83 if config.issue_discussion_url_func then
84 local url = config.issue_discussion_url_func(issue)
85 ui.link{
86 attr = { target = "_blank" },
87 external = url,
88 content = function()
89 ui.image{ static = "icons/16/comments.png" }
90 slot.put(_"Discussion on issue")
91 end,
92 }
93 end
94 end)
97 execute.view{
98 module = "issue",
99 view = "_show_box",
100 params = { issue = issue }
101 }
103 -- ui.twitter("http://example.com/t" .. tostring(issue.id))
105 if config.public_access_issue_head and not app.session.member_id then
106 config.public_access_issue_head(issue)
107 end
109 if app.session.member_id and issue.state == 'voting' and not direct_voter then
110 ui.container{
111 attr = { class = "voting_active_info" },
112 content = function()
113 slot.put(_"Voting for this issue is currently running!")
114 slot.put(" ")
115 if app.session.member_id then
116 ui.link{
117 content = function()
118 slot.put(_"Vote now")
119 end,
120 module = "vote",
121 view = "list",
122 params = { issue_id = issue.id }
123 }
124 end
125 end
126 }
127 slot.put("<br />")
128 end

Impressum / About Us