liquid_feedback_frontend
view app/main/interest/_show_box.lua @ 75:733f65c0c0a0
Bugfixes, feature enhancements, code-cleanup, and major work on API
Details:
- API
-- Allow relation name to be passed to helper function util.autoapi{...}
-- Added area API
-- Bugfixes in API
--- Correctly return initiatives (bug #162)
--- Correctly process "id" parameter for initiative API
--- Bugfix related to "state" parameter (bug #165)
--- Changed constant "discussion" to "accepted" (in model/issue.lua, used by API)
--- Fixed JSON encoding in auto_api (bug #181)
--- Ignore list filter "voted" in case of public access
--- Enable access to API without session
- Work on RSS feed (incomplete yet)
- Other bugfixes
-- Handle empty browser identification string
-- Handle invalid date in member/update.lua (bugs #24 #109 #115 #136)
-- Better handle errors while converting uploaded images. (bug #79 +5 duplicates)
-- Don't display revoked initiatives in list of new drafts (bug #134)
-- Fixed syntax error in app/main/member/_action/update_name.lua throwing unexpected error, when new name was too short
-- Do not display refresh support button for revoked initiatives
-- Repaired issue search (bug #150)
-- Fixed typos in german translation files
--- "initi(i)erte"
--- "Er(g)eignisse" (bug #161)
- Code cleanup
-- Removed deprecated motd files locale/motd/de.txt and locale/motd/de_public.txt
-- Removed redundant code in app/main/index/_updated_drafts.lua
- New features and (optical) enhancements
-- Support change of notify email; notification of not approved address added to start page
-- Settings dialog splitted into single pages
-- Mark deactivated members
-- Calendar for birthday selection in profile
-- Policy list public readable when public access is enabled
Details:
- API
-- Allow relation name to be passed to helper function util.autoapi{...}
-- Added area API
-- Bugfixes in API
--- Correctly return initiatives (bug #162)
--- Correctly process "id" parameter for initiative API
--- Bugfix related to "state" parameter (bug #165)
--- Changed constant "discussion" to "accepted" (in model/issue.lua, used by API)
--- Fixed JSON encoding in auto_api (bug #181)
--- Ignore list filter "voted" in case of public access
--- Enable access to API without session
- Work on RSS feed (incomplete yet)
- Other bugfixes
-- Handle empty browser identification string
-- Handle invalid date in member/update.lua (bugs #24 #109 #115 #136)
-- Better handle errors while converting uploaded images. (bug #79 +5 duplicates)
-- Don't display revoked initiatives in list of new drafts (bug #134)
-- Fixed syntax error in app/main/member/_action/update_name.lua throwing unexpected error, when new name was too short
-- Do not display refresh support button for revoked initiatives
-- Repaired issue search (bug #150)
-- Fixed typos in german translation files
--- "initi(i)erte"
--- "Er(g)eignisse" (bug #161)
- Code cleanup
-- Removed deprecated motd files locale/motd/de.txt and locale/motd/de_public.txt
-- Removed redundant code in app/main/index/_updated_drafts.lua
- New features and (optical) enhancements
-- Support change of notify email; notification of not approved address added to start page
-- Settings dialog splitted into single pages
-- Mark deactivated members
-- Calendar for birthday selection in profile
-- Policy list public readable when public access is enabled
author | bsw |
---|---|
date | Thu Jul 08 18:44:02 2010 +0200 (2010-07-08) |
parents | 00d1004545f1 |
children | ca006681befc |
line source
2 local issue = param.get("issue", "table")
4 local interest = Interest:by_pk(issue.id, app.session.member.id)
6 if interest then
7 slot.select("actions", function()
9 ui.container{
10 attr = { class = "interest vote_info"},
11 content = function()
12 ui.container{
13 attr = {
14 class = "head head_active" .. (interest.autoreject and " head_autoreject" or ""),
15 onclick = "document.getElementById('interest_content').style.display = 'block';"
16 },
17 content = function()
18 ui.image{
19 static = "icons/16/eye.png"
20 }
21 slot.put(_"Your are interested")
23 if interest.autoreject then
24 ui.image{
25 static = "icons/16/thumb_down_red.png"
26 }
27 end
29 ui.image{
30 static = "icons/16/dropdown.png"
31 }
32 end
33 }
35 ui.container{
36 attr = { class = "content", id = "interest_content" },
37 content = function()
38 ui.container{
39 attr = {
40 class = "close",
41 style = "cursor: pointer;",
42 onclick = "document.getElementById('interest_content').style.display = 'none';"
43 },
44 content = function()
45 ui.image{ static = "icons/16/cross.png" }
46 end
47 }
48 if issue.state ~= "finished" and issue.state ~= "cancelled" and issue.state ~= "voting" then
49 ui.link{
50 text = _"Remove my interest",
51 module = "interest",
52 action = "update",
53 params = { issue_id = issue.id, delete = true },
54 routing = { default = { mode = "redirect", module = "issue", view = "show", id = issue.id } }
55 }
56 slot.put("<br />")
57 slot.put("<br />")
58 end
59 if interest.autoreject then
60 ui.field.text{ value = _"Autoreject is on." }
61 if issue.state ~= "finished" and issue.state ~= "cancelled" then
62 ui.link{
63 text = _"Remove autoreject",
64 module = "interest",
65 action = "update",
66 params = { issue_id = issue.id, autoreject = false },
67 routing = { default = { mode = "redirect", module = "issue", view = "show", id = issue.id } }
68 }
69 end
70 else
71 ui.field.text{ value = _"Autoreject is off." }
72 if issue.state ~= "finished" and issue.state ~= "cancelled" then
73 ui.link{
74 text = _"Set autoreject",
75 module = "interest",
76 action = "update",
77 params = { issue_id = issue.id, autoreject = true },
78 routing = { default = { mode = "redirect", module = "issue", view = "show", id = issue.id } }
79 }
80 end
81 end
82 end
83 }
84 end
85 }
86 end)
87 else
88 if not issue.closed and not issue.fully_frozen then
89 ui.link{
90 image = { static = "icons/16/user_add.png" },
91 text = _"Add my interest",
92 module = "interest",
93 action = "update",
94 params = { issue_id = issue.id },
95 routing = { default = { mode = "redirect", module = "issue", view = "show", id = issue.id } }
96 }
97 end
98 end