liquid_feedback_frontend
annotate app/main/area/list.lua @ 64:3ec1dea6eefb
Bug when creating alternative initiatives fixed; Policy list link only shown when creating new issue
author | bsw |
---|---|
date | Thu Apr 22 17:05:18 2010 +0200 (2010-04-22) |
parents | 0849be391140 |
children | c553898f64cb |
rev | line source |
---|---|
bsw@51 | 1 if app.session.member_id then |
bsw@51 | 2 slot.put_into("title", _'Area list') |
bsw@51 | 3 else |
bsw@51 | 4 slot.put_into("title", encode.html(config.app_title)) |
bsw@51 | 5 end |
bsw@51 | 6 |
bsw@51 | 7 local lang = locale.get("lang") |
bsw@51 | 8 local basepath = request.get_app_basepath() |
bsw@51 | 9 local file_name = basepath .. "/locale/motd/" .. lang .. "_public.txt" |
bsw@51 | 10 local file = io.open(file_name) |
bsw@51 | 11 if file ~= nil then |
bsw@51 | 12 local help_text = file:read("*a") |
bsw@51 | 13 if #help_text > 0 then |
bsw@51 | 14 ui.container{ |
bsw@51 | 15 attr = { class = "motd wiki" }, |
bsw@51 | 16 content = function() |
bsw@51 | 17 slot.put(format.wiki_text(help_text)) |
bsw@51 | 18 end |
bsw@51 | 19 } |
bsw@51 | 20 end |
bsw@51 | 21 end |
bsw/jbe@0 | 22 |
bsw/jbe@4 | 23 util.help("area.list", _"Area list") |
bsw/jbe@4 | 24 |
bsw/jbe@0 | 25 local areas_selector = Area:new_selector():add_where("active") |
bsw/jbe@0 | 26 |
bsw/jbe@0 | 27 execute.view{ |
bsw/jbe@0 | 28 module = "area", |
bsw/jbe@0 | 29 view = "_list", |
bsw/jbe@0 | 30 params = { areas_selector = areas_selector } |
bsw/jbe@0 | 31 } |
bsw/jbe@0 | 32 |
bsw/jbe@4 | 33 --[[ |
bsw/jbe@0 | 34 execute.view{ |
bsw/jbe@0 | 35 module = "delegation", |
bsw/jbe@0 | 36 view = "_show_box" |
bsw/jbe@4 | 37 } |
bsw/jbe@4 | 38 --]] |