liquid_feedback_frontend
diff app/main/draft/_list.lua @ 134:de6b80867eb7
make user names clickable
simplify pseudonym code by having one place to generate ui.field.text
simplify pseudonym code by having one place to generate ui.field.text
| author | Daniel Poelzleithner <poelzi@poelzi.org> |
|---|---|
| date | Tue Oct 05 20:56:41 2010 +0200 (2010-10-05) |
| parents | 0849be391140 |
| children |
line diff
1.1 --- a/app/main/draft/_list.lua Tue Oct 05 16:18:39 2010 +0200 1.2 +++ b/app/main/draft/_list.lua Tue Oct 05 20:56:41 2010 +0200 1.3 @@ -15,10 +15,8 @@ 1.4 { 1.5 label = _"Author", 1.6 content = function(record) 1.7 - if app.session.member_id or config.public_access == "pseudonym" then 1.8 - ui.field.text{ readonly = true, value = record.author.name } 1.9 - else 1.10 - ui.field.text{ readonly = true, value = _"[not displayed public]" } 1.11 + if record.author then 1.12 + return record.author:ui_field_text() 1.13 end 1.14 end 1.15 },