liquid_feedback_frontend

diff app/main/delegation/_show_box.lua @ 273:7196685f9dd7

More optical enhancements, more repositioning
author bsw
date Wed Feb 08 18:49:22 2012 +0100 (2012-02-08)
parents 1b8d51e21614
children bde068b37608
line diff
     1.1 --- a/app/main/delegation/_show_box.lua	Wed Feb 08 00:55:17 2012 +0100
     1.2 +++ b/app/main/delegation/_show_box.lua	Wed Feb 08 18:49:22 2012 +0100
     1.3 @@ -71,6 +71,8 @@
     1.4  
     1.5  unit_id = param.get("unit_id", atom.integer)
     1.6  
     1.7 +local inline = param.get("inline", atom.boolean)
     1.8 +
     1.9  if param.get("initiative_id", atom.integer) then
    1.10    initiative_id = param.get("initiative_id", atom.integer)
    1.11    issue_id = Initiative:by_id(initiative_id).issue_id
    1.12 @@ -98,16 +100,28 @@
    1.13    if not delegation then
    1.14      delegation = Delegation:by_pk(app.session.member.id, nil, issue.area_id)
    1.15    end
    1.16 +  if not delegation then
    1.17 +    delegation = Delegation:by_pk(app.session.member.id, issue.area.unit_id)
    1.18 +  end
    1.19  elseif area_id then
    1.20    delegation = Delegation:by_pk(app.session.member.id, nil, area_id)
    1.21 +  if not delegation then
    1.22 +    local area = Area:by_id(area_id)
    1.23 +    delegation = Delegation:by_pk(app.session.member.id, area.unit_id)
    1.24 +  end
    1.25  end
    1.26  
    1.27  if not delegation then
    1.28    delegation = Delegation:by_pk(app.session.member.id, unit_id)
    1.29  end
    1.30  
    1.31 +local slot_name = "actions"
    1.32  
    1.33 -slot.select("actions", function()
    1.34 +if inline then
    1.35 +  slot_name = "default"
    1.36 +end
    1.37 +
    1.38 +slot.select(slot_name, function()
    1.39  
    1.40    if delegation then
    1.41      ui.container{

Impressum / About Us