liquid_feedback_frontend

changeset 214:7e3acb2f6284

Disable current member as delegation target through initiatorship
author bsw
date Thu Mar 03 23:47:35 2011 +0100 (2011-03-03)
parents acf92c2d33f4
children 1dab81353eb1
files app/main/lf2/delegation.lua
line diff
     1.1 --- a/app/main/lf2/delegation.lua	Thu Mar 03 21:26:35 2011 +0100
     1.2 +++ b/app/main/lf2/delegation.lua	Thu Mar 03 23:47:35 2011 +0100
     1.3 @@ -97,21 +97,26 @@
     1.4          }
     1.5  
     1.6        end
     1.7 +      disabled_records = {}
     1.8 +      disabled_records["_"] = true
     1.9 +
    1.10        -- add saved members
    1.11        records[#records+1] = {id="_", name= "--- " .. _"Saved contacts" .. " ---"}
    1.12        for i, record in ipairs(contact_members) do
    1.13          records[#records+1] = record
    1.14        end
    1.15 +      
    1.16        -- add initiative authors
    1.17        if initiative then
    1.18          records[#records+1] = {id="_", name= "--- " .. _"Initiators" .. " ---"}
    1.19          for i,record in ipairs(initiative.initiators) do
    1.20            records[#records+1] = record.member
    1.21 +          if record.member.id == app.session.member_id then
    1.22 +            disabled_records[record.member.id] = true
    1.23 +          end
    1.24          end
    1.25        end
    1.26  
    1.27 -      disabled_records = {}
    1.28 -      disabled_records["_"] = true
    1.29  
    1.30        
    1.31        ui.box_row{ content = function() ui.box_col{ content = function()

Impressum / About Us