liquid_feedback_frontend
view app/main/member/show.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 | 4f39f0a0d5b5 |
children | 7d0f4721d2f3 |
line source
1 local member = Member:by_id(param.get_id())
3 slot.select("title", function()
4 execute.view{
5 module = "member_image",
6 view = "_show",
7 params = {
8 member = member,
9 image_type = "avatar"
10 }
11 }
12 end)
14 slot.put_into("title", encode.html(_"Member '#{member}'":gsub("#{member}", member.name)))
16 slot.select("actions", function()
17 if not (member.id == app.session.member.id) then
18 if not member.active then
19 ui.tag{
20 tag = "div",
21 attr = { class = "interest deactivated_member_info" },
22 content = _"This member is deactivated."
23 }
24 slot.put(" ")
25 end
26 --TODO performance
27 local contact = Contact:by_pk(app.session.member.id, member.id)
28 if contact then
29 ui.container{
30 attr = { class = "interest" },
31 content = _"You have saved this member as contact."
32 }
33 ui.link{
34 image = { static = "icons/16/book_delete.png" },
35 text = _"Remove from contacts",
36 module = "contact",
37 action = "remove_member",
38 id = contact.other_member_id,
39 routing = {
40 default = {
41 mode = "redirect",
42 module = request.get_module(),
43 view = request.get_view(),
44 id = param.get_id_cgi(),
45 params = param.get_all_cgi()
46 }
47 }
48 }
49 elseif member.active then
50 ui.link{
51 image = { static = "icons/16/book_add.png" },
52 text = _"Add to my contacts",
53 module = "contact",
54 action = "add_member",
55 id = member.id,
56 routing = {
57 default = {
58 mode = "redirect",
59 module = request.get_module(),
60 view = request.get_view(),
61 id = param.get_id_cgi(),
62 params = param.get_all_cgi()
63 }
64 }
65 }
66 end
67 end
68 end)
70 slot.select("actions", function()
71 ui.link{
72 content = function()
73 ui.image{ static = "icons/16/clock_edit.png" }
74 slot.put(encode.html(_"Show name history"))
75 end,
76 module = "member",
77 view = "history",
78 id = member.id
79 }
80 end)
82 util.help("member.show", _"Member page")
84 execute.view{
85 module = "member",
86 view = "_show",
87 params = { member = member }
88 }