liquid_feedback_frontend

view app/main/delegation/_list.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
author bsw
date Thu Jul 08 18:44:02 2010 +0200 (2010-07-08)
parents 5c601807d397
children 19fbc5c758b5
line source
1 local delegations_selector = param.get("delegations_selector", "table")
2 local outgoing = param.get("outgoing", atom.boolean)
3 local incoming = param.get("incoming", atom.boolean)
5 local function delegation_scope(delegation)
6 ui.container{
7 attr = { class = "delegation_scope" },
8 content = function()
9 local area
10 if delegation.issue then
11 area = delegation.issue.area
12 else
13 area = delegation.area
14 end
15 if not area then
16 ui.field.text{ value = _"Global delegation" }
17 end
18 if area then
19 ui.link{
20 content = _"Area '#{name}'":gsub("#{name}", area.name),
21 module = "area",
22 view = "show",
23 id = area.id
24 }
25 end
26 if delegation.issue then
27 ui.link{
28 content = _"Issue ##{id}":gsub("#{id}", delegation.issue.id),
29 module = "issue",
30 view = "show",
31 id = delegation.issue.id
32 }
33 end
34 end
35 }
36 end
39 ui.paginate{
40 selector = delegations_selector,
41 content = function()
42 for i, delegation in ipairs(delegations_selector:exec()) do
43 ui.container{
44 attr = { class = "delegation_list_entry" },
45 content = function()
46 if outgoing then
47 delegation_scope(delegation)
48 else
49 execute.view{
50 module = "member",
51 view = "_show_thumb",
52 params = { member = delegation.truster }
53 }
54 end
55 ui.image{
56 attr = { class = "delegation_arrow" },
57 static = "delegation_arrow.jpg"
58 }
59 if incoming then
60 delegation_scope(delegation)
61 else
62 execute.view{
63 module = "member",
64 view = "_show_thumb",
65 params = { member = delegation.trustee }
66 }
67 end
68 end
69 }
70 end
71 slot.put("<br style='clear: left;' />")
72 end
73 }

Impressum / About Us