liquid_feedback_frontend

annotate app/main/area/show.lua @ 265:d37dce888225

More unit support
author bsw
date Tue Feb 07 18:40:08 2012 +0100 (2012-02-07)
parents 7ef1e03e4057
children d13b27a37ad5
rev   line source
bsw@197 1 local area = Area:by_id(param.get_id())
bsw@197 2
bsw/jbe@0 3
jorges@103 4 app.html_title.title = area.name
jorges@103 5 app.html_title.subtitle = _("Area")
jorges@103 6
bsw@197 7 util.help("area.show")
bsw@197 8
bsw@197 9
bsw/jbe@52 10 if config.feature_rss_enabled then
bsw/jbe@52 11 util.html_rss_head{ title = _"Initiatives in this area (last created first)", module = "initiative", view = "list_rss", params = { area_id = area.id } }
bsw/jbe@52 12 util.html_rss_head{ title = _"Initiatives in this area (last updated first)", module = "initiative", view = "list_rss", params = { area_id = area.id } }
bsw/jbe@52 13 end
bsw/jbe@52 14
bsw@197 15
bsw@265 16 slot.select("title", function()
bsw@265 17 if not config.single_unit_id then
bsw@265 18 ui.link{
bsw@265 19 content = area.unit.name,
bsw@265 20 module = "area",
bsw@265 21 view = "list",
bsw@265 22 params = { unit_id = area.unit_id }
bsw@265 23 }
bsw@265 24 slot.put(" · ")
bsw@265 25 end
bsw@197 26
bsw@265 27 ui.tag{ content = area.name }
bsw@265 28
bsw@265 29 end)
bsw/jbe@0 30
bsw/jbe@0 31 ui.container{
bsw/jbe@0 32 attr = { class = "vertical"},
bsw/jbe@0 33 content = function()
bsw/jbe@0 34 ui.field.text{ value = area.description }
bsw/jbe@0 35 end
bsw/jbe@0 36 }
bsw/jbe@0 37
bsw@197 38
bsw@51 39 if app.session.member_id then
bsw@197 40
bsw@51 41 slot.select("actions", function()
bsw@51 42 ui.link{
bsw@51 43 content = function()
bsw@51 44 ui.image{ static = "icons/16/folder_add.png" }
bsw@51 45 slot.put(_"Create new issue")
bsw@51 46 end,
bsw@51 47 module = "initiative",
bsw@51 48 view = "new",
bsw@51 49 params = { area_id = area.id }
bsw@51 50 }
bsw@51 51 end)
bsw/jbe@0 52
bsw@51 53 execute.view{
bsw@51 54 module = "membership",
bsw@51 55 view = "_show_box",
bsw@51 56 params = { area = area }
bsw@51 57 }
bsw/jbe@0 58
bsw@51 59 execute.view{
bsw@51 60 module = "delegation",
bsw@51 61 view = "_show_box",
bsw@51 62 params = { area_id = area.id }
bsw@51 63 }
bsw@51 64
bsw@51 65 end
bsw/jbe@0 66
bsw/jbe@19 67
bsw/jbe@19 68 execute.view{
bsw/jbe@19 69 module = "area",
bsw/jbe@19 70 view = "show_tab",
bsw/jbe@19 71 params = { area = area }
bsw/jbe@0 72 }
bsw/jbe@0 73

Impressum / About Us